Skip to content

feat(codegen): run trusted Rust support bundles - #304

Merged
tinovyatkin merged 8 commits into
mainfrom
codex/issue-265-trusted-rust-support
Aug 5, 2026
Merged

feat(codegen): run trusted Rust support bundles#304
tinovyatkin merged 8 commits into
mainfrom
codex/issue-265-trusted-rust-support

Conversation

@tinovyatkin

@tinovyatkin tinovyatkin commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Summary

  • detect sibling Rust/transformGrammar.py bundles and identify them by repository, revision, path, and content fingerprint
  • require explicit trust through a styled interactive prompt or an exact non-interactive --trust-rust-support fingerprint
  • persist trust-on-revision and trust-on-repository decisions in the platform configuration directory
  • fingerprint the staged bytes that will execute, then run the approved transform in a bundled RustPython child with bounded output and a configurable deadline
  • automatically enable embedded actions, strict semantics, generated-only parser coverage, and transformed superClass acknowledgement
  • relocate shipped Rust support modules behind a generated aggregator, expose helpers through a stable rust_support re-export, and emit transformed grammars plus rust-support.json

Why

Issue #265 identified two grammars-v4 Rust support folders whose transforms target the older antlr4rust generated API. The compatibility surfaces from #267 and committed action timing from #266 are now available, so codegen can consume those bundles without modifying the source checkout or requiring users to run Python, copy files, add flags, or declare support modules manually.

The execution contract is deliberately trusted-source-first. Staging protects the checkout and makes outputs auditable, but it is not presented as a host security sandbox.

Scope

  • automatic execution is currently an antlr4-rust-gen CLI feature; Builder and TestRig do not execute sibling scripts
  • Python compatibility is tested only against the imports and filesystem behavior used by the current c/Rust and java/java/Rust transforms
  • strict support policy is scoped to transformed sources when support and ordinary grammar roots share one invocation
  • this does not change the generated-source/runtime API revision

Validation

  • cargo test --locked --workspace --all-targets --all-features
  • cargo clippy --locked --workspace --all-targets --all-features -- -D warnings
  • cargo package --locked -p antlr-rust-codegen --allow-dirty
  • ANTLR_RUST_RELEASE_ALLOW_DIRTY=1 tools/release/verify-package-contents.sh antlr-rust-codegen
  • full ANTLR runtime testsuite: 357 passed, 0 failed, 0 skipped
  • generated and compiled the exact upstream C and Java Rust folders from grammars-v4 42b1ea521705c126d84331186b221c9819db1058

Summary by CodeRabbit

  • New Features
    • Added automatic discovery and support for selected grammars-v4 C and Java Rust transformation scripts.
    • Transformations run on disposable grammar copies using an isolated Python runtime, preserving the original checkout.
    • Generated output now includes transformed grammars, Rust support modules, and an audit manifest.
    • Added configurable transformation timeouts and trust options for interactive and non-interactive use.
  • Documentation
    • Documented trust decisions, fingerprints, configuration, generated artifacts, and supported Python behavior.
  • Bug Fixes
    • Improved diagnostics and source-path handling for transformed grammar errors.

Detect sibling Rust/transformGrammar.py bundles and require an explicit trust decision keyed by repository, revision, and content fingerprint before execution. Stage the complete grammar tree and run the approved transform in a bundled RustPython child so the source checkout remains untouched.

Automatically select embedded strict generated-parser behavior, acknowledge transformed superclass metadata, relocate shipped Rust modules behind a generated aggregator, and emit transformed grammars plus rust-support.json for auditability. Keep Python compatibility tests scoped to the two current grammars-v4 C and Java transforms.
@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown

Copy/Paste Detection

Found 1 duplication(s) across 15 changed non-generated Rust file(s) (threshold: 100 tokens).

Show duplications

Found a 17 line (112 tokens) duplication in the following files:

  • Starting at line 93 of crates/antlr-rust-codegen/src/driver.rs
  • Starting at line 142 of crates/antlr-rust-codegen/src/driver.rs
            let data = LexerCodegenData::from_compiled(compiled, &compilation.sources);
            let support_enabled =
                source_uses_rust_support(&data, &compilation.sources, &prepared_support);
            let option_hooks = option_hooks(args, &data, support_enabled);
            let options = collect_structural_grammar_options(&data, &option_hooks)?;
            if support_enabled {
                enforce_require_full_options(true, &options)?;
            }
            grammar_options.extend(options);
            let embedded_actions = args.embedded_actions || support_enabled;
            let sem_unknown = if support_enabled {
                SemUnknownPolicy::Error
            } else {
                args.sem_unknown
            };
            let require_full_semantics = args.require_full_semantics || support_enabled;
            let entries = collect_lexer_semantics(
```rust

@claude

claude Bot commented Aug 5, 2026

Copy link
Copy Markdown

Claude Code is working…

I'll analyze this and get back to you.

View job run

@coderabbitai

coderabbitai Bot commented Aug 5, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@tinovyatkin, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 18 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 693721e3-87a2-49bd-a252-f7826ad6e8cc

📥 Commits

Reviewing files that changed from the base of the PR and between b98e95c and 7e89421.

📒 Files selected for processing (2)
  • crates/antlr-rust-codegen/src/rust_support/identity.rs
  • crates/antlr-rust-codegen/src/rust_support/mod.rs
📝 Walkthrough

Walkthrough

The CLI discovers trusted grammars-v4 Rust support bundles, transforms grammar copies with bundled RustPython, integrates generated support modules, emits audit artifacts, and validates C and Java workflows through end-to-end tests.

Changes

Rust support transformation pipeline

Layer / File(s) Summary
Trust identity and CLI configuration
crates/antlr-rust-codegen/Cargo.toml, crates/antlr-rust-codegen/src/{builder,config,cli,testrig_cli,lib}.rs, crates/antlr-rust-codegen/src/rust_support/{identity,prompt,mod}.rs
The CLI configures Rust support and validates trust fingerprints. Bundle identity and repository or revision trust are stored in TOML. Interactive prompts support once, revision, repository, and abort decisions.
Bundle preparation and isolated execution
crates/antlr-rust-codegen/src/rust_support/{mod,python,stage}.rs
The generator discovers support bundles, copies grammars into temporary directories, runs transformGrammar.py through bundled RustPython, rewrites support paths, and records transformed files and support modules in an audit manifest.
Support-aware generation and diagnostics
crates/antlr-rust-codegen/src/driver.rs
Lexer and parser generation now use support roots, embedded actions, semantic policies, support modules, additional inputs, and source-path remapping.
Transformation fixtures and end-to-end validation
README.md, crates/antlr-rust-codegen/README.md, crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/*, crates/antlr-rust-codegen/tests/fixtures/antlr4-rust-gen/rust-support/*
Documentation describes the trust workflow and Python limits. C and Java fixtures and CLI tests validate rejection of untrusted bundles, grammar transformation, source preservation, support wiring, and generated parser execution.

Estimated code review effort: 5 (Critical) | ~90 minutes

Sequence Diagram(s)

sequenceDiagram
  participant User
  participant CLI
  participant Compiler
  participant RustSupport
  participant RustPython
  User->>CLI: provide grammar path and trust fingerprint
  CLI->>Compiler: create RustSupportOptions
  Compiler->>RustSupport: prepare support bundle
  RustSupport->>RustPython: transform staged grammar
  RustPython-->>RustSupport: return transformed grammar and support files
  RustSupport-->>Compiler: provide roots, modules, and manifest
  Compiler-->>User: generate parser and diagnostics
Loading

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 11.76% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: trusted Rust support bundle execution in code generation.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/issue-265-trusted-rust-support

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@codecov

codecov Bot commented Aug 5, 2026

Copy link
Copy Markdown

@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown

📊 Source Code Metrics (this PR vs main)

File Cyclomatic Cognitive Functions LLOC MI
crates/antlr-rust-codegen/src/builder.rs 46 ⚪ 10 ⚪ 24 ⚪ 55 ⚪ 13.59 (main: 13.71) 🔴
crates/antlr-rust-codegen/src/rust_support/mod.rs 136 🆕 94 🆕 23 🆕 160 🆕 0 🆕
crates/antlr-rust-codegen/src/rust_support/identity.rs 96 🆕 54 🆕 22 🆕 154 🆕 0 🆕
crates/antlr-rust-codegen/src/testrig_cli.rs 75 ⚪ 34 ⚪ 21 ⚪ 88 ⚪ 2.42 (main: 2.48) 🔴
crates/antlr-rust-codegen/src/driver.rs 111 (main: 79) 🔴 89 (main: 61) 🔴 9 (main: 7) 🔴 154 (main: 115) 🔴 0 (main: 5.20) 🔴
crates/antlr-rust-codegen/src/rust_support/stage.rs 51 🆕 39 🆕 9 🆕 61 🆕 17.93 🆕
crates/antlr-rust-codegen/src/cli.rs 23 (main: 14) 🔴 13 (main: 6) 🔴 5 (main: 4) 🔴 27 (main: 17) 🔴 17.20 (main: 21.34) 🔴
crates/antlr-rust-codegen/src/rust_support/prompt.rs 26 🆕 18 🆕 5 🆕 31 🆕 27.80 🆕
crates/antlr-rust-codegen/src/lib.rs 3 ⚪ 0 ⚪ 2 ⚪ 4 ⚪ 38.57 (main: 38.77) 🔴
crates/antlr-rust-codegen/src/rust_support/python.rs 11 🆕 7 🆕 1 🆕 27 🆕 36.52 🆕
crates/antlr-rust-codegen/src/config.rs 1 ⚪ 0 ⚪ 0 ⚪ 0 ⚪ 42.33 (main: 43.23) 🔴

Generated by mehen v1.8.1 — the code quality watcher.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 13

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@crates/antlr-rust-codegen/src/cli.rs`:
- Around line 189-195: Update the CLI argument definition and the into_config
method so a --no-rust-support option is accepted and propagated into
RustSupportOptions.enabled. Default the option to enabled for backward
compatibility, but set enabled to false when the opt-out flag is supplied so
Rust support discovery skips trust validation.

In `@crates/antlr-rust-codegen/src/driver.rs`:
- Around line 318-324: Suppress structured positions when the diagnostic source
path is remapped, matching the existing byte_span behavior. Update the
computation around primary and structured_position in the current diagnostic
flow, and apply the same condition in compilation_diagnostics so positions from
staged grammar files are omitted unless they are mapped back to the original
source.

In `@crates/antlr-rust-codegen/src/rust_support/identity.rs`:
- Around line 264-301: Update default_trust_store_path so the Windows fallback
uses USERPROFILE when HOME is unavailable, allowing the AppData\Roaming path to
be constructed on standard Windows environments without HOME. Preserve the
existing APPDATA and non-Windows home-directory behavior.
- Around line 240-261: Update TrustStore::save to re-read the existing
trust-store file immediately before serialization, merge any records added by
other processes into the in-memory state, and then persist the merged contents.
Preserve the current directory creation, temporary-file, and error-handling
behavior while ensuring concurrent approvals are not discarded.

In `@crates/antlr-rust-codegen/src/rust_support/mod.rs`:
- Around line 458-495: Update write_file_name_array to stop unconditionally
expecting UTF-8 file names and instead return an io::Error when path.file_name()
cannot be converted with to_str, since transformed_grammars can reach this path
from the caller. Keep the existing JSON array writing logic in
write_file_name_array and json_string unchanged for valid names, but propagate
the conversion failure through the same error-handling flow used by
rewrite_support_paths rather than panicking.
- Around line 261-267: Update the candidate loop around identify,
stage::copy_grammar_directory, and stage::execute_transform so the grammar is
copied first, then identify the staged Rust directory and call ensure_trusted on
that staged identity. Remove the trust check against the original
support_directory, and execute the transform only after the staged bundle’s
digest has been approved.
- Around line 269-278: The support-file discovery currently reads the original
support directory before transformation, so generated artifacts use stale paths.
Update the flow around execute_transform and rewrite_support_paths to call
top_level_files_with_extension on the staged Rust directory after the transform
completes, then pass that resulting list to rewrite_support_paths and subsequent
artifact aggregation.

In `@crates/antlr-rust-codegen/src/rust_support/stage.rs`:
- Around line 7-15: Add a concise comment immediately before the
fs::create_dir_all call in copy_grammar_directory explaining that transform
scripts expect the staged grammar/src directory to exist. Keep the unconditional
directory creation and surrounding staging behavior unchanged.
- Around line 42-50: Update execute_transform to avoid unbounded Command::output
behavior: spawn the child, drain stdout and stderr concurrently into capped
buffers, and enforce a configurable execution deadline that terminates the child
when exceeded. Preserve the existing bounded diagnostic handling and return an
appropriate io::Error for timeout or child-process failures.
- Around line 78-89: Update top_level_files_with_extension in stage.rs to stop
discarding per-entry read_dir errors; replace the filter_map(Result::ok) path
with error propagation so any failed directory entry returns an io::Error
instead of silently skipping the file. Keep the existing extension filtering,
file collection, and sorting behavior unchanged, and make sure the read_dir
iterator in top_level_files_with_extension is the only place that changes.

In `@crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/rust_support.rs`:
- Around line 41-60: Add a test alongside
noninteractive_bundle_requires_its_exact_fingerprint that invokes the command
with a valid-looking but different sha256: trust value, then assert the command
fails. Reuse the existing temporary grammar, generated-output, trust-store, and
command helpers, and verify the mismatched fingerprint is rejected rather than
accepted.
- Around line 62-129: Update both untrusted invocations in
current_java_transform_runs_from_the_staged_tree and the corresponding test
block to assert !untrusted.status.success() immediately after each run, before
extracting its fingerprint. Use normalize_cli_snapshot on stderr before every
untrusted_fingerprint call, including the existing parsing site near line 56, so
all fingerprint extraction uses normalized CLI output.

In
`@crates/antlr-rust-codegen/tests/fixtures/antlr4-rust-gen/rust-support/c/Rust/transformGrammar.py`:
- Around line 15-20: In the _lt function, remove the unnecessary f-string
prefixes from the chained string fragments that contain no interpolation, while
retaining the f prefix on the fragment that interpolates k.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: dc376cdb-5daa-47b6-b503-c17a92581ad0

📥 Commits

Reviewing files that changed from the base of the PR and between badb7a6 and ac0a06b.

⛔ Files ignored due to path filters (3)
  • Cargo.lock is excluded by !**/*.lock
  • crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/snapshots/antlr4_rust_gen_cli__cli__antlr4_rust_gen_help.snap is excluded by !**/*.snap
  • crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/snapshots/antlr4_rust_gen_cli__rust_support__untrusted_rust_support_diagnostic.snap is excluded by !**/*.snap
📒 Files selected for processing (23)
  • README.md
  • crates/antlr-rust-codegen/Cargo.toml
  • crates/antlr-rust-codegen/README.md
  • crates/antlr-rust-codegen/src/builder.rs
  • crates/antlr-rust-codegen/src/cli.rs
  • crates/antlr-rust-codegen/src/config.rs
  • crates/antlr-rust-codegen/src/driver.rs
  • crates/antlr-rust-codegen/src/lib.rs
  • crates/antlr-rust-codegen/src/rust_support/identity.rs
  • crates/antlr-rust-codegen/src/rust_support/mod.rs
  • crates/antlr-rust-codegen/src/rust_support/prompt.rs
  • crates/antlr-rust-codegen/src/rust_support/python.rs
  • crates/antlr-rust-codegen/src/rust_support/stage.rs
  • crates/antlr-rust-codegen/src/testrig_cli.rs
  • crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli.rs
  • crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/rust_support.rs
  • crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/support.rs
  • crates/antlr-rust-codegen/tests/fixtures/antlr4-rust-gen/rust-support/c/CParser.g4
  • crates/antlr-rust-codegen/tests/fixtures/antlr4-rust-gen/rust-support/c/Rust/c_parser_base.rs
  • crates/antlr-rust-codegen/tests/fixtures/antlr4-rust-gen/rust-support/c/Rust/transformGrammar.py
  • crates/antlr-rust-codegen/tests/fixtures/antlr4-rust-gen/rust-support/java/JavaLexer.g4
  • crates/antlr-rust-codegen/tests/fixtures/antlr4-rust-gen/rust-support/java/JavaParser.g4
  • crates/antlr-rust-codegen/tests/fixtures/antlr4-rust-gen/rust-support/java/Rust/transformGrammar.py

Comment thread crates/antlr-rust-codegen/src/cli.rs
Comment thread crates/antlr-rust-codegen/src/driver.rs Outdated
Comment thread crates/antlr-rust-codegen/src/rust_support/identity.rs
Comment thread crates/antlr-rust-codegen/src/rust_support/identity.rs
Comment thread crates/antlr-rust-codegen/src/rust_support/mod.rs Outdated
Comment thread crates/antlr-rust-codegen/src/rust_support/stage.rs Outdated
Comment thread crates/antlr-rust-codegen/src/rust_support/stage.rs
Comment thread crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/rust_support.rs
Comment thread crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/rust_support.rs

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ac0a06bb1d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread crates/antlr-rust-codegen/src/driver.rs Outdated
Comment thread crates/antlr-rust-codegen/src/rust_support/mod.rs Outdated
Fingerprint the staged bundle bytes that will execute and harvest support modules from post-transform staged state. Bound child runtime and output, propagate filesystem and path errors, and suppress transformed coordinates when diagnostics point back to untouched sources.

Serialize concurrent trust-store updates under a file lock, add the Windows home fallback, and strengthen exact-fingerprint and trust-flow coverage.
Enforce strict grammar options only for staged support sources and retain the caller's semantic policy for mixed-root manifests.

Re-export shipped modules through a stable generated rust_support surface so bundle-level reset and preprocessing helpers remain reachable without consumer module declarations.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4e44822dd2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread crates/antlr-rust-codegen/src/rust_support/mod.rs Outdated
Comment thread crates/antlr-rust-codegen/src/rust_support/stage.rs Outdated
Comment thread crates/antlr-rust-codegen/src/rust_support/stage.rs Outdated
Comment thread crates/antlr-rust-codegen/src/rust_support/mod.rs
Comment thread crates/antlr-rust-codegen/src/rust_support/mod.rs
Derive artifact identities from repository, revision, and bundle path so identical support contents from different grammar directories cannot collide.

Relocate crate-root references inside shipped support modules and prepare the conventional src output directory only when bundle metadata includes Rust modules.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6a0dc192df

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread crates/antlr-rust-codegen/src/rust_support/mod.rs
Comment thread crates/antlr-rust-codegen/src/rust_support/mod.rs Outdated
Comment thread crates/antlr-rust-codegen/src/rust_support/identity.rs Outdated
Encode support path and file lengths as u64 so trusted fingerprints remain target-independent.

Short-circuit exact CLI fingerprints before loading persisted trust state, allowing reproducible CI even when an unrelated user trust store is unreadable or corrupt.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/rust_support.rs`:
- Around line 254-257: Update the parser output assertions in the relevant
rust_support test to build the expected #[path] prefix using the
platform-specific separator and compare it against the generated path via
to_string_lossy(). Remove the hard-coded `antlr-rust-support/` prefix while
preserving the existing assertions for the support module and alias.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 1019d862-c223-455e-9ceb-eaff76d3272e

📥 Commits

Reviewing files that changed from the base of the PR and between ac0a06b and b98e95c.

⛔ Files ignored due to path filters (1)
  • crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/snapshots/antlr4_rust_gen_cli__cli__antlr4_rust_gen_help.snap is excluded by !**/*.snap
📒 Files selected for processing (8)
  • crates/antlr-rust-codegen/README.md
  • crates/antlr-rust-codegen/src/cli.rs
  • crates/antlr-rust-codegen/src/driver.rs
  • crates/antlr-rust-codegen/src/rust_support/identity.rs
  • crates/antlr-rust-codegen/src/rust_support/mod.rs
  • crates/antlr-rust-codegen/src/rust_support/stage.rs
  • crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/rust_support.rs
  • crates/antlr-rust-codegen/tests/fixtures/antlr4-rust-gen/rust-support/c/Rust/c_parser_base.rs

Comment thread crates/antlr-rust-codegen/tests/antlr4_rust_gen_cli/rust_support.rs

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5a1b87fb27

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread crates/antlr-rust-codegen/src/rust_support/mod.rs Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 464149a894

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread crates/antlr-rust-codegen/src/rust_support/identity.rs
@tinovyatkin
tinovyatkin merged commit debc33d into main Aug 5, 2026
13 of 14 checks passed
@tinovyatkin
tinovyatkin deleted the codex/issue-265-trusted-rust-support branch August 5, 2026 13:54
@ophiarch ophiarch Bot mentioned this pull request Aug 5, 2026
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