Skip to content

fix(spans) Trim environment names to prevent overflows#115141

Merged
markstory merged 2 commits into
masterfrom
fix-5hbe
May 8, 2026
Merged

fix(spans) Trim environment names to prevent overflows#115141
markstory merged 2 commits into
masterfrom
fix-5hbe

Conversation

@markstory
Copy link
Copy Markdown
Member

The environment model has a max name length of 64 characters. Currently if a span contains a longer name, saving segment relations will fail.

Trimming the environment name to prevent overflows preserves as much data as we can. This change will also impact environments created by errors and transactions.

Fixes SENTRY-5HBE

The environment model has a max name length of 64 characters. Currently
if a span contains a longer name, saving segment relations will fail.

Trimming the environment name to prevent overflows preserves as much
data as we can. This change will also impact environments created by
errors and transactions.

Fixes SENTRY-5HBE
@markstory markstory requested review from a team as code owners May 7, 2026 21:15
@github-actions github-actions Bot added the Scope: Backend Automatically applied to PRs that change backend components label May 7, 2026
Copy link
Copy Markdown
Contributor

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 3b0fec3. Configure here.

Comment thread src/sentry/models/environment.py Outdated
Comment thread src/sentry/models/environment.py Outdated
@markstory markstory merged commit 1bbfb52 into master May 8, 2026
83 checks passed
@markstory markstory deleted the fix-5hbe branch May 8, 2026 14:36
nikkikapadia pushed a commit that referenced this pull request May 12, 2026
The environment model has a max name length of 64 characters. Currently
if a span contains a longer name, saving segment relations will fail.

Trimming the environment name to prevent overflows preserves as much
data as we can. This change will also impact environments created by
errors and transactions.

Fixes SENTRY-5HBE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Backend Automatically applied to PRs that change backend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants