Skip to content

Conversation

@fed1337
Copy link

@fed1337 fed1337 commented Dec 10, 2025

This is very similar to the slack notification plugin. Tests are passed in a slightly different environment with python 3.10

data = {
"parse_mode": "MarkdownV2",
"chat_id": self.get_option("chat", options),
"text": "*Lemur {} Notification*\n\n{}".format(notification_type.capitalize(), *attachments),
Copy link
Contributor

Choose a reason for hiding this comment

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

Looking at the structure, it should probably be:

For expiration (list of strings)

"text": "Lemur {} Notification\n\n{}".format(
notification_type.capitalize(),
''.join(attachments) # Join the list into one string
)

Or for rotation (single string)

"text": "Lemur {} Notification\n\n{}".format(
notification_type.capitalize(),
attachments # Already a string, no unpacking
)
as currently unpacking will just yield the first element

@@ -0,0 +1,109 @@
"""
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we add a changelog / amdinistration.rst entry for this as well?

Copy link
Contributor

@jmcrawford45 jmcrawford45 left a comment

Choose a reason for hiding this comment

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

Pending open comments.

@fed1337 fed1337 marked this pull request as draft December 20, 2025 16:20
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.

2 participants