Skip to content

test(ccv2): add isolated build cleanup fixtures and races - #16

Merged
anilkreddy merged 3 commits into
mainfrom
feat/build-cleanup-scenarios
Nov 14, 2026
Merged

anilkreddy merged 3 commits into
mainfrom
feat/build-cleanup-scenarios

Conversation

@anilkreddy

@anilkreddy anilkreddy commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

CCv2 build cleanup needs deterministic inventories and races that cannot be created through normal build operations. Add an authenticated, run-isolated cleanup fixture control endpoint with bounded build/deployment seeds, internal modification metadata, deterministic record changes, and accepted deletion followed by an ambiguous response. SAP-shaped responses remain unchanged; deletion initiation retains the build record with DELETED status.

The deletion simulation now rejects snapshot-backed, unknown/non-terminal, deployed, or operationally referenced builds. State counters observe every operation so cleanup tests can distinguish target API mutations from fixture setup and run teardown. Update the control OpenAPI and focused tests accordingly.

Validation: 63 sandbox tests passed across 14 files at 5ded738ccab77f640ce40714d1d3bec77b1285c8; formatting, ESLint, main/test TypeScript, OpenAPI validation, generated-type consistency, and local dry-run bundling passed. The actual cleanup bundles also passed local sandbox integration, including OAuth refresh, paginated discovery, protections, deployment references, report/event validation, and zero target mutations while eligibility is unverified. The canonical pnpm run ci attempt was blocked by the temporary checkout's symlinked dependency setup; its constituent checks were executed directly.

Draft validation gate: sandbox metadata does not establish that SAP exposes a build modification timestamp or enforces the four-hour deletion rule at the API. Production eligibility and destructive bundled scenarios remain blocked. Hosted/live SAP validation, slow-request timeout/cancellation/deadline scenarios, actual token expiry, and a snapshot appearing during final revalidation were not run against the sandbox. Separate cleanup orchestration tests cover injected safety evidence; they do not prove SAP guarantees.

No Cloudflare configuration change or deployment is included. This draft does not authorize merging, package/action publication, tagging, production enablement, or real SAP deletion.

Base: a787e4b07c487a8a4833541f7f7d8bd4afd9fef4. This candidate was rebased without conflicts onto current main; current main’s source tree is identical to the audited ec545e81f0d3f7151572d925905ebdabe84d8f47 baseline (both tree a8ed92a1187f750f4d47605e24af956219b94ffa). The focused cleanup patch is unchanged.

Security note: the push reported five existing default-branch Dependabot alerts (four moderate, one low). These were not resolved by the cleanup-fixture changes; review the repository security dashboard independently.

Companion draft PRs

These are coordinated draft changes. No merge, publication, tagging, deployment, production enablement, or real SAP deletion is authorized by this review. Keep the dependency-publication and SAP eligibility gates explicit.

Hosted validation snapshot — 2026-11-14

PASS: sandbox validate completed successfully on rebased head 5ded738ccab77f640ce40714d1d3bec77b1285c8. Existing default-branch advisory findings, documented unexecuted scenarios, and lack of authoritative SAP eligibility evidence remain separate review gates. No deployment was triggered by this draft.

@anilkreddy
anilkreddy marked this pull request as ready for review November 14, 2026 17:22
@anilkreddy
anilkreddy merged commit 4af998a into main Nov 14, 2026
1 check passed
@anilkreddy
anilkreddy deleted the feat/build-cleanup-scenarios branch November 14, 2026 17:22
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