Skip to content

Improve CLI error formatting#81

Closed
Copilot wants to merge 3 commits intomainfrom
copilot/format-use-agently-errors
Closed

Improve CLI error formatting#81
Copilot wants to merge 3 commits intomainfrom
copilot/format-use-agently-errors

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 17, 2026

  • CLI now formats top-level errors instead of dumping stack traces, providing boxen-styled TUI output on TTY and JSON when stdout is non-TTY.
  • Added reusable handleCliError/resolveOutputFormat utilities and wrapped the CLI entrypoint to ensure consistent formatting.
  • Expanded coverage with TUI/JSON/default output tests and deterministic stderr TTY mocking.

Example:

try {
  await cli.parseAsync();
  await checkAutoUpdate();
} catch (err) {
  handleCliError(err, { output: resolveOutputFormat(cli.optsWithGlobals().output) });
}

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • mainnet.base.org
    • Triggering command: /usr/local/bin/node node dist/cli.js dev --anvil-port 8545 --anvil-host 0.0.0.0 --port 4022 --rpc-url REDACTED (dns block)

If you need me to access, download, or install something from one of these locations, you can either:


💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.

Copilot AI and others added 2 commits March 17, 2026 09:00
Co-authored-by: fuxingloh <4266087+fuxingloh@users.noreply.github.com>
Co-authored-by: fuxingloh <4266087+fuxingloh@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix formatting of use-agently error logs Improve CLI error formatting Mar 17, 2026
Copilot AI requested a review from fuxingloh March 17, 2026 09:12
@fuxingloh fuxingloh marked this pull request as ready for review March 17, 2026 13:35
@fuxingloh fuxingloh closed this Mar 17, 2026
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.

2 participants