/
View dependency graph
Depends on
- dh-python (dh-sequence-python3)
- pytest (python3-pytest)
- python3-defaults (python3-all)
- setuptools (python3-setuptools)
- debhelper-compat, python3-pytest-runner
README (full)
flake8-mutable
Motivation
Python's default arguments are evaluated at definition as opposed to when the function is invoked. This leads to unexpected behavior, as mutations persist between calls. For a more detailed explanation, see The Hitchhiker's Guide to Python.
Example
def fnc(a, b={}):
pass
foo.py:2:14: M511 - mutable default arg of type Dict
Installation
pip install flake8-mutable
Changes
[1.1.0] 2016-11-26
- Callables
[1.0.6] 2016-11-26
- added MANIFEST.in
License
| dir | debian/ |
| dir | tests/ |
| file | .gitignore |
| file | .travis.yml |
| file | LICENSE |
| file | MANIFEST.in |
| file | README.md |
| file | dev-requirements.txt |
| file | mutable_defaults.py |
| file | requirements.txt |
| file | setup.cfg |
| file | setup.py |