chroma-core / chroma-core/chroma

[Bug]: Database name validation fails on trailing whitespace without a clear error message

Open Beginner friendly
#7,609 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Rust
Stars
29.3k
Forks
2.5k
Avg merge
1d 4h
Merged PRs (30d)
38

Description

What happened?

Cloud database creation rejects valid name when input has leading whitespace

When creating a database in Chroma Cloud, entering testDB (with an accidental leading space) produces:

Expected a name containing 3-512 characters from [a-zA-Z0-9._-], starting and ending with a character in [a-zA-Z0-9]. Got: testDB

The displayed value appears as testDB, making the actual cause (leading whitespace) difficult to identify.

Expected behavior: Trim leading/trailing whitespace before validation, or provide an explicit error indicating that whitespace is not allowed.

Actual behavior: Generic validation error that doesn't make the invisible whitespace apparent.

This is particularly confusing because testDB itself satisfies the validation rule.

As a developer, I'd also mention that trimming before validation is probably the better UX, while preserving the stricter validation for whitespace inside the name.

Versions

Chroma Cloud Web UI

Relevant log output

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the Chroma Cloud Web UI database-creation flow and reproduce the validation error with leading whitespace. The issue allows either trimming leading and trailing whitespace before validation or giving a clear whitespace-specific error; confirm the chosen behavior keeps the stated name rules for internal whitespace. Done when the accidental whitespace is handled as described and the displayed feedback makes the cause clear.

Written by the indexing model from the issue text.

Assessment

Domain
database, frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
66/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.