Skip to content

fix: handle undefined monitor name in PagerDuty notification summary#6977

Merged
CommanderStorm merged 3 commits intolouislam:masterfrom
mixelburg:fix/pagerduty-undefined-title
Feb 18, 2026
Merged

fix: handle undefined monitor name in PagerDuty notification summary#6977
CommanderStorm merged 3 commits intolouislam:masterfrom
mixelburg:fix/pagerduty-undefined-title

Conversation

@mixelburg
Copy link
Copy Markdown
Contributor

Fixes #2315

When the monitor name is undefined (e.g. when using the test button), the PagerDuty alert summary shows [undefined] in the title. This change conditionally includes the monitor name bracket only when it's available.

Also handles the dedup_key field to avoid Uptime Kuma/undefined when monitor ID is not set.

Copilot AI review requested due to automatic review settings February 18, 2026 18:24
@github-actions
Copy link
Copy Markdown
Contributor

Hello and thanks for lending a paw to Uptime Kuma! 🐻👋
As this is your first contribution, please be sure to check out our Pull Request guidelines.
In particular: - Mark your PR as Draft while you’re still making changes - Mark it as Ready for review once it’s fully ready
If you have any design or process questions, feel free to ask them right here in this pull request - unclear documentation is a bug too.

Copy link
Copy Markdown
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 fixes an issue where PagerDuty notifications show [undefined] in the alert title when the monitor name is not available, such as when using the test button. The fix adds conditional checks to only include the monitor name and ID when they are defined.

Changes:

  • Conditionally includes monitor name in PagerDuty alert summary to avoid displaying [undefined]
  • Handles undefined monitor ID in dedup_key field by using "Uptime Kuma/test" as fallback

Copy link
Copy Markdown
Collaborator

@CommanderStorm CommanderStorm left a comment

Choose a reason for hiding this comment

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

LGTM

@CommanderStorm CommanderStorm enabled auto-merge (squash) February 18, 2026 19:51
@CommanderStorm CommanderStorm merged commit ab3045f into louislam:master Feb 18, 2026
24 checks passed
@github-actions
Copy link
Copy Markdown
Contributor

@mixelburg congrats on your first contribution to Uptime Kuma! 🐻
We hope you enjoy contributing to our project and look forward to seeing more of your work in the future! If you want to see your contribution in action, please see our nightly builds here.

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.

PagerDuty Alerts have [undefined] title section

3 participants