Consolidate all_scripts_test.go to use a single CGO target to fix duplicate symbol errors introduced by rules_go v0.58.1#2311
Merged
ddelnano merged 1 commit intopixie-io:mainfrom Jan 7, 2026
Conversation
protobuf encoded export Signed-off-by: Dom Del Nano <ddelnano@gmail.com> (cherry picked from commit 322954c)
vihangm
reviewed
Jan 7, 2026
| pl_cc_binary( | ||
| name = "export_schemas", | ||
| srcs = ["export_schemas.cc"], | ||
| stamp = -1, |
Member
There was a problem hiding this comment.
why do we need to disable stamping here?
Member
Author
There was a problem hiding this comment.
Oops missed this before I merged the original PR yesterday. We actually don't need this.
Removed in #2312.
vihangm
approved these changes
Jan 7, 2026
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.
Summary: Consolidate
all_scripts_test.goto use a single CGO target to fix duplicate symbol errors introduced by rules_go v0.58.1bazel-contrib/rules_go#4438, included in
rules_gov0.58.1, causes certain statically linked CGO binaries to fail with duplicate symbol errors. This occurs when a binary depends on more than one CGO library that transitively depends on a common set of object files.all_scripts_test.gopreviously depended on two CGO targets://src/carnot/planner//src/e2e_test/vizier/planner/dump_schemas/godumpschemasThis PR solves this issue by removing the src/e2e_test/vizier/planner/dump_schemas/godumpschemas CGO library and instead generate the protobuf export directly in C++, loading it in the main application. This approach mirrors the existing pattern used in src/vizier/funcs.
Why not fix
rules_go?The
rules_gochange that causes the issue explains that it doesn't include the necessary deduplication logic to avoid these duplicate symbol errors (bazel-contrib/rules_go#4438 (comment)). This tradeoff was deemed acceptable since it solved the c++ initialization problem with minimal complexity.Relevant Issues: N/A
Type of change: /kind cleanup
Test Plan: Build should pass