diff --git a/doc/data/messages/l/logging-too-many-args/bad.py b/doc/data/messages/l/logging-too-many-args/bad.py new file mode 100644 index 0000000000..f94222aa4f --- /dev/null +++ b/doc/data/messages/l/logging-too-many-args/bad.py @@ -0,0 +1,7 @@ +import logging + +try: + function() +except Exception as e: + logging.error('Error occured: %s', type(e), e) # [logging-too-many-args] + raise diff --git a/doc/data/messages/l/logging-too-many-args/good.py b/doc/data/messages/l/logging-too-many-args/good.py new file mode 100644 index 0000000000..3772c59b20 --- /dev/null +++ b/doc/data/messages/l/logging-too-many-args/good.py @@ -0,0 +1,7 @@ +import logging + +try: + function() +except Exception as e: + logging.error('%s error occured: %s', type(e), e) + raise