pylint-dev/astroid

`ClassDef.instance_attrs` is being mutated during inference

jacobtylerwalls opened this issue · 0 comments

Steps to reproduce

  1. Clone music21 (from pylint primer)
  2. Revert the pylint change from pylint-dev/pylint@81be03b
  3. Compare:
  • pylint music21.roman --disable=all --enable=too-many-instance-attributes
  • pylint music21 --disable=all --enable=too-many-instance-attributes

Current behavior

The second form gives a too-many-instance-attributes message because it finds 5 extra instance attributes from a parent class using properties.

Expected behavior

no message

python -c "from astroid import __pkginfo__; print(__pkginfo__.version)" output

pylint 3.0.0b1
astroid 3.0.0a9-dev0