3
3
import smtplib
4
4
from email .message import EmailMessage
5
5
6
- from patchwork .common .utils .input_parsing import parse_to_list
7
6
from patchwork .common .utils .utils import mustache_render
8
7
from patchwork .step import Step
9
8
from patchwork .steps .SendEmail .typed import SendEmailInputs , SendEmailOutputs
@@ -16,7 +15,7 @@ def __init__(self, inputs):
16
15
self .subject = inputs .get ("subject" , "Patchwork Execution Email" )
17
16
self .body = inputs .get ("body" , "Patchwork Execution Email" )
18
17
self .sender_email = inputs ["sender_email" ]
19
- self .recipient_email = parse_to_list ( inputs ["recipient_email" ], [ " " , "," ])
18
+ self .recipient_email = inputs ["recipient_email" ]
20
19
self .smtp_host = inputs .get ("smtp_host" , "smtp.gmail.com" )
21
20
self .smtp_username = inputs ["smtp_username" ]
22
21
self .smtp_password = inputs ["smtp_password" ]
@@ -29,7 +28,7 @@ def run(self) -> dict:
29
28
msg .set_content (mustache_render (self .body , self .email_template_value ))
30
29
msg ["Subject" ] = mustache_render (self .subject , self .email_template_value )
31
30
msg ["From" ] = self .sender_email
32
- msg ["To" ] = ", " . join ( self .recipient_email )
31
+ msg ["To" ] = self .recipient_email
33
32
if self .reply_message_id is not None :
34
33
msg .add_header ("Reference" , self .reply_message_id )
35
34
msg .add_header ("In-Reply-To" , self .reply_message_id )
0 commit comments