ALL-OVER0001 · evidence
This page continues ALL-OVER0001 directly from its source docstring. Read its implementation.
Evidence
Section titled “Evidence”Each finding names the subclass, the base, the member, and both parameter lists in the order each side states them, with how every parameter binds. The value counts the ways one override departs, so a signature that changed its arguments and also dropped a tail counts twice.
Exceptions
Section titled “Exceptions”A name that begins with two underscores is left alone, because Python either rewrites it into
the class that wrote it or calls it itself, so neither one is part of a substitution anybody
can perform. A setter is left alone too, since the assigned value reaches it as an argument
the reader never wrote. A parameter the override adds with a default extends the base rather
than breaking it, and an override ending in *args accepts whatever the base accepted, so
the positions it stopped naming are the ones that tail stands for.
A positional-only parameter counts toward the arguments and never toward the names, which is exactly what it is. Pylint reads its own tree through a list that leaves positional-only parameters out altogether, so an override that drops one is reported here and nowhere there.
References
Section titled “References”- Generalizes Pylint W0221 arguments-differ. Open reference
- Cites “A Behavioral Notion of Subtyping”, 1994
- Cites “Agile Software Development”, the Liskov substitution principle