tensorflow-serving: fix project build at HEAD (Bazel 7.7.0 pin, tensorflow.patch refresh, static libc++) - #16061
Open
alencheung wants to merge 1 commit into
Open
alencheung wants to merge 1 commit into
alencheung wants to merge 1 commit into
Conversation
- pin Bazel 7.7.0 via .bazelversion (bazelisk resolves 9.x, which no longer reads WORKSPACE repositories -> @com_google_fuzztest unresolvable, setup_configs/--config=oss-fuzz fail) - refresh third_party/tensorflow/tensorflow.patch against the pinned TF commit 2f504bd: 3 hunks obsolete upstream (graph_execution_options.h fields, tf_runtime repo_mapping, gpu_communicator.h PackedKernelArg), 1 hunk context drift (absl/strings:string_view in xla/tsl/cuda/BUILD.bazel) - link with -static-libstdc++ -l:libc++abi.a so binaries run in base-runner (hermetic rules_ml_toolchain clang otherwise links its own dynamic libc++.so.1) Verified end-to-end: build_image -> build_fuzzers --sanitizer address --architecture x86_64 -> reproduce all succeed; existing json_tensor_test_fuzz target builds and runs.
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
|
alencheung is a new contributor to projects/tensorflow-serving. The PR must be approved by known contributors before it can be merged. The past contributors are: maflcko |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
tensorflow-servingproject currently fails to build at HEAD. Three independent breaks; all verified fixed by this change (the fullbuild_image->build_fuzzers --sanitizer address --architecture x86_64->reproducesequence passes afterwards):Bazel 9.x dropped WORKSPACE repositories. bazelisk resolves the latest release, in which
@com_google_fuzztest(required bysetup_configsto define--config=oss-fuzz) is unresolvable. Fix: pin.bazelversionto 7.7.0 — the version the pinned TF commit (2f504bd) builds with.third_party/tensorflow/tensorflow.patchis stale against serving's own TF pin (tensorflow/serving@549f7a1 pins2f504bd): 3 hunks no longer apply (thegraph_execution_options.hfields, thetf_runtimerepo_mappingblock, and thegpu_communicator.hPackedKernelArgalias all changed upstream) and 1 hunk needs a context refresh (absl/strings:string_viewinserted inxla/tsl/cuda/BUILD.bazel). Theorg_tensorflowrepository fetch fails withCONTENT_DOES_NOT_MATCH_TARGETotherwise. Fix: refresh the patch insidetensorflow-serving.diff.Binaries link a dynamic
libc++.so.1from the hermeticrules_ml_toolchain, which base-runner does not ship — fuzzers fail to load at run time (error while loading shared libraries: libc++.so.1). Fix:-static-libstdc++ -l:libc++abi.a.After these, the existing
json_tensor_test_fuzz@JsonFuzzTest.TheFtarget builds and loads in base-runner (verified), and out-of-tree REST-JSON harnesses overFill{Predict,Classification,Regression}RequestFromJsonreproduce the known unbounded-recursion crash under ASAN (tensorflow_serving/util/json_tensor.cc:393inFillTensorProto, the parse-side half of CVE-2025-0649) — relevant context for #15357 and tensorflow/serving#4143, which add such targets but currently cannot build on top of the project as-is.