Skip to content

fix(auth): ignore broken pipe in token view#73

Closed
goncalossilva wants to merge 1 commit into
mainfrom
fix/token-view-epipe
Closed

fix(auth): ignore broken pipe in token view#73
goncalossilva wants to merge 1 commit into
mainfrom
fix/token-view-epipe

Conversation

@goncalossilva

@goncalossilva goncalossilva commented Jun 16, 2026

Copy link
Copy Markdown
Member

Summary

  • Make auth token-view stdout writes tolerate downstream pipe closure (EPIPE)
  • Keep non-EPIPE stdout write errors visible
  • Add regression coverage for early pipe close behavior

Test plan

  • npm run type-check
  • npm run check
  • npm test -- src/auth/token-view.test.ts
  • pre-push hook also ran full npm test: 34 files passed, 517 tests passed, 1 skipped

Context

This fixes the stack trace seen when a script consumes only part of td auth token view / tdc auth token view output and closes the pipe early.

The implementation lives in @doist/cli-core, so Todoist CLI and Comms CLI should pick it up by bumping cli-core after this is released.

@goncalossilva goncalossilva deleted the fix/token-view-epipe branch June 16, 2026 17:03
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