Skip to main content
← Back to list
01Issue
BugShippedSwamp CLIPublic
Assigneeszack

Relationships

#3302 swamp model edit silently renames the target when the piped body's name differs

Opened by stack72 · 10/12/2026· Shipped 10/12/2026

Summary

swamp model edit <name> applies the whole piped body, including the name field. When the body's name differs from the addressed model, the model gets silently renamed. No warning, no diff, no confirmation.

Repro

  1. Create a model named foo.
  2. Author a definition file whose own top-level name: is bar.
  3. Run swamp model edit foo < bar.yaml.
  4. swamp model get foo now resolves to nothing. swamp model get bar resolves to the model that used to be foo, with all its prior state intact under the new name.

Impact

Hit this for real on 2026-10-12. A shared, 105-record @swamp/software-factory instance named platform-team got renamed to platform-team-template by a routine model edit platform-team < factories/platform-team-template.yaml call, whose only intent was refreshing globalArguments. The piped file's own name: field happened to differ.

Every bare-name call against platform-team then failed to resolve. A downstream auto-create-on-missing fallback in our own extension code created a fresh, empty model under the freed name. Several webhook nudges then wrote real work onto that decoy: classify, plan, and two rounds of plan-review. Nobody caught the mismatch until later.

Suggested fix

model edit should refuse, or require an explicit --allow-rename flag, when the piped body's name differs from the model_id_or_name argument that named the target. A rename is a deliberate, identity-affecting operation. It should never happen as a side effect of a content patch.


Automoved by swampadmin from https://github.com/swamp-club/swamp/issues/3020

02Bog Flow
✓OPEN✓TRIAGED✓IN PROGRESS✓SHIPPED+ 1 MOREASSIGNED+ 6 MOREREVIEW+ 10 MOREPR_MERGED+ 2 MORESESSION_SUMMARIZED

Shipped

10/12/2026, 8:04:02 PM

Click a lifecycle step above to view its details.

03Sludge Pulse
zack assigned zack10/12/2026, 7:24:10 PM
Editable. Press Enter to edit.

system commented 10/12/2026, 4:54:08 PM

Classified automatically when this issue was filed.

  • Type: Bug

If you feel this classification is incorrect, add a ripple to tell us so.

Sign in to post a ripple.