Skip to main content
← Back to list
01Issue
BugClosedSwamp CLIPublic
AssigneesNone

Relationships

#2505 Failed pulled-extension sources are attributed to @local/model, producing a nonsensical 'extension pull @local/model --force' hint

Opened by skunk-ape · 9/24/2026

Summary

When a source file inside a pulled extension fails to bundle (for example after a local edit introduces a syntax error), the catalog row records the failure under the pulled path but with extension_name '@local/model' and version 0.0.0 instead of the owning pulled extension. The broken-bundles warning then names the wrong extension and suggests a command that cannot work.

Reproduce

  1. swamp repo init; swamp extension trust add magistr
  2. swamp extension pull @magistr/telegram-send@2026.09.24.1
  3. Append a syntax error (for example the line: const broken = ;) to .swamp/pulled-extensions/@magistr/telegram-send/models/extensions/models/telegram_send.ts
  4. rm -rf .swamp/bundles
  5. swamp model create @magistr/telegram/send inst1

Actual

WRN swamp·model·loader: Extension "@local/model" has broken bundles and is not available. Run 'swamp doctor extensions --repair' or 'swamp extension pull "@local/model" --force' to fix.

The catalog (bundle_types) row for the pulled source has state BundleBuildFailed, extension_name @local/model, extension_version 0.0.0.

Expected

The failure is attributed to @magistr/telegram-send at its installed version, and the hint names that extension.

Notes

Likely the cold-start failure path in ExtensionLoader.buildIndex: when the failing source is not found in repository.loadAll() it falls back to makeLocalExtension({ basename: kind }). Found while triaging swamp-club#2476, which avoids relying on extension_name for this reason.

02Bog Flow
✓OPEN○TRIAGED○IN PROGRESS◉CLOSED

Closed

9/24/2026, 9:40:40 PM

No activity in this phase yet.

03Sludge Pulse
Editable. Press Enter to edit.

skunk-ape commented 9/24/2026, 9:40:40 PM

Closing: this was a false report from my own reproduction setup, not a swamp bug. I built the scratch repo with cp -a from another repo, so its _extension_catalog.db still held rows whose source_path pointed at the original repo. The failing source's path then matched no known pulled extension, and the loader fell back to the @local/model placeholder. In a freshly initialized repo, the same syntax-error edit is recorded as BundleBuildFailed under @magistr/telegram-send 2026.09.24.1, and the warning names that extension correctly. Found while working on swamp-club#2476.

Sign in to post a ripple.