AAfghahi commented on code in PR #20903:
URL: https://github.com/apache/superset/pull/20903#discussion_r948478697
##########
superset/utils/core.py:
##########
@@ -963,8 +974,10 @@ def send_email_smtp( # pylint:
disable=invalid-name,too-many-arguments,too-many
image.add_header("Content-ID", "<%s>" % msgid)
image.add_header("Content-Disposition", "inline")
msg.attach(image)
-
- send_mime_email(smtp_mail_from, recipients, msg, config, dryrun=dryrun)
+ msg_mutator = config["EMAIL_HEADER_MUTATOR"]
+ # the base notification returns the message without any editing.
+ new_msg = msg_mutator(msg, **header_data or {})
Review Comment:
Yeah! This is something that I learned, you actually are not allowed to make
a default into an empty dictionary or list.
##########
superset/reports/commands/execute.py:
##########
@@ -73,6 +74,8 @@
from superset.utils.urls import get_url_path
from superset.utils.webdriver import DashboardStandaloneMode
+from ...utils.core import HeaderDataType
Review Comment:
yeah, I keep on doing this and the black reformats it. So annoying.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]