Control: reassign -1 python3.12 Control: found -1 3.12.6-1 Control: affects -1 unattended-upgrades Control: forwarded -1 https://github.com/python/cpython/issues/124170
(also anything that received the security update, but it's hard to track as it's multiple packages) On Tue, Aug 27, 2024 at 11:50:58AM GMT, Moritz Schlarb wrote: > Package: unattended-upgrades > Version: 2.11 > Severity: normal > > Dear Maintainer, > > I found the following python tracebacks in my syslog: > > apt.systemd.daily: Traceback (most recent call last): > apt.systemd.daily: File "/usr/bin/unattended-upgrade", line 2246, in main > apt.systemd.daily: send_summary_mail(res.pkgs, res.success, > res.result_str, > apt.systemd.daily: File "/usr/bin/unattended-upgrade", line 1728, in > send_summary_mail > apt.systemd.daily: ret = _send_mail_using_sendmail(from_email, to_email, > subject, body) > apt.systemd.daily: > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > apt.systemd.daily: File "/usr/bin/unattended-upgrade", line 1624, in > _send_mail_using_sendmail > apt.systemd.daily: sendmail.stdin.write(msg.as_string()) > apt.systemd.daily: ^^^^^^^^^^^^^^^ > apt.systemd.daily: File "/usr/lib/python3.12/email/message.py", line 181, > in as_string > apt.systemd.daily: from email.generator import Generator > apt.systemd.daily: File "/usr/lib/python3.12/email/generator.py", line 17, > in <module> > apt.systemd.daily: from email.errors import HeaderWriteError > apt.systemd.daily: ImportError: cannot import name 'HeaderWriteError' from > 'email.errors' (/usr/lib/python3.12/email/errors.py). Did you mean: > 'HeaderParseError'? > apt.systemd.daily: During handling of the above exception, another exception > occurred: > apt.systemd.daily: Traceback (most recent call last): > apt.systemd.daily: File "/usr/bin/unattended-upgrade", line 2757, in > <module> > apt.systemd.daily: sys.exit(main(options)) > apt.systemd.daily: ^^^^^^^^^^^^^ > apt.systemd.daily: File "/usr/bin/unattended-upgrade", line 2271, in main > apt.systemd.daily: send_summary_mail(["<unknown>"], False, _("An error > occurred"), > apt.systemd.daily: File "/usr/bin/unattended-upgrade", line 1728, in > send_summary_mail > apt.systemd.daily: ret = _send_mail_using_sendmail(from_email, to_email, > subject, body) > apt.systemd.daily: > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > apt.systemd.daily: File "/usr/bin/unattended-upgrade", line 1624, in > _send_mail_using_sendmail > apt.systemd.daily: sendmail.stdin.write(msg.as_string()) > apt.systemd.daily: ^^^^^^^^^^^^^^^ > apt.systemd.daily: File "/usr/lib/python3.12/email/message.py", line 181, > in as_string > apt.systemd.daily: from email.generator import Generator > apt.systemd.daily: File "/usr/lib/python3.12/email/generator.py", line 17, > in <module> > apt.systemd.daily: from email.errors import HeaderWriteError > apt.systemd.daily: ImportError: cannot import name 'HeaderWriteError' from > 'email.errors' (/usr/lib/python3.12/email/errors.py). Did you mean: > 'HeaderParseError'? This happens because the new python security update introduces a new error class HeaderWriteError and email.generator is made to rely on this. Now, email.generator is not imported by the application, but inside the function call of email.message.Message.as_string() which happens after the update. But our previous imports of email.message already imported email.errors from before the update, so we are lacking the new error class. -- debian developer - deb.li/jak | jak-linux.org - free software dev ubuntu core developer i speak de, en