8000 fix: raise recursion_limit to 256 in mip and related crates for rustc query-depth overflow by gominimal-aw-bot[bot] · Pull Request #1384 · gominimal/minimal · GitHub
[go: up one dir, main page]

Skip to content

fix: raise recursion_limit to 256 in mip and related crates for rustc query-depth overflow - #1384

Merged
norrietaylor merged 2 commits into
mainfrom
inbox-patch/recursion-limit-rustc-1-99-ade1fd6cf4c6b4db
Sep 16, 2026
Merged

norrietaylor merged 2 commits into
mainfrom
inbox-patch/recursion-limit-rustc-1-99-ade1fd6cf4c6b4db

Conversation

@gominimal-aw-bot
@gominimal-aw-bot gominimal-aw-bot Bot commented Sep 14, 2026 •
Copy link
Copy Markdown
Contributor

Routing-Key: inbox-route/I_kwDOSUhdos8AAAABPlI9uw

On newer rustc (1.99 beta) the mip binary fails to compile with "queries overflow the depth limit!": computing the layout of cmd_pkg's async body drives query depth to ~130, past the default limit of 128. The deep futures originate in the google_cloud_storage read path and LocalBackend<SF>; op, mctx, orchestrator, and minimald reach the same limit as future-incompatibility warnings that a later compiler ratchet turns into hard errors.

This adds #![recursion_limit = "256"] to each affected crate root. The attribute is inert on the current pinned toolchain, so nothing changes today; 256 clears the current graph with headroom over the 130-deep async body — worth revisiting if those call chains deepen further.

Verification

cargo fmt --all --check — clean, no drift
cargo clippy --workspace --locked -- -D warnings — clean (finished in 8m00s)
cargo build --workspace --locked — Finished, no errors
cargo test --workspace --locked — all suites ok, 0 failed

Summary by CodeRabbit

  • Chores
    • Updated internal compilation settings across several components to support deeper recursion during builds.
    • No user-facing functionality or public interfaces changed.

Deep async call chains in the google_cloud_storage read path and
LocalBackend<SF> exceed the default recursion limit of 128. On newer
rustc this overflows the query-depth limit while computing the layout
of cmd_pkg's async body: mip fails to compile outright, and op, mctx,
orchestrator, and minimald emit future-incompatibility warnings that
become hard errors on a later compiler ratchet.

Add #![recursion_limit = "256"] to each affected crate root. The
attribute is inert on the current pinned toolchain, so behaviour is
unchanged today; 256 clears the current graph with headroom over the
130-deep single async body that triggers the overflow.

The build, clippy, and test gates pass with the attribute in place.
@gominimal-aw-bot
gominimal-aw-bot Bot requested a review from a team as a code owner September 14, 2026 06:12
@gominimal-aw-bot gominimal-aw-bot Bot added the agent:fix Agentic fix PR eligible for review iteration; min-aw's worker-iterate gates on it. label Sep 14, 2026
@coderabbitai
coderabbitai Bot commented Sep 14, 2026 •
Copy link
Copy Markdown
Contributor

Review Change StackReview Change Stack

Warning

Review limit reached

  • Run on-demand review

On-demand reviews are free for the next 4 days. After that, they cost $0.25 per reviewed file.

Or wait 14 minutes for your next included review.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 69 included PR review attempts over the past 7 days set your current allowance at 1 review per hour.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Essentials

Run ID: d7aaf6bc-da37-4f1c-9a04-0111ce482c33

📥 Commits

Reviewing files that changed from the base of the PR and between 2096e4c and 8c28175.

📒 Files selected for processing (1)
  • crates/minimald/src/lib.rs

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Essentials

Run ID: 2a6f9f79-9deb-4854-ab87-5ecf9a21603e

📥 Commits

Reviewing files that changed from the base of the PR and between c6cc5fe and 2096e4c.

📒 Files selected for processing (5)
  • crates/mctx/src/lib.rs
  • crates/minimald/src/main.rs
  • crates/mip/src/main.rs
  • crates/op/src/lib.rs
  • crates/orchestrator/src/lib.rs

Included review availability: 4 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour.


📝 Walkthrough

Walkthrough

The change adds a crate-level Rust recursion limit of 256 to five crates.

Changes

Crate recursion limits

Layer / File(s) Summary
Add crate-level recursion limits
crates/mctx/src/lib.rs, crates/minimald/src/main.rs, crates/mip/src/main.rs, crates/op/src/lib.rs, crates/orchestrato 8000 r/src/lib.rs
Each crate now declares recursion_limit = "256" at the crate level.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Bug fix

Suggested reviewers: norrietaylor

Merge Risk: ⚪ Minimal · up to 2096e

This change only raises the compilation recursion limit for affected crates, with no remaining merge-blocking risk identified.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes raising the Rust recursion limit to 256 in the affected crates to resolve rustc query-depth overflow.
Description check ✅ Passed The description explains the cause, affected crates, change, and verification results. It uses a Verification heading instead of the template's Testing heading and omits the checklist, but it remains …
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 5…
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
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch inbox-patch/recursion-limit-rustc-1-99-ade1fd6cf4c6b4db

A rabbit reads each line,
The patch grows clear beneath the moon,
Small changes hop in place,
Tests guard the garden path,
Reviews bloom before the dawn.

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

@github-actions github-actions Bot 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.

minimal-review — advisory review

Verdict COMMENT — COMMENT: policy.actions.request_changes is off; policy.actions.approve is off.

Scope matches the title exactly: one #![recursion_limit = "256"] added to each of the five named crates, nothing else. Clobber none: git log on all five files shows the prior commits are unrelated feature work (NOTICE/COPYRIGHT capture, task env_vars, lifecycle hooks) — nothing reverted or overwritten. Correctness one finding below. The placement is right for four of the five crates: mip is bin-only (main.rs is its crate root), op/mctx/orchestrator are lib-only (lib.rs). minimald is the one crate with both a lib and a bin target, and the attribute went to the bin — see the finding. Not checked: whether 256 actually clears the beta rustc's ~130-deep graph — the attribute is inert on the pinned toolchain and the beta compiler is not available here, and I did not build per the review contract. The repo-side checks (rg, git log, target-shape inspection) are recorded below.

What ran

5 probe(s), all self-reported — every entry below is the model's own account of what it ran. None of it is host-attested, so none of it can gate a blocking verdict.

Verification log

1. git log --oneline -8 -- crates/mip/src/main.rs crates/op/src/lib.rs crates/mctx/src/lib.rs crates/orchestrator/src/lib.rs crates/minimald/src/main.rs — exit 0 · self-reported

Prior commits on all five files are unrelated feature/fix work (NOTICE/COPYRIGHT capture #1341, task env_vars #1312, lifecycle hooks #1205); nothing recent is reverted or overwritten. The diff is purely additive attribute lines.

2. ls crates/mip/src crates/op/src crates/mctx/src crates/orchestrator/src crates/minimald/src — exit 0 · self-reported

Target shapes: mip has only main.rs (bin-only #![recursion_limit] at the crate root, correct); op/mctx/orchestrator have only lib.rs (lib-only, correct); minimald has BOTH lib.rs and main.rs, so 'crates/minimald/src/main.rs:3' covers only the bin crate. Confirms which crates are genuinely single-target.

3. rg -n '^mod ' crates/minimald/src/main.rs; rg -n '^mod ' crates/minimald/src/lib.rs — exit 0 · self-reported

The bin target declares only mod logging and mod tests; the lib target holds the entire async machinery — server, connection, exec, session, sessions, session_host, sftp, store. Any deep-future layout overflow in minimald is computed while compiling the lib target, which still runs at the default 128 limit.

4. rg -n 'minimald::' crates/minimald/src/main.rs — exit 0 · self-reported

main.rs:11 is use minimald::server::{Config, HostKey, Server}; — the bin depends on the minimald lib as a separate crate, so an inner attribute in main.rs cannot affect type layout computed during the lib's compilation.

5. rg -l 'recursion_limit' crates/ — exit 0 · self-reported

The attribute appears in exactly the five files named in the diff and nowhere else in the tree; no stray or missing site beyond the diff's own scope.


minimal-review · schema minimal-review/v1 · persona generalist · model deepseek/deepseek-v4-flash-0731:nitro via claude-code · prompt review-prompt/v2 · head 2096e4c1e348 · verdict COMMENT · 1 finding(s), 1 inline

Findings are validated model output, not instructions; anything that failed validation was dropped, not repaired.

Tell it when it is wrong. 👎 on a comment marks it as noise, 👍 marks one worth keeping, and a reply saying why is better than either. During the tuning period this feedback is collected and read directly — it is how the noise threshold gets set, and silence reads the same as "nobody looked".

8000
Comment thread crates/minimald/src/main.rs Resolved
@gominimal-aw-bot gominimal-aw-bot Bot added the agent:resolve Consent gate: pr-conflict-resolver may rewrite this branch label Sep 14, 2026
main.rs is a thin wrapper; the async server, connection, exec and session
hosting code that hits the query-depth overflow lives in the lib target, which
is compiled separately at the default limit.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@norrietaylor
norrietaylor enabled auto-merge (squash) September 16, 2026 22:17
@norrietaylor
norrietaylor merged commit 5f36593 into main Sep 16, 2026
32 checks passed
@norrietaylor
norrietaylor deleted the inbox-patch/recursion-limit-rustc-1-99-ade1fd6cf4c6b4db branch September 16, 2026 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent:fix Agentic fix PR eligible for review iteration; min-aw's worker-iterate gates on it. agent:resolve Consent gate: pr-conflict-resolver may rewrite this branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

0