Skip to content

fix(automations): fix validation error when selecting Tagged Event#116120

Open
afsuyadi wants to merge 3 commits into
getsentry:masterfrom
afsuyadi:fix_alert_tag_bug
Open

fix(automations): fix validation error when selecting Tagged Event#116120
afsuyadi wants to merge 3 commits into
getsentry:masterfrom
afsuyadi:fix_alert_tag_bug

Conversation

@afsuyadi
Copy link
Copy Markdown

This PR fixes #115268 ; the bug that appears when creating Alert.

Testing scenario:

  1. Click create Alert button
  2. On the If section, chooses Tagged Event
  3. The key will be automatically filled with 'Tag' string
  4. Fill in manually the Match and Value field
  5. When clicking Create Alert, the validation keeps appearing as a blocker.
Screencast.from.23-05-26.23.13.55.webm

Analyze:

  1. In function validateTaggedEventCondition, the key seems to always be falsy.
  2. The hook onChange in KeyField's component seems to not fire anything, which causes the Key to not be saved.

Solution:

  1. Use hook onBlur to manually commit whatever was typed - which will required useRef & onInputChange hook.

After implement:
Screencast from 24-05-26 23:33:07.webm

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

@afsuyadi afsuyadi requested a review from a team as a code owner May 24, 2026 16:44
@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label May 24, 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 b6db59e. Configure here.

@dule1013
Copy link
Copy Markdown

Seems good

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Validation error "Ensure all fields are filled in" when using the "The event's tag ... contains"

2 participants