This is an automated email from the ASF dual-hosted git repository.

potiuk pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/main by this push:
     new 4374a49872 Cleanup PagerdutyNotifier __init__ (#39145)
4374a49872 is described below

commit 4374a4987218a05913253b368f45b5fe0ef21493
Author: David Traina <[email protected]>
AuthorDate: Sat Apr 20 02:22:18 2024 -0500

    Cleanup PagerdutyNotifier __init__ (#39145)
    
    fix duplicate initialization of self.class_type and self.custom_details + 
allow pagerduty_events_conn_id to be None
---
 airflow/providers/pagerduty/notifications/pagerduty.py | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/airflow/providers/pagerduty/notifications/pagerduty.py 
b/airflow/providers/pagerduty/notifications/pagerduty.py
index 5f04e2cb6c..68dae03e7c 100644
--- a/airflow/providers/pagerduty/notifications/pagerduty.py
+++ b/airflow/providers/pagerduty/notifications/pagerduty.py
@@ -84,7 +84,7 @@ class PagerdutyNotifier(BaseNotifier):
         class_type: str | None = None,
         images: list[Any] | None = None,
         links: list[Any] | None = None,
-        pagerduty_events_conn_id: str = "pagerduty_events_default",
+        pagerduty_events_conn_id: str | None = "pagerduty_events_default",
         integration_key: str | None = None,
     ):
         super().__init__()
@@ -96,11 +96,9 @@ class PagerdutyNotifier(BaseNotifier):
         self.action = action
         self.dedup_key = dedup_key
         self.custom_details = custom_details
-        self.custom_details = custom_details
         self.group = group
         self.component = component
         self.class_type = class_type
-        self.class_type = class_type
         self.images = images
         self.links = links
 

Reply via email to