Repository navigation
0.12.1
·
8 commits
to main
since this release
Immutable
release. Only release title and notes can be modified.
Changes
comprehension-complexityallows twoforclauses and reports from the third, as a pairing of two sequences still reads as one step (#137) by @gaborbernat.
Bug fixes
definition-before-useno longer pins a class named in the annotations of a standard decorator that never evaluates them, such asdataclass,property,contextmanagerorfunctools.cache, when annotations are lazy, and no longer reads@name.setteras calling the getter while the class body runs (#137) by @gaborbernat.empty-collection-comparisonleaves.get(key) == [],.get(key, None) == []andgetattr(obj, name, None) == ()alone: a missing value givesNone, which a truth test would take for an empty one (#137) by @gaborbernat.iterator-reusereads the two sides ofa if test else bas separate branches, so a generator each side consumes is no longer reported (#137) by @gaborbernat.mutable-module-constantkeeps a comment inside alist[...]annotation when its fix makes it atuple[..., ...]: it renames the base and adds the, ...instead of rewriting the whole annotation (#137) by @gaborbernat.mutable-module-constantleavespytestmarkand the other names pytest reads by name alone: its fix madepytestmarka tuple, which pytest rejects as a single mark (#137) by @gaborbernat.too-many-attributesand the rules that tell class attributes from instance ones read__init_subclass__and__class_getitem__as class methods, which Python makes them without a decorator (#137) by @gaborbernat.unused-dependencyno longer reports the requirements of a project nested under the tests, which a fixture may list unused on purpose (#137) by @gaborbernat.