Skip to content

Conversation

@andreaskienle
Copy link
Contributor

This PR fixes the issue where the names of MCPs were restricted to 25 characters, when they should actually allow up to 36 characters. (The limit of 25 is still fine for projects and workspaces.)

@andreaskienle andreaskienle requested a review from Copilot July 17, 2025 10:22
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the validation limit for managed control plane (MCP) names from 25 to 36 characters and standardizes the error message key to a parameterized maxChars message.

  • Increased the maximum length for MCP name to 36 characters in the Zod schema.
  • Updated validationErrors.max25chars to validationErrors.maxChars with a maxLength parameter in both schemas and locale file.
  • Consolidated regex imports into a single line.

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
src/lib/api/validations/schemas.ts Updated .max length for MCP names, switched to maxChars message, and flattened import line.
public/locales/en.json Replaced "max25chars" translation key with "maxChars" and added interpolation parameter.
Comments suppressed due to low confidence (2)

src/lib/api/validations/schemas.ts:26

  • Add or update unit tests to cover the new 36-character boundary for managed control plane names, ensuring both valid and invalid cases are tested.
    .max(36, t('validationErrors.maxChars', { maxLength: 36 })),

public/locales/en.json:271

  • [nitpick] Ensure that the new maxChars translation key is added and old max25chars removed across all locale files so translations remain consistent.
    "maxChars": "Max length is {{maxLength}} characters.",

@andreaskienle andreaskienle merged commit c5a45d9 into main Jul 17, 2025
5 checks passed
@andreaskienle andreaskienle deleted the fix/name-length branch July 17, 2025 11:27
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