Skip to content

id: ci-check profile for the nix test phase (#3195 phase 1) - #3674

Merged
dezren39 merged 3 commits into
mainfrom
queue/5375-3195-ci-check-profile
Nov 2, 2026
Merged

dezren39 merged 3 commits into
mainfrom
queue/5375-3195-ci-check-profile

Conversation

@dezren39

@dezren39 dezren39 commented Nov 1, 2026 •

Copy link
Copy Markdown
Member

Phase 1 of #3195 (queue task 5375), per the triage pin in task 5367: the nix buildRustPackage check phase was compiling the test suite under the release profile — thin LTO, codegen-units = 1, symbol stripping — and [profile.test] is ignored in release mode, so every check build paid full release codegen for throwaway test binaries.

Changes

  • pkgs/id/Cargo.toml: add [profile.ci-check] — inherits = "release" (opt-level 3 kept, so test behaviour and FUEL_BUDGETS assertions stay release-shaped) with lto = false, codegen-units = 256, strip = false.
  • pkgs/id/default.nix: checkType = "ci-check" on the buildRustPackage derivation, so the cargo check hook runs cargo test --profile ci-check. The release binary build (cargoBuildType) is untouched. The pkgs/id/flake.nix integration-test runner compiles in the debug profile already, so it needs no change.

Verified this shift

  • cargo metadata --no-deps accepts the manifest; the parsed profile is exactly {inherits: release, lto: false, codegen-units: 256, strip: false}.
  • nix-instantiate --eval of the derivation shows cargoCheckType = "ci-check".

Still owed before merge (load-gated, tracked on #3195 / task 5375)

Refs #3195


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

@dezren39
dezren39 requested a review from a team as a code owner November 1, 2026 11:51
@coderabbitai

coderabbitai Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

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

Next included review available in 13 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 0fc481db-af02-464b-8daa-2ace335f07e9
Commits

Reviewing files that changed from the base of the PR and between fddd4ad and 0948694.

Files selected for processing: 3
  • pkgs/id/Cargo.toml
  • pkgs/id/default.nix
  • pkgs/id/flake.nix
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-02T06:10:52.198832Z 0948694 Manual request
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@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: 4051de0b60

ℹ️ 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 pkgs/id/default.nix
# instead of release: same opt-level, no LTO / codegen-units=1 /
# strip costs for test binaries. The release binary build
# (cargoBuildType) is unchanged.
checkType = "ci-check";

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Wire the check profile into the actual flake packages

For the documented nix build and nix build .#id-lib entry points, this setting has no effect: pkgs/id/flake.nix independently defines id-web and id-lib (lines 616–728), both with doCheck = true but neither with checkType. A repo-wide search of Nix sources found no import of this default.nix; the root integration also imports pkgs/id/flake.nix directly. Consequently, normal Nix package builds still compile tests with the expensive release profile, defeating the optimization this change introduces. Set checkType on those flake derivations as well, or share their configuration with this derivation.

AGENTS.md reference: pkgs/id/AGENTS.md:L86-L92

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Fixed in 0948694: checkType = "ci-check" now set on both flake derivations (id-web and id-lib in pkgs/id/flake.nix), which are the actual nix build / nix build .#id-lib entry points; Cargo.toml comment updated to match. A repo-wide search confirms those two plus default.nix are the only buildRustPackage sites for pkgs/id. Load-gated before/after timings (load <20) still pending — task 5375 parked on that gate; @codex review requested on the new head.

Codex P2 on PR #3674: default.nix is not imported by the flake entry
points; pkgs/id/flake.nix defines id-web and id-lib independently with
doCheck=true but no checkType, so nix build still compiled tests in
release. Set checkType = ci-check on both.
@dezren39

dezren39 commented Nov 2, 2026

Copy link
Copy Markdown
Member Author

@codex review — head 0948694 wires checkType=ci-check into the flake packages per your P2 on 4051de0.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Chef's kiss.

Reviewed commit: 09486943b2

ℹ️ 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".

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