Bug#1064790: reportbug: regression when max reports per hour reached
Package: reportbug
Version: 13.0.0
Severity: normal
Dear Maintainer,
reportbug crashes when maximum number of reports per hour is reached. This is a regression from previous version where reportbug instead offered to try again instead of crashing. Traceback attached.
Connecting to reportbug.debian.org via SMTP...
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/reportbug/submit.py", line 484, in send_report
refused = conn.sendmail(fromaddr, toaddrs, message)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/smtplib.py", line 901, in sendmail
raise SMTPRecipientsRefused(senderrs)
smtplib.SMTPRecipientsRefused: {'submit@bugs.debian.org': (451, b'sorry, only 5 reports per hour for submission')}
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/bin/reportbug", line 2386, in <module>
main()
File "/usr/bin/reportbug", line 1094, in main
return iface.user_interface()
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/bin/reportbug", line 2369, in user_interface
submit.send_report(
File "/usr/lib/python3/dist-packages/reportbug/submit.py", line 499, in send_report
if ui.yes_no(f'SMTP send failure: {x}. You can retry, or save the report and exit. Do you want to retry?',
^
UnboundLocalError: cannot access local variable 'x' where it is not associated with a value
Reply to: