Repository navigation
Fleet: fail-closed TOML and CLI-flag contract admission across zed-pkg #87
Description
Activity
ORESoftware commented
on Sep 10, 2026 ContributorAuthorMore actions2026-09-10 implementation evidence and follow-up scope
The focused audit has now produced concrete regression inputs for this fleet task:
.github#86merged exact-PR-candidate self-scanning for the existing TJSV fleet gate; post-merge policy/privacy/scratch/TJSV workflows are green.zed-e2e#40now binds a coherent immutablezed-cli/flags-2-envpair, parses all tracked TOML in both checkouts, validates the Cargo dependency URL/revision, and runs the exact native parser over all six root CLI contracts.zed-cli#338is the reopened authoritative Rust-native consolidation for current CLI/package TOML. It includes.zpkg.toml↔Cargo version parity, all tracked TOML parsing, native flags2env audit, fail-closedallow_unknown, canonical scalar type names, command-scope parity with Clap, root env/alias uniqueness, canonical dependency ownership, exact toolchain parity, and public Zed-bin/build-output checks.- Focused overlapping PRs were closed only after their useful semantics and regression coverage were visible in #338. The attempted stale-head update was rejected by a non-fast-forward guard; concurrent work was re-read instead of overwritten.
Additional fleet acceptance criteria derived from this audit:
- distinguish Cargo build targets from deliberately public
.zpkg.toml [bin]entries rather than forcing all binaries public; - validate option/env uniqueness within each command scope, while allowing the same spelling or env in distinct subcommands where the typed CLI does;
- compare
.zpkg.tomlpackage identity to the ecosystem-native package manifest and validate every public binary against both the native build target and the Zed build-output allowlist; - verify the exact Rust/toolchain version used by reusable and release workflows against
rust-toolchain.toml; - treat current PR candidate content as authoritative for the scanner repository itself and default-branch content for other fleet members.
Linear could not create a new child because the workspace issue quota is exhausted; DEN-3982 now carries the link and evidence. This GitHub issue remains the canonical new-task record.
ORESoftware commented
on Sep 10, 2026 ContributorAuthorMore actions2026-09-10 execution checkpoint
Two tested Zed/TOML changes are now merged:
.github#86merged asb8fa19f1964fa541bca9a318f30c6a2643423e7aafter exact head7308cac538f8364db355cdc21ebc2bff300f53ecpassed baseline policy, privacy, scratch-ignore, and the live TJSV fleet scan.zed-mcp-server.rs#5merged aseab36156077b7ae0f3a400245ff392968d0ee54eafter exact head4e43910707820988d2dae2623821b4ddd47c8fddpassed CI, MCP peer-contract, and secrets-audit workflows. It corrects the Zed CLI package range to the released^0.3.0line.
Two larger candidates are review-ready but intentionally not merged while exact-head GitHub Actions remain queued:
zed-cli#338, current clean product tree at0b0230cf8b8f0aa6b89b7df0e1894541969f31a0, consolidates CLI/TOML/package/toolchain checks. A transient branch-specific write-enabled repair workflow was detected and removed;c5f0ce5...and0b0230c...have identical trees. Fresh exact-head workflows are queued and cancelled predecessors are not counted as passes.zed-e2e#40, current head8c5dc64755396903b3fd7dacc33da29c318f771a, binds canonicalflags-2-env, a coherent immutable CLI/parser tuple, tracked-TOML parsing,.zpkg.tomlpackage-line parity, and native audit of all six root CLI flag contracts. Its four required workflows are queued/pending.
The organization currently has a substantial Actions backlog, also affecting post-merge jobs on already-landed commits. No queued, pending, cancelled, or zero-step run is being represented as successful.
This issue remains the canonical fleet follow-up for expanding those repo-local checks across all active
zed-pkgTOML surfaces. No credential value was persisted, rotated, or revoked, and no rebase/reset/stash/force update or blanket conflict-side selection was used.ORESoftware commented
on Sep 10, 2026 ContributorAuthorMore actionsGoogle Chat exact-window reconciliation linkage:
ORESoftware/my-ai#141, tail recordS10-05(2026-09-10).This issue is the canonical owner for that prompt's Zed-specific requirement; do not create a duplicate issue merely for Chat accounting. Please treat the following as explicit acceptance refinements:
- consume the canonical flags2env env-manifest/reconciliation behavior tracked by
ORESoftware/flags-2-env#49rather than implementing a second TOML/env parser; - include
.cli-flags.tomlplus every tracked root/runtime*.tomlfamily in the same deterministic inventory, with explicit skipped-file reasons; - cross-check CLI/argv-capable env ownership against env-only secret bindings and fail closed on duplicates/conflicts;
- retain machine-readable source SHA/tool SHA/file-digest evidence so Chat reconciliation can point to immutable implementation proof;
- keep
zed-cli#345,zed-cli#350,.github#88, andzed-web-server.rs#55as child/canonical slices where their scopes match rather than duplicating them.
Historical Chat bodies/credentials are intentionally not reproduced here. Final completion should link the exact implementation PR heads back to
ORESoftware/my-ai#141.- consume the canonical flags2env env-manifest/reconciliation behavior tracked by
ORESoftware commented
on Sep 14, 2026 ContributorAuthorMore actionsBroader package/SDK env-contract refinement after re-verifying the canonical implementation:
flags-2-env/flags-2-env#16is merged at333c2ace93c362d274171ab0e0edf613d96a8e59and already owns deterministic root[[env]]discovery, value-freemanifest.env,.cli-flags.tomlindexing, argv-vs-env-only ownership, secret/default refusal, and key-only encrypted/plain inventory reconciliation. Zed fleet work should consume that exact authority rather than recreate it.Add one Zed-specific layer that #16 intentionally does not own: transitive package env requirements. A library/SDK package such as
ores-locks-and-leasesorores-redis-lru-cacheshould be able to publish value-free environment metadata through.zpkg.toml/package metadata, andzed validateshould compute the deterministic transitive union for an application. Requirements:- preserve source package + version/revision provenance for every env requirement;
- merge compatible repeated keys, but fail on type/required/secret/exposure disagreement;
- distinguish runtime-required, build-only, dev/test-only, server-only, and client-safe scope where the package metadata declares it;
- never synthesize env-only secrets into argv flags;
- emit the transitive requirement set through the canonical flags2env JSON/manifest representation rather than inventing a second format;
- compare the resolved application set with its
.cli-flags.toml, domain TOMLs, andores-clisource-read evidence; - include cycle/diamond dependency fixtures so the result is deterministic regardless of traversal order.
This keeps package declaration ownership in Zed, environment normalization in flags2env, and fleet/source reconciliation in ores-cli.
Problem
The current Zed release harness now validates the selected
zed-cliandflags-2-envpair, but the organization does not yet have one fleet-level admission inventory for tracked TOML contracts.The 2026-09-10 audit found a concrete coupled-pin defect: the tagged E2E workflow initially paired a current canonical
flags-2-envrevision with an older Zed CLI whoseCargo.tomlstill referenced the legacy repository and a different commit. PRzed-pkg/zed-e2e#40fixes that tuple and adds repository-level checks, but equivalent drift can recur elsewhere.Required scope
Create a fail-closed scanner and reusable admission workflow for every active
zed-pkgrepository. It must inventory and validate, as applicable:.cli-flags.tomland every root.*-cli-flags.tomlfile;.zpkg.tomland related Zed package manifests/locks;Cargo.toml, workspace manifests, andrust-toolchain.toml;pyproject.toml, Dart/Flutter TOML bridges, and other tracked*.tomlfiles;flags-2-env/flags-2-envandzed-pkg/*dependencies.Admission behavior
flags2env auditimplementation against every CLI flag contract..zpkg.tomlwith an immutable reviewed Zed CLI and run deterministiczed validate/zed packsmoke checks where a package manifest exists..github#86.Safety and ownership
my-ai/AGENTS.mdsemantic-conflict rules: no rebase/reset/stash/force-push or blanket side selection.Acceptance criteria
.zpkg.lock, unreadable required repositories, and exception expiry.zed-pkgrepositories and retains evidence artifacts.zed-pkg/zed-e2e#40and.github#86remain regression inputs rather than duplicated implementations.Related: DEN-3982,
zed-pkg/zed-e2e#40,zed-pkg/.github#86.