Skip to content

Fix ArrayRecord OSS build, macOS TensorFlow segfault, and GitHub CI. - #210

Merged
copybara-service[bot] merged 1 commit into
mainfrom
test_992591542
Oct 5, 2026
Merged

copybara-service[bot] merged 1 commit into
mainfrom
test_992591542

Conversation

@copybara-service

@copybara-service copybara-service Bot commented Oct 2, 2026 •

Copy link
Copy Markdown

Fix ArrayRecord OSS build, macOS TensorFlow segfault, and GitHub CI.

Importing array_record_module.so alongside TensorFlow 2.21+ on macOS and Linux caused a segmentation fault (Segmentation fault: 11 in oss/test_import_tensorflow.py) because array_record_module.so statically linked C++ Protobuf 28.3 and Abseil with default global symbol visibility, colliding at runtime with TensorFlow's libtensorflow_framework (Protobuf 31.1). In addition, the OSS Bazel build failed due to unpinned protobuf dependencies in MODULE.bazel, newer absl::MutexLock and Mutex::try_lock/unlock APIs in the C++ writers not yet available in the pinned OSS abseil-cpp release, and unquoted version specifiers in oss/build_whl.sh.

Restrict exported symbols of array_record_module.so in OSS builds to only PyInit_array_record_module via -Wl,-exported_symbol,_PyInit_array_record_module on macOS and a linker version script (-Wl,--version-script) on Linux. Pin protobuf to 28.3 in MODULE.bazel, use Copybara replacements to rewrite absl::MutexLock and try_lock/unlock calls in the C++ record writers for OSS Abseil compatibility while keeping the modern API internally, and fix oss/build_whl.sh to quote tensorflow>=2.20.0, enforce --only-binary :all: for wheel test dependencies, and install the specific built wheel file.

@copybara-service
copybara-service Bot force-pushed the test_992591542 branch 5 times, most recently from 62ddb02 to 355b20c Compare October 5, 2026 19:26
@copybara-service copybara-service Bot changed the title Fix ArrayRecord OSS build issues and update runner for all Python versions. Fix ArrayRecord OSS build, macOS TensorFlow segfault, and GitHub CI. Oct 5, 2026
@copybara-service
copybara-service Bot force-pushed the test_992591542 branch 2 times, most recently from 0fe1037 to 3730026 Compare October 5, 2026 20:04
PiperOrigin-RevId: 993856096
@copybara-service
copybara-service Bot merged commit 88cba2e into main Oct 5, 2026
4 checks passed
@copybara-service
copybara-service Bot deleted the test_992591542 branch October 5, 2026 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant