From 78161982dfee77398c60ab8ee19f6111a0a07124 Mon Sep 17 00:00:00 2001 From: Daniel Abraham Date: Mon, 30 Dec 2024 14:57:54 -0800 Subject: [PATCH] add a couple of tiny docstrings --- purrr/slack_channel.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/purrr/slack_channel.py b/purrr/slack_channel.py index 6b583902..609e2b83 100644 --- a/purrr/slack_channel.py +++ b/purrr/slack_channel.py @@ -84,6 +84,7 @@ def _set_bookmarks(pr, channel_id: str) -> None: def _set_description(pr, channel_id: str) -> None: + """Set the description of a Slack channel to a GitHub PR title.""" title = f"`{pr.title}`" if len(title) > _MAX_METADATA_LENGTH: title = title[: _MAX_METADATA_LENGTH - 4] + "`..." @@ -95,6 +96,7 @@ def _set_description(pr, channel_id: str) -> None: def _set_topic(pr, channel_id: str) -> None: + """Set the topic of a Slack channel to a GitHub PR URL.""" topic = pr.html_url if len(topic) > _MAX_METADATA_LENGTH: topic = topic[: _MAX_METADATA_LENGTH - 4] + " ..."