Skip to content

Releases: pylint-dev/astroid

v2.11.6

13 Jun 14:28
Compare
Choose a tag to compare
  • The Qt brain now correctly treats calling .disconnect() (with no
    arguments) on a slot as valid.

  • The argparse brain no longer incorrectly adds "Namespace" to the locals
    of functions that return an argparse.Namespace object.

    Refs pylint-dev/pylint#6895

v2.11.5

09 May 11:40
Compare
Choose a tag to compare
  • Fix crash while obtaining object_type() of an Unknown node.

    Refs pylint-dev/pylint#6539

  • Fix a bug where in attempting to handle the patching of distutils by virtualenv,
    library submodules called distutils (e.g. numpy.distutils) were included also.

    Refs pylint-dev/pylint#6497

v2.11.4

02 May 12:00
Compare
Choose a tag to compare
  • Fix col_offset attribute for nodes involving with on PyPy.

  • Fixed a crash involving two starred expressions: one inside a comprehension,
    both inside a call.

    Refs pylint-dev/pylint#6372

  • Made FunctionDef.implicit_parameters return 1 for methods by making
    FunctionDef.is_bound return True, as it does for class methods.

    Closes pylint-dev/pylint#6464

  • Fixed a crash when _filter_stmts encounters an EmptyNode.

    Closes pylint-dev/pylint#6438

v2.11.3

19 Apr 20:33
Compare
Choose a tag to compare

v2.11.2

26 Mar 19:44
Compare
Choose a tag to compare

v2.11.1

22 Mar 23:18
Compare
Choose a tag to compare
  • Promoted getattr() from astroid.scoped_nodes.FunctionDef to its parent
    astroid.scoped_nodes.Lambda.

  • Fixed crash on direct inference via nodes.FunctionDef._infer.

    Closes #817

v2.11.0

12 Mar 12:13
Compare
Choose a tag to compare
  • Add new (optional) doc_node attribute to nodes.Module, nodes.ClassDef,
    and nodes.FunctionDef.

  • Accessing the doc attribute of nodes.Module, nodes.ClassDef, and
    nodes.FunctionDef has been deprecated in favour of the doc_node attribute.
    Note: doc_node is an (optional) nodes.Const whereas doc was an (optional) str.

  • Passing the doc argument to the __init__ of nodes.Module, nodes.ClassDef,
    and nodes.FunctionDef has been deprecated in favour of the postinit doc_node attribute.
    Note: doc_node is an (optional) nodes.Const whereas doc was an (optional) str.

  • Replace custom cachedproperty with functools.cached_property and deprecate it
    for Python 3.8+.

    Closes #1410

  • Set end_lineno and end_col_offset attributes to None for all nodes
    with PyPy 3.8. PyPy 3.8 assigns these attributes inconsistently which could lead
    to unexpected errors. Overwriting them with None will cause a fallback
    to the already supported way of PyPy 3.7.

  • Add missing shape parameter to numpy zeros_like, ones_like,
    and full_like methods.

    Closes pylint-dev/pylint#5871

  • Only pin wrapt on the major version.

v2.10.0

27 Feb 21:54
Compare
Choose a tag to compare
  • Fixed inference of self in binary operations in which self
    is part of a list or tuple.

    Closes pylint-dev/pylint#4826

  • Fixed builtin inference on property calls not calling the postinit of the new node, which
    resulted in instance arguments missing on these nodes.

  • Fixed a crash on Super.getattr when the attribute was previously uninferable due to a cache
    limit size. This limit can be hit when the inheritance pattern of a class (and therefore of the
    __init__ attribute) is very large.

    Closes pylint-dev/pylint#5679

  • Include names of keyword-only arguments in astroid.scoped_nodes.Lambda.argnames.

    Closes pylint-dev/pylint#5771

  • Fixed a crash inferring on a NewType named with an f-string.

    Closes pylint-dev/pylint#5770

  • Add support for attrs v21.3.0 which
    added a new attrs module alongside the existing attr.

    Closes #1330

  • Use the end_lineno attribute for the NodeNG.tolineno property
    when it is available.

    Closes #1350

  • Add is_dataclass attribute to ClassDef nodes.

  • Use sysconfig instead of distutils to determine the location of
    python stdlib files and packages.

    Related pull requests: #1322, #1323, #1324
    Closes #1282
    Ref #1103

  • Fixed crash with recursion error for inference of class attributes that referenced
    the class itself.

    Closes pylint-dev/pylint#5408

  • Fixed crash when trying to infer items() on the __dict__
    attribute of an imported module.

    Closes #1085

  • Add optional NodeNG.position attribute.
    Used for block nodes to highlight position of keyword(s) and name
    in cases where the AST doesn't provide good enough positional information.
    E.g. nodes.ClassDef, nodes.FunctionDef.

  • Fix ClassDef.fromlineno. For Python < 3.8 the lineno attribute includes decorators.
    fromlineno should return the line of the class statement itself.

  • Performance improvements. Only run expensive decorator functions when
    non-default Deprecation warnings are enabled, eg. during a Pytest run.

    Closes #1383

v2.9.3

09 Jan 16:18
Compare
Choose a tag to compare
  • Fixed regression where packages without a __init__.py file were
    not recognized or imported correctly.

    Closes #1327

v2.9.2

03 Jan 23:16
Compare
Choose a tag to compare
  • Fixed regression in astroid.scoped_nodes where _is_metaclass
    was not accessible anymore.

Closes #1325