Skip to content

rules: build-artifact hygiene, attestation gates, and stale-artifact pruning - #9

Merged
shinaoka merged 1 commit into
mainfrom
codex/build-artifact-hygiene
Aug 8, 2026
Merged

rules: build-artifact hygiene, attestation gates, and stale-artifact pruning#9
shinaoka merged 1 commit into
mainfrom
codex/build-artifact-hygiene

Conversation

@shinaoka

@shinaoka shinaoka commented Aug 8, 2026

Copy link
Copy Markdown
Member

Summary

Adds shared policy for a failure mode observed this week: tenferro-rs keeps local builds lean (debug = 0 dev/test, [profile.ci] with strip = "symbols") as repository practice, but the practice was never shared, and tensor4all-rs independently adopted the opposite ([profile.release] debug = true plus release-mode-tests-by-default), producing a 14 GB target/ (12 GB release, including 7 orphaned feature/rev variants of one rlib totaling 596 MB).

rules/common/docs-and-tests.md (Local And Hosted Validation):

  1. Default build profiles carry no full debug information; opt-in variants for debugger sessions; line-tables-only usually suffices for backtraces; comprehensive-CI profiles strip symbols.
  2. When hosted CI owns a measurement (coverage is the canonical case), the local gate may be attestation-based, but the attestation must be an explicit flag and the check must fail when absent (the check-pr-fast.sh --coverage-reviewed pattern).
  3. Stale-artifact pruning must be documented; no profile setting removes artifacts orphaned by dependency rev/feature churn.

rules/rust/performance.md (new section Build Profiles And Target Hygiene): the concrete Cargo shape of the above.

Enforcement split (discussed in session): prose policy here; per-repo checks in each repository's scripts; periodic verification belongs to the planned single private audit-bot repository (tracked separately).

No index.md changes, so this does not conflict with #8.

🤖 Generated with Claude Code

Local And Hosted Validation gains three policies distilled from the
tenferro-rs/tensor4all-rs build-size comparison: default profiles carry no
full debug info (opt-in debug variants instead), CI-owned measurements may
be gated locally by explicit attestation, and stale-artifact pruning must
be documented. rust/performance.md adds the concrete Cargo profile shape
(dev/test debug=0 with assertions kept, release line-tables-only with a
release-debug variant, CI strip=symbols) and the rev-churn orphan warning.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
shinaoka added a commit to tensor4all/tensor4all-rs that referenced this pull request Aug 8, 2026
Local target/ reached 14 GB, 12 GB of it release artifacts, because
[profile.release] carried debug = true while repository policy runs the
normal verification suite in release mode. Release now uses
line-tables-only, which keeps file:line RUST_BACKTRACE output; a new
release-debug profile inherits release with full debug info for debugger
sessions. dev/test pin debug = 0 while keeping debug assertions and
overflow checks, matching the shared build-artifact hygiene rule
(tensor4all/tensor4all-agent-rules#9) and tenferro-rs practice.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
@shinaoka
shinaoka merged commit a550779 into main Aug 8, 2026
1 check passed
@shinaoka
shinaoka deleted the codex/build-artifact-hygiene branch August 8, 2026 18:08
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