Skip to main content
← Back to list
01Issue
BugShippedSwamp CLITeam
Assigneesstack72

Relationships

#1194 swamp auth login prompts are confusing — "username" only accepts email, and --username is re-prompted

Opened by kneel · 7/16/2026· Shipped 7/17/2026

A few small papercuts in the interactive login flow that together make the prompt feel unreliable:

"Username or email" only accepts an email. signIn() posts to /api/auth/sign-in/email with body: { email: username } (src/infrastructure/http/swamp_club_client.ts:118), so whatever is typed lands in the email field of an email-only endpoint. A bare username won't work, despite the Username or email: prompt and the --username flag.

--username gets ignored and re-prompted. readCredentials() always asks for both fields (login.ts:179-183), so swamp auth login --no-browser --username alice still prints Username or email:, reads the answer, and discards it (username ?? creds.username, line 256) before asking for the password. Looks broken even though it technically works.

Piping a password doesn't work. With non-TTY stdin, readPassword() returns "" (login.ts:133-135), so printf 'pass\n' | swamp auth login ... ends in "Username and password are required." No stdin/env option for automation.

Repro:

swamp auth login --no-browser --username alice   # still asks for username, then discards it
printf 'pass\n' | swamp auth login --no-browser --username alice   # empty password → error

Suggestions:

  • Relabel the prompt/flag to Email: / --email, or make usernames actually work.
  • When --username is given, prompt only for the missing password.
  • Add a non-interactive password option (stdin or SWAMP_PASSWORD).

Environment: swamp 20260716.194319.0-sha.df9fc306.

02Bog Flow
OPENTRIAGEDIN PROGRESSSHIPPED+ 1 MOREASSIGNED+ 7 MOREREVIEW+ 4 MOREPR_MERGED+ 1 MORECONTRIBUTOR_NOTIFIED

Shipped

7/17/2026, 1:26:52 AM

Click a lifecycle step above to view its details.

03Sludge Pulse
stack72 assigned stack727/16/2026, 11:25:13 PM
Editable. Press Enter to edit.

stack72 commented 7/17/2026, 1:27:12 AM

Thanks @kneel for reporting this! The fix has been merged and a release is on its way. We appreciate your contribution to swamp.

Sign in to post a ripple.