Skip to content

Local provision CLI contracts and typed preflight #289

Description

@aram356

Description

Section 1 of #288 covers foundation types, CLI flag and shared typed preflight. PR #287 contains the proposed implementation but remains unmerged. Dependencies: none beyond the umbrella contract.

Steps to reproduce

Inspection steps (no tests executed):

  1. Inspect main Adapter::provision contract.
  2. Compare this section’s tasks in local-provision plan with the open branch.
  3. Confirm the local-provision contract is still absent from main rather than treating checked-off branch tasks as delivery.

Expected behavior

The section’s contract is present on main and composes with the other local-provision sections without cloud operations during local mode.

Impact

The CLI and adapter trait cannot express local/cloud provision modes or return deployed state.

Proposed fix

Review and merge this section through PR #287, preserving the tasks below and subsequent umbrella amendments. Reconcile with current main rather than reintroducing removed Fastly runtime-env descriptors.

Dependencies: none beyond the umbrella contract.

Done when

  • Task 1: Add ProvisionMode enum + local flag on ProvisionArgs (extend manual Default impl)
  • Task 2: Add neutral AdapterDeployedState + ProvisionOutcome types in edgezero-adapter; crate-root re-exports
  • Task 3: Thread ProvisionMode, deployed: Option<&AdapterDeployedState>, and ProvisionOutcome through Adapter::provision
  • Task 4: Add Adapter::provision_typed trait method with default no-op
  • Task 5: Extract run_typed_preflight(&typed, &ctx); pub(crate) accessors on ValidationContext; rewrite validate/push/diff sites

Required repository verification: cargo fmt --all -- --check; cargo clippy --workspace --all-targets --all-features -- -D warnings; cargo test --workspace --all-targets; cargo check --workspace --all-targets --features "fastly cloudflare spin"; cargo check -p edgezero-adapter-spin --target wasm32-wasip2 --features spin. These are acceptance requirements, not tests executed during this audit.

Related

#288; local-provision plan; PR #287 is the fully covering open PR. This section is a foundation for later sections.

July amendment: all five generated manifests, including axum.toml, are gitignored.

Activity

  1. self-assigned this
    on Jun 30, 2026
  2. changed the title [-]Section 1 — CLI surface, neutral types, trait method (Tasks 1–5)[/-] [+]Local provision CLI contracts and typed preflight[/+] on Nov 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions