Skip to content

Slack issue alert links use the wrong environment query parameter #123541

Description

@ricar6os

Environment

SaaS (https://sentry.io/)

Steps to Reproduce

  1. Use an Issue Alert configured for the production environment.
  2. Configure Slack as an alert action.
  3. Trigger the alert with an event whose environment is production.
  4. Open the issue link included in the Slack notification.
  5. Check the environment query parameter in the generated URL.

The issue and alert are correctly associated with production.

Expected Result

The issue link generated in the Slack notification should preserve the environment that triggered the alert.

For a production alert, the generated URL should contain:

environment=production

Actual Result

The Slack notification contains an issue link with:

environment=development

even though the alert was triggered by a production event and the alert rule is configured for the production environment.

For example, the generated link uses an environment filter different from the environment that triggered the alert.

As a result, clicking the Slack notification opens Sentry with the wrong environment filter applied.

Product Area

Alerts

Link

No response

DSN

No response

Version

No response

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions