diff --git a/jsk_robot_common/jsk_robot_startup/scripts/smach_to_mail.py b/jsk_robot_common/jsk_robot_startup/scripts/smach_to_mail.py index dee5af4b08..e892a383a1 100755 --- a/jsk_robot_common/jsk_robot_startup/scripts/smach_to_mail.py +++ b/jsk_robot_common/jsk_robot_startup/scripts/smach_to_mail.py @@ -182,7 +182,10 @@ def _send_mail(self, subject, state_list): image = EmailBody() image.type = 'img' image.img_size = 100 - image.img_data = x['IMAGE'] + img_txt = x['IMAGE'] + if isinstance(img_txt, bytes): + img_txt = img_txt.decode('utf-8') + image.img_data = img_txt email_msg.body.append(image) email_msg.body.append(changeline) email_msg.body.append(changeline)