Relationships
#524 swamp workflow validate emits misleading "Extension failed to load" warning when type resolves locally
Opened by prawn · 6/1/2026
Summary
swamp workflow validate repeatedly emits
extension·auto-resolve Extension "@swamp/digitalocean" is already installed at
/…/.swamp/pulled-extensions/@swamp/digitalocean
but failed to load.
extension·auto-resolve Local edits may be preventing it from registering —
inspect the source and fix errors.
extension·auto-resolve To reset to the registry version and discard local
changes, run: swamp extension pull "@swamp/digitalocean"
--forcefor every workflow step whose model type comes from an installed extension. The
warning is misleading — the extension does load successfully via the
local-bundle path that swamp model type describe, swamp model get, and
actual method execution all use. Only the validator's auto-resolve fallback
errors. The user is told to run --force even when nothing is actually broken.
Reproduction
Giga-swamp-like repo with @swamp/digitalocean and @swamp/kubernetes pulled:
swamp extension install— clean, no errors.swamp extension pull @swamp/digitalocean --force.swamp doctor extensions→5 passed, 0 failed — OVERALL: PASS.swamp model type describe @swamp/digitalocean/kubernetes-cluster --json→ returns full schema and all methods (including locally-added ones).swamp model get <any-cluster-model> --json→ returns the model fine.swamp workflow validate <workflow-referencing-that-type>→ emits the auto-resolve error twice per affected step. Validation itself still reportsPASSED.
Expected: no ERR line on the validate path when the type is loadable via
the normal local-bundle path.
Actual: the error fires every workflow validate (and likely every workflow run too — haven't executed yet). Non-blocking, but produces a wall of noise that hides real failures.
Environment
- swamp
20260601.142529.0-sha.6885aa31 - Darwin 25.3.0 (macOS, arm64)
@swamp/digitalocean2026.05.29.1@swamp/kubernetes2026.05.27.2- Local
extensions/models/*.tsoverlays on@swamp/digitalocean/kubernetes-cluster(addswrite_kubeconfig). The warning fires identically when those overlays are temporarily moved aside, so the issue is independent of local extensions.
Tried (none cleared the warning)
swamp extension installswamp extension pull @swamp/digitalocean --forcerm .swamp/_extension_catalog.db*and re-resolveswamp doctor extensions- Removing local overlay extensions, re-running validate, restoring them
Hypothesis
The workflow validator's auto-resolve code path tries to fetch the type via the
registry rather than reusing the already-loaded local bundle. The registry
lookup surfaces a generic "but failed to load" error and tells the user to run
--force, instead of falling through to the working local-load path (or
recognizing that the type is already resolved and skipping the lookup entirely).
A possible quick win: when extension·auto-resolve finds an extension already
installed locally and swamp model type describe <type> succeeds, suppress
the warning and the "run --force" suggestion. Long-term, the auto-resolver
should share the same load path as model type describe.
Impact
Cosmetic but high-noise. A multi-step deploy workflow (e.g. our 8-step deploy-swamp-club-k8s) emits 16+ ERR lines per validate, drowning real diagnostics. Also undermines confidence — users (and AI agents) reasonably read "failed to load" as a real failure and chase fixes (pull --force, catalog delete, doctor) that don't help.
Closed
No activity in this phase yet.
stack72 commented 6/2/2026, 9:41:40 AM
Thanks for the detailed report, @prawn! This was fixed in PR #1485 (swamp-club#506) — workflow validate now calls modelRegistry.ensureLoaded() before resolving types, so pulled extension types resolve correctly without triggering the auto-resolver's misleading "failed to load" warning.
Your binary (sha.6885aa31) was built ~48 minutes before that fix merged. Running swamp update should clear this up. Let us know if you still see it after updating!
prawn commented 6/2/2026, 10:27:07 AM
Ah ha! thanks
Sign in to post a ripple.