Page MenuHomeSolus

Update python-astroid to 1.6.0
ClosedPublic

Authored by EP01 on Dec 15 2017, 12:43 PM.

Details

Summary
  • When verifying duplicates classes in MRO, ignore on-the-fly generated classes
  • Add brain tip for attrs library to prevent unsupported-assignment-operation false positives
  • file_stream was removed, since it was deprecated for three releases
    • Instead one should use the .stream() method.
  • Vast improvements to numpy support
  • Add brain tips for curses
  • Add brain tips for UUID.int
  • The result of using object.__new__ as class decorator is correctly inferred as instance
  • Enums created with functional syntax are now iterable
  • Enums created with functional syntax are now subscriptable
  • Don't crash when getting the string representation of BadUnaryOperationMessage
    • In some cases, when the operand does not have a .name attribute, getting the string representation of a BadUnaryOperationMessage leads to a crash.
  • Don't raise DuplicateBaseError when classes at different locations are used
    • For instance, one can implement a namedtuple base class, which gets reused on a class with the same name later on in the file. Until now, we considered these two classes as being the same, because they shared the name, but in fact they are different, being created at different locations and through different means.
  • The func form of namedtuples with keywords is now understood
  • Dunder class at method level is now inferred as the class of the method
Test Plan

Tested with pylint.

Diff Detail

Repository
R3709 python-astroid
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

EP01 created this revision.Dec 15 2017, 12:43 PM
EP01 edited the summary of this revision. (Show Details)Dec 15 2017, 12:45 PM
EP01 edited the summary of this revision. (Show Details)
EP01 edited the summary of this revision. (Show Details)Dec 15 2017, 12:47 PM
EP01 added a child revision: D1618: Update pylint to 1.8.1.
JoshStrobl accepted this revision.Jan 6 2018, 6:34 PM
This revision is now accepted and ready to land.Jan 6 2018, 6:34 PM
This revision was automatically updated to reflect the committed changes.