From 085f4824d90066150cfbfd2fb941980b17823e27 Mon Sep 17 00:00:00 2001 From: Ym <173550318+MaxonT@users.noreply.github.com> Date: Sun, 29 Nov 2026 16:09:26 -0600 Subject: [PATCH] refactor(errors): rename the JSX-free modules in src/errors from .tsx to .ts Signed-off-by: Ym <173550318+MaxonT@users.noreply.github.com> --- AGENTS.md | 2 +- src/errors/{errors.test.tsx => errors.test.ts} | 0 src/errors/{errors.tsx => errors.ts} | 0 src/errors/{index.tsx => index.ts} | 0 src/errors/{types.tsx => types.ts} | 0 5 files changed, 1 insertion(+), 1 deletion(-) rename src/errors/{errors.test.tsx => errors.test.ts} (100%) rename src/errors/{errors.tsx => errors.ts} (100%) rename src/errors/{index.tsx => index.ts} (100%) rename src/errors/{types.tsx => types.ts} (100%) diff --git a/AGENTS.md b/AGENTS.md index c2e2fa873a..b01ba2f9cf 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -136,7 +136,7 @@ Before finishing a change run `bun test`, `bun run typecheck`, `bun run lint:che - Errors: throw `AgentCoreCLIError` subclasses (`src/errors/`), which carry `source` (user/service/internal), `exitCode`, and `meta` for logging and telemetry. `AgentCoreCLIError.fromError` maps Commander errors to exit code 2 and SDK 4xx to user errors. - `SilentCLIError` (`src/errors/errors.tsx`) is the one to throw when the command has already + `SilentCLIError` (`src/errors/errors.ts`) is the one to throw when the command has already written its own output and only needs to carry an exit code — a remote command's exit status, for instance — so the root handler does not print a second message over it. Error text is asserted behaviour: when you refactor an error path, keep everything the old diff --git a/src/errors/errors.test.tsx b/src/errors/errors.test.ts similarity index 100% rename from src/errors/errors.test.tsx rename to src/errors/errors.test.ts diff --git a/src/errors/errors.tsx b/src/errors/errors.ts similarity index 100% rename from src/errors/errors.tsx rename to src/errors/errors.ts diff --git a/src/errors/index.tsx b/src/errors/index.ts similarity index 100% rename from src/errors/index.tsx rename to src/errors/index.ts diff --git a/src/errors/types.tsx b/src/errors/types.ts similarity index 100% rename from src/errors/types.tsx rename to src/errors/types.ts