Repository navigation
fix(test): make PyPI fixture platform boundaries portable - #4911
Conversation
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
Warning Review limit reachedNext included review available in 16 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (2)
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. Comment |
EffortlessSteven
left a comment
There was a problem hiding this comment.
reviewed_head_sha: fbe21d4
integration_basis: Linux CI checkout 6f9da16, tree 76cc77848970c769eb526ad46cfcb7f77d6db75a, parents aad6028 + reviewed head.
claim_boundary: Unix-only live identity helpers are cfg-scoped; portable PATH fixtures use native split_paths/join_paths and reject planted/ambient executables. No production change.
changed_surfaces_and_semantic_owners_inspected: complete identity.rs/isolation.rs diff, all live/support callers, resolver and portable fixture/oracle controls; root substantive exact-head counterreview completed.
blocking_findings: none.
non_blocking_suggestions: none.
refuted_or_stale_findings: prior missing local target setup, colon-split Windows fixture failure and introduced ignored-error lint were retained and repaired; current proof establishes their dispositions.
proof_and_ci_observed: Windows targeted strict Clippy, 13 portable tests (0 ignored), doctor, fast15 and six precommit commands PASS with independently matched 1125 rows/1127 path union. Current Linux required run36558607111 terminal SUCCESS; actual JUnit10087/0 failure/0 error/0 skip, all14 named PyPI tests PASS including local wheel pip/uv live test. Actual CI owner blobs match both reviewed files.
proof_or_review_missing: automated reviewer quota is missing automated review, not a clean review; substantive root review supplies the current disposition.
affected_currentness_dimensions: source, platform fixture setup, test stimulus/oracles, exact-head and combined checkout proof reviewed.
residual_assumptions_and_non_claims: no Windows live PyPI support, release qualification, or general installation claim. SDK prerequisite only; its own review remains separate. Reverting these test-only edits restores prior fixture behavior.
disposition: REVIEW_READY.
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: fbe21d4869
ℹ️ 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".
| return None; | ||
| } | ||
| let candidate = Path::new(entry).join(name); | ||
| let candidate = entry.join(name); |
There was a problem hiding this comment.
Resolve Windows executable suffixes on PATH
Failure mode: On Windows, entry.join(name) checks only extensionless cargo, rustc, and ripr, so require_clean_consumer_path accepts normal cargo.exe/rustc.exe installations and the installed/planted checks cannot find ripr.exe; the new Windows tests conceal this by creating extensionless files. Why here: These portable controls therefore do not discriminate the Windows behavior they claim to test. Fix direction: follow the existing PATHEXT-aware lookup in crates/ripr/src/output/doctor_binary.rs::ripr_executable_names/first_on_path, and make the Windows fixtures use .exe names. Validation: rerun cargo test -p ripr --test pypi_consumer --features lang-python on native Windows with .exe controls. Confidence: High.
AGENTS.md reference: AGENTS.md:L162-L167
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Decision
- Needs reviewer attention before upstream: findings remain.
Confirmed findings
- path_env() into_string() fallback returns a static 'fixture PATH is not UTF-8' error; this branch is not exercised by any of the 13 portable controls. If a CI host ever produces non-UTF8 temp paths, require_clean_consumer_path tests would fail with that sentinel rather than the expected message; coverage gap is latent but not trust-affecting.
Refuted
- assertion ordering in planted-first PATH check might be tautological with the existing installed-first check; refuted because: wrong_path vector is planted_parent-first while the existing assertion is installed_parent-first; sentinel check is distinct.
- Temp-root cleanup (remove_dir_all) errors are still swallowed at the three call sites after removal of let _ =.; refuted because: Refuted by diff inspection: all three cleanup call sites were rewritten to propagate remove_fixture(&root)? or fs::remove_file(&installed).map_err(...). No additional let _ = fs::remove_dir_all remains.
Evidence gaps
- Model proof intent was rejected by deterministic validation.
Summary
Gate Unix-only PyPI identity helpers consistently with their existing Unix-only live/support consumers. Portable identity, isolation and oracle controls remain enabled on Windows.
Swarm / Source Boundary
Source-of-truth Links
Governing issue: #4910; inherited contract: #4626 / #4848.
Dependent SDK guard: #4899.
Acceptance delta: strict Windows compilation has no unused Unix-only fixture helpers, while Unix live consumers and portable oracles retain their existing behavior.
Candidate Relationships
Candidate: codex/pypi-unix-identity-cfg,fbe21d4869f305a9551842feba83729af29c6091.
Base: immutable main7f5e6e7249cad0ba9f23491864f8bb3ea2eb0592.
Prerequisite for #4899 owning Windows guards, not a replacement or SDK source change. Current all-state claim search found no equivalent active repair.
Scope
Five cfg(unix) attributes align identity.rs imports/helpers with Unix consumers. Isolation.rs now uses native split_paths and fallible join_paths for portable fixtures, retaining empty-entry refusal and adding planted-first rejection within an existing test. Clock, unique fixture creation, and successful cleanup fail explicitly.
Scope Classification
Production delta: none.
Evidence delta: align fixture item availability and PATH parsing with the host platform. All13 portable controls retain their meanings; the previously failing isolation controls still require installed/planted ordering and fail-closed sentinels.
Single acceptance: Windows strict Clippy and all13 portable controls pass without suppressions; Unix consumers and their existing behavior remain valid.
Non-goals: Windows live pip/uv journey, publication, dependencies, SDK protocol behavior, control weakening.
Support-tier Impact
No Windows live-install or release support claim.
Policy Impact
No lint suppression, exception, dependency, process or network surface added.
Proof
rustfmt --edition 2024 crates/ripr/tests/pypi_consumer/identity.rs: PASS.
git diff --check: PASS.
Current fbe21 Windows targeted Clippy, all13 portable controls, worktree doctor, check-fast and precommit: PASS. Native current-main baseline before edits was not run; source-identical preceding failure and every failed attempt remain retained. Historical290aa v2 stopped before runtime with LINK1104 because the new worktree lacked the Cargo-forced local TEMP directory. Creating only that owned directory preserved source/config. The recovered290aa v3 attempt passed native Windows targeted Clippy, then executed13 controls:11PASS/2FAIL/0ignored. Both failures exposed Windows drive-prefix loss from colon PATH splitting; later guards were NOT_RUN. That actual failure and both scratch fixtures remain retained. The90c v4 attempt failed targeted Clippy before runtime on an introduced map_err_ignore wildcard. This successor changes only that binding to a named ignored value, retaining its static redacted message. The exact fbe21 v5 attempt then passed targeted native Windows Clippy and all13 controls with zero failures/ignores/filtered tests. Doctor passed; check-fast ran15 expected gates with no skips and independent1125-path selector. Precommit passed all six exact commands, complete1125 changed rows /1127 old-new path union, no limits/skips. Five phasePIDs were absent and scoped target images empty at11:15:31Z before lease release. Linux current full required evidence remains pending; the Rust-only feature lane does not qualify Python-enabled consumers.
Historical SDK3f strict workspace/all-target Clippy failed on this exact inherited identity blob: EXECUTABLE:11, sha256_bytes:29, sha256_file:35 dead_code. Its preceding focused SDK controls passed; precommit was not run. Source blob comparison matches landed4848 and this candidate parent, but is not an executed current-main baseline.
Prepared Windows proof: cargo clippy -p ripr --test pypi_consumer --features lang-python -- -D warnings; cargo test -p ripr --test pypi_consumer --features lang-python; owning worktree doctor/check-fast/precommit with independently retained selector inventory. Linux hosted execution must retain the Unix consumers before merge.
Claim Boundary
SOURCE_CLEAR / REVIEW_INCOMPLETE. Exact fbe21 native Windows targeted Clippy and13 portable controls passed; owning fast/precommit receipts passed. These establish this fixture platform seam only. Current Linux full-required/Unix journey evidence is still pending. No merge readiness, Windows live-install, release or SDK qualification claim.
Rollback
Ordinary revert of the fixture platform change; no persisted data or release action.
Spec-Test-Code Traceability
Static Language Check
CI Economics
n/a: no workflow, routing, artifact, or branch-protection changes.
Engineering Check
Gates
cargo fmt --checkcargo check --workspace --all-targetscargo test --workspacecargo clippy --workspace --all-targets -- -D warningscargo doc --workspace --no-depscargo package -p ripr --listcargo publish -p ripr --dry-runcargo xtask check-static-languagecargo xtask check-doc-artifactscargo xtask check-support-tierscargo xtask check-no-panic-familycargo xtask check-allow-attributescargo xtask check-local-contextcargo xtask check-file-policycargo xtask check-covered-bycargo xtask check-executable-filescargo xtask check-workflowscargo xtask check-spec-formatcargo xtask check-spec-numberingcargo xtask check-fixture-contractscargo xtask check-generatedcargo xtask check-badge-diff-policycargo xtask check-generated-cleancargo xtask check-dependenciescargo xtask check-process-policycargo xtask check-network-policyExtension changes:
cd editors/vscode && npm cicd editors/vscode && npm run compilecd editors/vscode && npm run package