You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Django 1.8.3 security update introduces a backport (django/django@76c526f) which casts the verbosity argument to an int.
This results in the error:
File ".../django-mailer/django_mailer/management/commands/__init__.py", line 13, in create_handler
handler.setLevel(LOGGING_LEVEL[verbosity])
KeyError: 1
to: LOGGING_LEVEL = {0: logging.ERROR, 1: logging.WARNING, 2: logging.DEBUG}
because I don't need to maintain backwards compatibility with earlier Django versions.
A backwards compatible fix in this source repo would need either a version check to set LOGGING_LEVEL appropriately or a try-catch in create_handler to cast if there's a KeyError.
The text was updated successfully, but these errors were encountered:
The Django 1.8.3 security update introduces a backport (django/django@76c526f) which casts the verbosity argument to an int.
This results in the error:
In my fork I just needed to change LOGGING_LEVEL in https://github.com/SmileyChris/django-mailer-2/blob/master/django_mailer/management/commands/__init__.py#L4 from:
LOGGING_LEVEL = {'0': logging.ERROR, '1': logging.WARNING, '2': logging.DEBUG}
to:
LOGGING_LEVEL = {0: logging.ERROR, 1: logging.WARNING, 2: logging.DEBUG}
because I don't need to maintain backwards compatibility with earlier Django versions.
A backwards compatible fix in this source repo would need either a version check to set LOGGING_LEVEL appropriately or a try-catch in create_handler to cast if there's a KeyError.
The text was updated successfully, but these errors were encountered: