Repository navigation
fix(minimal): build in release mode again - #3684
bryan-minimal wants to merge 1 commit into
Conversation
The function that decides whether a command prints the native-boxes notice named the spinner run and the answerer aid in its pattern. Both commands exist in debug builds only, so a release build of the crate stopped at "no variant named Spin" and "no variant named DebugAnswererCommand". The other uses of the two names carry the debug gate already. The two names move into a debug-only early return, which keeps the debug behaviour as it was. One test named the answerer aid without the gate as well, which stopped a release build of the tests; it has the gate now. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
|
Approved: no findings at Nothing to do. Clobber: none seen. |
What
maindoes not compile in release mode since #3644. A release build of theminimalcrate stops at:shows_native_boxes_noticeincrates/minimal/src/cmd/mod.rsnamesCommand::SpinandCommand::DebugAnswererCommandin its pattern. Both variants are#[cfg(debug_assertions)], so a release build has no such names. Every other use of the two in that file carries the gate already.The change
The two names move into a debug-only early return at the top of the function. A debug build behaves as before (neither command prints the notice); a release build compiles.
One test in
crates/minimal/src/update_check/tests.rsnamedDebugAnswererCommandwithout the gate as well. That stopped a release build of the tests, and has since #2650. That one assertion has the gate now.15 lines added, 6 removed. No behaviour change in either build mode.
How it was found, and checked
A release build of two unrelated branches failed on this error after they took today's
main. Branches based onmainfrom before #3644 build.With this change: format, clippy, the workspace tests, doctests and the native e2e pass, and the release build of the workspace completes.
Why CI did not catch it
No required check compiles the
minimalcrate with debug assertions off: the CI lanes build the dev profile. The release workflow buildsminwith--release, so the next release or nightly build is the first thing that would hit it. Acheckof the release profile in CI would catch this class of mistake; that is not added here.🤖 Generated with Claude Code
Summary by CodeRabbit