You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
test(layout): verify offline inspection and compatibility regressions - #226
Closes#216. Related tracking issue: #130 remains in progress; final documentation #217 and the separate 0.3 removal #209 are not included.
Prerequisites #215 and #208 merged through #224 and #225. Implements the approved section-10 fixture/measurement protocol without inventing numerical release thresholds.
Seven real public BusyBox metadata documents retained with exact digest verification. Local payload stand-ins are two bytes; only dependent sizes change. No downloaded image layers are committed or needed.
72 integrated cases (71 on Mac plus one Linux-only RSS case) verify selected SDK/CLI bytes, exact statistics, provenance, limits, diagnostics/streams, safe ASCII/JSON, immutable stored bytes/modes/identities/timestamps, forbidden IO/effects and legacy compatibility. Negative cases cover cached Python 3.10 pathlib, credential bindings, inherited RSS, native/positional/vectored reads, extra descriptor wrappers, constructor reads, worker failure retention, full-path stat/lstat cache checks, complete fingerprint coverage and early threshold rejection.
Fresh-process all-four-view resource harness checks exact 1,024-wide/100-by-64-reuse counts and per-address IO, recording one warm-up and five samples per view, median/maximum elapsed and peak RSS bytes.
Linux/Python 3.12 CI enforces owner-approved resource limits and retains evidence even on failure; minimum Click and Windows rejection selectors include the new suite. macOS measurements/validation are local. Existing hosted platform jobs remain unchanged.
Related library/developer reference documents fixture limitations and reproducible baseline/approved-threshold reruns.
Validation
Current head 687ec17f270613a4a0131d5ab29347d0aaf073ba, local Mac/Python 3.12.4: 71 integrated cases pass, one Linux-only RSS case skipped. Every numeric cap unchanged. Historical broader regressions are not claimed as a current-head rerun.
Scoped Ruff lint/format, mypy, Bandit, actionlint/yamllint, fixture JSON and whitespace checks passed. mypy skips untyped external JSON Schema imports; Bandit skips normal test assertions and reviewed non-shell local subprocess calls.
Source contracts: every new module/type/callable/helper documented and placement checked; behavior reviewed against signatures and tests. No production SDK/CLI behavior or dependencies changed.
Isolated development dependencies satisfy declared constraints after restoring packages via pip. Newer Click emits existing deprecation warnings; these are not test failures.
Local self-review of the current fix has no unresolved findings. Both Copilot guard findings were fixed with negative tests and separately replied with the pushed SHA before resolution.
Current-head hosted Tests pass all active jobs; Python 3.12 full suite: 5,289 passed, five skipped. CodeQL passed. Actual exact-head Copilot review has no open code issues; its final-resource-evidence concern is satisfied by both independently verified fresh reports below. Codex quota exhausted, no Codex approval claimed.
The fingerprint now includes complete driver bytes, fixture/IO builder, shared descriptor/address helper source and pinned metadata; timing/sample-count/RSS/fixture-helper changes invalidate approval. Threshold JSON, revision/platform/approval identity and all finite caps are validated before setup/workers, and the loaded limits are reused. Pytest runs first, the Linux resource gate runs with always() on 3.12, and artifact upload stays last.
Actual review 6081285634 identified shared fixture helpers omitted from the fingerprint. Reproduced and fixed in signed 36dd08ace44c35f45c0dc5eefe57a2a4f73578ed, with a fourth input-mutation regression and pushed-fix follow-up in the original fingerprint thread.
Stored-byte expectations now use independent pre-inspection fixture bytes, excluding the intentionally unvisited subject-only object. Linux peak RSS now uses post-exec VmHWM, not an inherited getrusage floor; the retained-parent-allocation regression passes in Linux CI.
Historical baselines/results remain in the canonical issue state/checkpoints; they are not presented as final-revision certification.
Evidence checked for credentials/provider tokens/private keys/authorization headers and secret-bearing URLs before persistence; no redactions needed. No configured docs build and no dependency audit claimed.
Approved resource limits and final-head evidence
The owner renewed the exact unchanged table for complete driver/builder/shared-helper/metadata fingerprint 56f6df80194c60888a9e8464b72905d786194490ff4d424d7d35848180619e66. Signed binding commit 687ec17f270613a4a0131d5ab29347d0aaf073ba is published. Both platform files match the actual approval; every numeric value is unchanged.
Fresh exact-final-head local-Mac report passes all 24 approved comparisons, with twelve five-sample cases and verified 687ec17/56f6df80/7205440161 provenance. Hosted Linux artifact 15159997089 also passes all 24 recomputed comparisons; stored checks match and integration merge f3377c26116dc281cb022681448038354ccabdfc has exactly main 7aa2f30dbb300c609c5e9f7d59cb14990e024542 and PR head 687ec17f270613a4a0131d5ab29347d0aaf073ba as parents. Both complete reports and the authentic approval match the four-source fingerprint. 48 approved comparisons pass. The preapproval baseline remains explicitly historical and unapproved when measured.
Merged normally after all exact-head/base/check/thread/review/resource gates passed as verified signed 17f82710. The merge tree exactly matches tested head 687ec17 and main contains it. #216 is closed; its eleven original obligations are reconciled through new completion evidence. No force merge, release, sibling implementation or parent close-out. Owned worktree clean, no unpublished commits; checkout/branch/claim retained.
Keep the internal sample protocol in a basename-scoped temporary namespace with enumerated shapes. Validate descriptor path components with the existing digest_parts guard and reject traversal before metadata reads.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
Inspection guards miss payload reads via builtins.open and Path.read_bytes() and credential lookup via RegistryClient’s imported binding, allowing prohibited operations to escape detection.
Adds offline regression and resource-measurement coverage for RegShape’s local OCI layout inspection under #216, without changing production SDK/CLI behavior or dependencies.
Changes:
Adds deterministic fixtures, including digest-pinned BusyBox metadata with minimal local payload stand-ins.
Tests SDK/CLI consistency, counts, limits, diagnostics, preservation and legacy compatibility.
Adds fresh-process resource measurements, Linux CI evidence retention and rerun documentation. Performance approval still requires owner-approved thresholds and passing reruns.
Guard builtins/io file opens and transport-bound credential lookup, with negative regressions. Workers inherit the owned fixture cwd instead of accepting paths. Retain Linux measurements before the longer full pytest step.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
The tests lack independent stored-byte verification and complete I/O guards, while Linux peak-memory measurements can be inflated by retained parent allocations.
On Linux, ru_maxrss can include memory inherited before exec, so retaining the prechecked SDK graph in measure() can inflate an otherwise unchanged child's reported peak. This makes Linux baselines and later RSS gates depend on the parent's memory usage. Read Linux's post-exec VmHWM, retain getrusage on macOS, and add a regression checking that a large retained parent allocation does not inflate the reported child peak.
Use independent fixture sizes to verify stored-byte totals
This expected value repeats the exact calculation used by summarize_layout (summary.py:215), using the same SDK storage facts. If inspection caches an incorrect file size, both sides change together and this regression still passes. Compare the total against independent fixture file sizes so the stored-byte statistic is actually verified across this family, including shared and incomplete layouts.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
The benchmark can inflate Linux worker memory measurements through an inherited ru_maxrss floor, making memory-cap validation unreliable until it uses the worker’s /proc/self/statusVmHWM.
No open issues 🎉
1 previously missed issue
In code that hasn't changed since last review
Linux worker RSS measurement includes inherited parent memory
On Linux, ru_maxrss can retain a pre-exec RSS floor inherited from the parent rather than report only the worker's peak. Because measure() keeps the expanded SDK graph alive while launching workers, this can inflate the measurements used to approve memory caps. Read the worker's /proc/self/statusVmHWM on Linux and retain getrusage on macOS.
Guard pathlib cached opens on Python 3.10, verify stored-byte totals from fixture snapshots rather than SDK facts, and use Linux post-exec VmHWM with a retained-parent-allocation regression. Preserve macOS byte-unit getrusage.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Owner-approved time/RSS thresholds and fresh Linux/local-macOS reruns remain pending, while the CI run predates the pathlib fix and cannot verify exact-head Python 3.10 compatibility.
Bind Linux and local macOS limits to the approved fixture revision and recorded issue approval. Enforce Linux limits in the existing CI sampler and document local Mac reruns.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Count actual native metadata opens and track direct os.read bytes, including existing-handle rereads. Add sampler regressions that preserve SDK output while triggering the precise cache/byte-budget failures. Instrumentation revision renewal is required before publication with approved caps.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Retain owner-approved numerical caps and bind both platforms to the explicitly renewed instrumentation revision for #216.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because unaccounted positional reads and additional descriptor wrappers can let the sampler accept duplicate metadata I/O despite unchanged output.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because reads before _Stream attachment can go uncounted, allowing duplicate metadata reads to pass the sampler’s verification checks.
Observe binary metadata reads before SafeFile construction and reuse the same observer in the SafeDirectory context. Preserve close/seek/context behavior and reject unobserved streams so early reads cannot pass the sampler gates for #216.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Keep every cap unchanged and bind both platforms to the explicitly approved factory-time observer revision for #216.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because worker failures can lose captured diagnostics and leave incomplete reports, obscuring the underlying correctness or I/O failure.
Retain captured stdout/stderr, case and iteration plus partial measured evidence before raising an explicit worker failure for #216. IO instrumentation and approved fixture revision remain unchanged.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because a moderate finding omitted from the published review shows that repeated full-path stat calls can evade the sampler’s per-address cache check.
Normalize supported pathname forms and route cached pathlib accessors through one observed native stat factory. Add eight sampler regressions for full-path stat/lstat observations and surface the cache-guard failure explicitly. Keep this changed instrumentation unpublished until numerical approval is renewed for #216.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Bind the unchanged Linux and Mac caps to explicitly renewed approval 7180329437 and corrected full-path stat/lstat fingerprint 20f129 for #216.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human review is needed because the reported Linux/macOS resource passes predate the renewed stat/lstat observer, leaving final-revision verification against the updated limits unconfirmed.
Include the entire benchmark driver in the approval fingerprint, validate thresholds before fixtures or worker processes, and run pytest before the always-run Linux resource gate. Add focused revision and invalid-threshold regressions for the three review findings on #226.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Bind both unchanged platform tables to full driver/builder/metadata revision 79bac092 and explicit owner approval 7204970937 for #216. No numeric values changed.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because fixture helpers omitted from the fingerprint can change manifest digests without changing the revision, allowing threshold preflight to accept changed fixtures under an old approval.
Include shared address and descriptor source in the approval fingerprint; add an input mutation regression and document the complete fixture source boundary.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Record owner approval 7205440161 for the four-source fixture/measurement fingerprint; preserve every Linux and local-Mac numerical cap.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Required final-head Linux and local macOS resource reports remain pending and cannot be validated here, so a human must verify them against the renewed limits before approval.
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
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.
Scope
Closes #216. Related tracking issue: #130 remains in progress; final documentation #217 and the separate 0.3 removal #209 are not included.
Prerequisites #215 and #208 merged through #224 and #225. Implements the approved section-10 fixture/measurement protocol without inventing numerical release thresholds.
Validation
687ec17f270613a4a0131d5ab29347d0aaf073ba, local Mac/Python 3.12.4: 71 integrated cases pass, one Linux-only RSS case skipped. Every numeric cap unchanged. Historical broader regressions are not claimed as a current-head rerun.a9ef528330e5e1c9630ef6f93ecd90cbc403835c, each replied before resolution: driver fingerprint, pytest/resource ordering, threshold preflight.always()on 3.12, and artifact upload stays last.36dd08ace44c35f45c0dc5eefe57a2a4f73578ed, with a fourth input-mutation regression and pushed-fix follow-up in the original fingerprint thread.VmHWM, not an inheritedgetrusagefloor; the retained-parent-allocation regression passes in Linux CI.Approved resource limits and final-head evidence
The owner renewed the exact unchanged table for complete driver/builder/shared-helper/metadata fingerprint
56f6df80194c60888a9e8464b72905d786194490ff4d424d7d35848180619e66. Signed binding commit687ec17f270613a4a0131d5ab29347d0aaf073bais published. Both platform files match the actual approval; every numeric value is unchanged.Fresh exact-final-head local-Mac report passes all 24 approved comparisons, with twelve five-sample cases and verified 687ec17/56f6df80/7205440161 provenance. Hosted Linux artifact 15159997089 also passes all 24 recomputed comparisons; stored checks match and integration merge
f3377c26116dc281cb022681448038354ccabdfchas exactly main7aa2f30dbb300c609c5e9f7d59cb14990e024542and PR head687ec17f270613a4a0131d5ab29347d0aaf073baas parents. Both complete reports and the authentic approval match the four-source fingerprint. 48 approved comparisons pass. The preapproval baseline remains explicitly historical and unapproved when measured.Merged normally after all exact-head/base/check/thread/review/resource gates passed as verified signed 17f82710. The merge tree exactly matches tested head 687ec17 and main contains it. #216 is closed; its eleven original obligations are reconciled through new completion evidence. No force merge, release, sibling implementation or parent close-out. Owned worktree clean, no unpublished commits; checkout/branch/claim retained.