Skip to content

unified: Make build work in Bazel again#22069

Merged
asgerf merged 1 commit into
github:mainfrom
asgerf:unified/build
Jun 26, 2026
Merged

unified: Make build work in Bazel again#22069
asgerf merged 1 commit into
github:mainfrom
asgerf:unified/build

Conversation

@asgerf

@asgerf asgerf commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Makes bazel build //unified work again

@asgerf asgerf added the no-change-note-required This PR does not need a change note label Jun 26, 2026
@asgerf asgerf marked this pull request as ready for review June 26, 2026 11:11
@asgerf asgerf requested a review from a team as a code owner June 26, 2026 11:11
Copilot AI review requested due to automatic review settings June 26, 2026 11:11

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR restores bazel build //unified by removing the build-time dependency on an external Node.js binary for tree-sitter Swift parser generation and by ensuring a schema file needed by include_str! is available to Bazel’s Rust compile action.

Changes:

  • Switch the tree-sitter-generate invocation for tree-sitter-swift to use the embedded QuickJS runtime (“native”) instead of spawning node, which is unavailable in Bazel’s sandbox.
  • Add ast_types.yml to the unified extractor Bazel target’s compile_data so Rust compilation can resolve include_str!("../../ast_types.yml").
Show a summary per file
File Description
unified/extractor/tree-sitter-swift/bindings/rust/build.rs Uses embedded JS runtime for grammar evaluation to avoid requiring Node.js under Bazel sandboxing.
unified/extractor/BUILD.bazel Adds ast_types.yml to compile_data so the extractor can compile with the YAML embedded via include_str!.

Review details

  • Files reviewed: 2/2 changed files
  • Comments generated: 0
  • Review effort level: Low

@tausbn tausbn left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes look reasonable to me, though I'm in no way an expert on Bazel.

@asgerf asgerf merged commit 2767b8d into github:main Jun 26, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-change-note-required This PR does not need a change note

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants