Repository navigation
Clean up Factory skills after unit tests finish - #1930
Merged
Merged
Conversation
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A completed unit-test process left its Factory skills extraction in TMPDIR because static values are not dropped at process exit.
Closes #1913
Test seams: the existing Session subprocess entry point with a private TMPDIR; public Factory skills linking across overlapping test users; an ordinary Run through Scenario with its private TMPDIR.
Evidence
Execution evidence
cargo test --bin thirdshift session::execution_tests::session_subprocess_removes_its_factory_skills -- --exact --nocapturefailed withFactory skills left behind: ["thirdshift-skills-acWAv6"](0 passed; 1 failed).After: the same command passed (
1 passed; 0 failed).TMPDIR: it passed but left 7 extractions before the fix (one per current Harness), and left 0 after it.cargo test --bin thirdshift skills::tests -- --nocapture: 6 passed, including overlapping users retaining one extraction until the last finishes.cargo fmt --checkpassed.TMPDIR,--test-threads=3: 1,684 passed, 3 ignored; 0 Factory skills entries left (666.79 seconds, execution only).TMPDIR: passed; 0 Factory skills entries left by each.HOMEand the installedCARGO_HOME/RUSTUP_HOME. An initial run inherited the operator's admission limits; its toolchain fixture also neededRUSTUP_HOMEset. That fixture passes with the installed root, and the full unit rerun above passes.cargo nextest runpassed on exact headded15db6eb0d1992c8bd5262624963a23115a545: 3,960 passed, 92 skipped. Test execution took 1,297.727 seconds, plus 73 seconds of compilation (about 1,372 seconds for the command including compilation).scripts/affected-tests mainselected that same full Rust suite locally. After CI passed the exact head, the duplicate local run was intentionally stopped, followingdocs/testing.md's CI-reuse guidance. Its/usr/bin/time -pwall time was 1,681.56 seconds including cached compilation; this interrupted run is not reported as a local pass.Integration TMPDIR inventory
Each built test binary ran with
--test-threads=3and a fresh privateTMPDIR(python3 /tmp/issue-1913-validation.py integrations). All 23 exited successfully.security_reviewsecurity_runsession_tracessetupsetup_lifetimesetup_offershare_cardshow_logssite_deployskillspec_1796spec_push_racespec_review_706_regressionsspec_runstandards_1795statusstoptoolchaintriage_runtrialtrial_scopeupdateuser_configUnaddressed findings
Standards
None. The Standards reviewer raised 0 findings.
Spec
None. The Spec reviewer raised 0 findings.
Security
None. The Security review found no unaddressed introduced findings.
Security review outcome
No unaddressed introduced findings.
Review coverage
Both independent reviewers read all six changed files:
src/skills.rs,src/skills/testing.rs,src/skills/tests.rs,src/session/execution_tests.rs,src/session/private/tests.rs, andtests/fresh_run.rs. Unread changed files: none. Generated-output exclusions: none.Merge Danger
Door: two-way
Blast Radius: tests
Built with codex codex-cli 0.164.0 · gpt-6.1-sol · xhigh