Skip to content

chore(versioning): remove dead 423 freeze + v1-migration error handlers - #34

Merged
prat11m merged 1 commit into
mainfrom
chore/mcp-remove-dead-versioning-handlers
Aug 6, 2026
Merged

chore(versioning): remove dead 423 freeze + v1-migration error handlers#34
prat11m merged 1 commit into
mainfrom
chore/mcp-remove-dead-versioning-handlers

Conversation

@prat11m

@prat11m prat11m commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

PRO-1946

Part of the agent-versioning v1 cleanup program (parent PRO-1621). PR6 — mcp-server tidy.

What

Removes two now-unreachable branches from `formatApiError` in `src/api.ts`, plus the unused `VERSIONING_V2_MIGRATION_ERROR` constant:

Handler Why dead
`if (result.status === 423)` — config-freeze message The `AGENT_CONFIG_FROZEN` freeze flag was removed in atoms cleanup PR1; the backend no longer returns 423.
`if (result.data?.error_type === "versioning_v2_migration_required")` The deprecated v1 versioning write endpoints were deleted in atoms cleanup PR3; the backend no longer emits this `error_type`.

`formatApiError` now falls through to its generic `API error : ` for any real error.

What to test

  • Build + typecheck pass (`npm run build`, `tsc --noEmit`) — verified locally, both green.
  • No behavioural change for live errors: any real API failure still surfaces via the generic message. There is no path that can produce a 423 or the v1-migration error_type from the current backend.

What to validate

  • grep confirms no remaining references to `423` / `VERSIONING_V2_MIGRATION_ERROR` / `versioning_v2_migration_required` in `src`.

Deployment

Plain merge — no env vars, no migration. Ships with the next mcp-server release.

Dependencies

Independent of atoms PR5. Relies on PR1 + PR3 (both merged & deployed).

🤖 Generated with Claude Code

Both branches in formatApiError are now unreachable after the v1 cleanup:
- HTTP 423 config-freeze: the AGENT_CONFIG_FROZEN flag was removed (atoms
  cleanup PR1), so the backend never returns 423.
- versioning_v2_migration_required: the deprecated v1 versioning write
  endpoints were deleted (atoms cleanup PR3), so the backend never emits
  this error_type.

Drops both handlers and the now-unused VERSIONING_V2_MIGRATION_ERROR const;
formatApiError falls through to its generic message.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@prat11m
prat11m merged commit cbd0666 into main Aug 6, 2026
1 check 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.

2 participants