Skip to content

fix(cli): reject malformed IDs and preserve TSID batch sequencing - #112

Merged
jkomyno merged 1 commit into
mainfrom
fix/cli-inspection-errors
Nov 15, 2026
Merged

jkomyno merged 1 commit into
mainfrom
fix/cli-inspection-errors

Conversation

@jkomyno

@jkomyno jkomyno commented Nov 15, 2026 •

Copy link
Copy Markdown
Owner

uniku inspect not-an-id --type ulid --json now exits with code 1, leaves stdout empty, and writes a structured INVALID_ID error to stderr. Explicitly selecting UUID, CUID, or another format also validates the input instead of accepting malformed values; decoder failures use the CLI's typed error path.

Configured TSID batches use the library sequence from #111, preserving uniqueness across successive calls. Fixed-timestamp batches retain one node identity while stepping their counter and timestamp.

Final PR in the stack: #110 → #111 → this PR.

Validation: 280 CLI tests pass, including malformed inspection for all nine selectable types and repeated TSID batches. Built-bin checks confirm empty stdout, structured JSON stderr, and exit code 1 for malformed ULID, UUID, and CUID input. Package suites pass on Node 22.12.0 and Node 24.22.3; repository type checks and lint pass.

@github-actions

github-actions Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

Preview removed because the pull request was closed.

@pkg-pr-new

pkg-pr-new Bot commented Nov 15, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

pnpm add https://pkg.pr.new/@uniku/cli@112
pnpm add https://pkg.pr.new/uniku@112

commit: b223237

@jkomyno
jkomyno force-pushed the fix/cli-inspection-errors branch 2 times, most recently from 777ae34 to 653e3f2 Compare November 15, 2026 20:54
Base automatically changed from fix/tsid-configured-generation to main November 15, 2026 20:55
@jkomyno
jkomyno force-pushed the fix/cli-inspection-errors branch from 653e3f2 to b223237 Compare November 15, 2026 20:55
@jkomyno
jkomyno merged commit ca8b953 into main Nov 15, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant