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

Relationships

↔ sibling #2925

#2923 swamp model create crashes with an [FTL] ZodError stack trace on an invalid (uppercase) model name

Opened by hammz · 10/1/2026· Shipped 10/1/2026

Description

Passing a model name that fails definition-name validation to swamp model create crashes the CLI with an [FTL] fatal log, a raw ZodError JSON dump and a full stack trace, instead of a clean validation error.

Found while reproducing swamp-club#2918 on 20261001.202145.0-sha.a3515474.

Steps to reproduce

  1. swamp repo init --tool none in a scratch dir
  2. swamp model create command/shell shUpper

Actual

[FTL] error: ZodError: [ { code: custom, path: [name], message: Definition name must be lowercase alphanumeric with hyphens or underscores (e.g. 'my-server'). Must start with a letter or number. } ] followed by a stack trace through Definition.create (src/domain/definitions/definition.ts) and createAndSave (src/libswamp/models/create.ts).

Expected

A user-facing validation error naming the rule (and a json-mode error object under --json), with no stack trace. The name should be validated up front, before Definition.create throws.

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

Shipped

10/1/2026, 10:19:03 PM

Click a lifecycle step above to view its details.

03Sludge Pulse
hammz assigned hammz10/1/2026, 8:45:52 PM
hammz linked sibling of #292510/1/2026, 8:49:08 PM

Sign in to post a ripple.