Skip to content
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@
from airflow.providers.common.compat.notifier import BaseNotifier
from airflow.providers.discord.hooks.discord_webhook import DiscordWebhookHook

ICON_URL: str = "https://raw.githubusercontent.com/apache/airflow/main/airflow/www/static/pin_100.png"
ICON_URL: str = (
"https://raw.githubusercontent.com/apache/airflow/main/airflow-core/src/airflow/ui/public/pin_100.png"
)


class DiscordNotifier(BaseNotifier):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@
if TYPE_CHECKING:
from slack_sdk.http_retry import RetryHandler

ICON_URL: str = "https://raw.githubusercontent.com/apache/airflow/2.5.0/airflow/www/static/pin_100.png"
ICON_URL: str = (
"https://raw.githubusercontent.com/apache/airflow/main/airflow-core/src/airflow/ui/public/pin_100.png"
)


class SlackNotifier(BaseNotifier):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ def __init__(
"https://www.youtube.com/watch?v=J---aiyznGQ"
),
icon_url: str = (
"https://raw.githubusercontent.com/apache/airflow/main/airflow/www/static/pin_100.png"
"https://raw.githubusercontent.com/apache/airflow/main/airflow-core/src/airflow/ui/public/pin_100.png"
),
blocks: list | None = None,
attachments: list | None = None,
Expand Down
4 changes: 3 additions & 1 deletion providers/slack/tests/system/slack/example_slack.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,9 @@
DAG_ID = "slack_api_example_dag"
SLACK_API_CONN_ID = os.environ.get("SLACK_API_CONN_ID", "slack_conn_id")
SLACK_CHANNEL = os.environ.get("SLACK_CHANNEL", "#general")
IMAGE_URL = "https://raw.githubusercontent.com/apache/airflow/main/airflow/www/static/pin_100.png"
IMAGE_URL = (
"https://raw.githubusercontent.com/apache/airflow/main/airflow-core/src/airflow/ui/public/pin_100.png"
)

with DAG(
dag_id=DAG_ID,
Expand Down
4 changes: 3 additions & 1 deletion providers/slack/tests/system/slack/example_slack_webhook.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@
ENV_ID = os.environ.get("SYSTEM_TESTS_ENV_ID")
DAG_ID = "slack_webhook_example_dag"
SLACK_WEBHOOK_CONN_ID = os.environ.get("SLACK_WEBHOOK_CONN_ID", "slack_default")
IMAGE_URL = "https://raw.githubusercontent.com/apache/airflow/main/airflow/www/static/pin_100.png"
IMAGE_URL = (
"https://raw.githubusercontent.com/apache/airflow/main/airflow-core/src/airflow/ui/public/pin_100.png"
)

with DAG(
dag_id=DAG_ID,
Expand Down
16 changes: 8 additions & 8 deletions providers/slack/tests/unit/slack/notifications/test_slack.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ def test_slack_notifier(self, mock_slack_hook, dag_maker, extra_kwargs, hook_ext
"channel": "#general",
"username": "Airflow",
"text": "test",
"icon_url": "https://raw.githubusercontent.com/apache/airflow/2.5.0/airflow/www/static"
"/pin_100.png",
"icon_url": "https://raw.githubusercontent.com/apache/airflow/main/airflow-core"
"/src/airflow/ui/public/pin_100.png",
"attachments": "[]",
"blocks": "[]",
"unfurl_links": True,
Expand All @@ -87,8 +87,8 @@ def test_slack_notifier_with_notifier_class(self, mock_slack_hook, dag_maker):
"channel": "#general",
"username": "Airflow",
"text": "test",
"icon_url": "https://raw.githubusercontent.com/apache/airflow/2.5.0/airflow/www/static"
"/pin_100.png",
"icon_url": "https://raw.githubusercontent.com/apache/airflow/main/airflow-core"
"/src/airflow/ui/public/pin_100.png",
"attachments": "[]",
"blocks": "[]",
"unfurl_links": True,
Expand All @@ -114,8 +114,8 @@ def test_slack_notifier_templated(self, mock_slack_hook, dag_maker):
"channel": "#test-test_slack_notifier",
"username": "Airflow",
"text": "test Airflow",
"icon_url": "https://raw.githubusercontent.com/apache/airflow/2.5.0/airflow/www/static"
"/pin_100.png",
"icon_url": "https://raw.githubusercontent.com/apache/airflow/main/airflow-core"
"/src/airflow/ui/public/pin_100.png",
"attachments": '[{"image_url": "test_slack_notifier.png"}]',
"blocks": "[]",
"unfurl_links": True,
Expand All @@ -140,8 +140,8 @@ def test_slack_notifier_unfurl_options(self, mock_slack_hook, dag_maker):
"channel": "#general",
"username": "Airflow",
"text": "test",
"icon_url": "https://raw.githubusercontent.com/apache/airflow/2.5.0/airflow/www/static"
"/pin_100.png",
"icon_url": "https://raw.githubusercontent.com/apache/airflow/main/airflow-core"
"/src/airflow/ui/public/pin_100.png",
"attachments": "[]",
"blocks": "[]",
"unfurl_links": False,
Expand Down
2 changes: 1 addition & 1 deletion providers/slack/tests/unit/slack/operators/test_slack.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ def test_api_call_params_with_default_args(self, mock_hook):
"Here is a cat video instead\n"
"https://www.youtube.com/watch?v=J---aiyznGQ",
"icon_url": "https://raw.githubusercontent.com/apache/"
"airflow/main/airflow/www/static/pin_100.png",
"airflow/main/airflow-core/src/airflow/ui/public/pin_100.png",
"attachments": "[]",
"blocks": "[]",
}
Expand Down