Skip to content

Releases: pylint-dev/astroid

v2.8.1-rc1

07 Oct 05:33
Compare
Choose a tag to compare

This is the real 2.8.1 following a mistake when creating the tag for it, see #1199 (comment)

v2.8.1

06 Oct 20:21
Compare
Choose a tag to compare
  • Adds support of type hints inside numpy's brains.

    Closes pylint-dev/pylint#4326

  • Enable inference of dataclass import from pydantic.dataclasses.
    This allows the dataclasses brain to recognize pydantic dataclasses.

    Closes pylint-dev/pylint#4899

  • Fix regression on ClassDef inference

    Closes pylint-dev/pylint#5030
    Closes pylint-dev/pylint#5036

  • Fix regression on Compare node inference

    Closes pylint-dev/pylint#5048

  • Extended attrs brain to support the provisional APIs

  • Astroid does not trigger it's own deprecation warning anymore.

  • Improve brain for typing.Callable and typing.Type.

  • Fix bug with importing namespace packages with relative imports

    Closes pylint-dev/pylint#5059

  • The is_typing_guard and is_sys_guard functions are deprecated and will
    be removed in 3.0.0. They are complex meta-inference functions that are better
    suited for pylint. Import them from pylint.checkers.utils instead
    (requires pylint 2.12).

  • Suppress the conditional between applied brains and dynamic import authorized
    modules. (Revert the "The transforms related to a module are applied only if this
    module has not been explicitly authorized to be imported" of version 2.7.3)

  • Adds a brain to infer the numpy.ma.masked_where function.

    Closes pylint-dev/pylint#3342

v2.8.0

14 Sep 07:27
Compare
Choose a tag to compare
  • Add additional deprecation warnings in preparation for astroid 3.0

    • Require attributes for some node classes with __init__ call.

      • name (str) for Name, AssignName, DelName
      • attrname (str) for Attribute, AssignAttr, DelAttr
      • op (str) for AugAssign, BinOp, BoolOp, UnaryOp
      • names (list[tuple[str, str | None]]) for Import
  • Support pyz imports

    Closes pylint-dev/pylint#3887

  • Add node_ancestors method to NodeNG for obtaining the ancestors of nodes.

  • It's now possible to infer the value of comparison nodes

    Closes #846

  • Fixed bug in inference of dataclass field calls.

    Closes pylint-dev/pylint#4963

v2.7.3

30 Aug 16:37
Compare
Choose a tag to compare
  • The transforms related to a module are applied only if this module has not been explicitly authorized to be imported
    (i.e is not in AstroidManager.extension_package_whitelist). Solves the following issues if numpy is authorized to be imported
    through the extension-pkg-allow-list option.

    Closes pylint-dev/pylint#3342
    Closes pylint-dev/pylint#4326

  • Fixed bug in attribute inference from inside method calls.

    Closes pylint-dev/pylint#400

  • Fixed bug in inference for superclass instance methods called
    from the class rather than an instance.

    Closes #1008
    Closes pylint-dev/pylint#4377

  • Fixed bug in inference of chained attributes where a subclass
    had an attribute that was an instance of its superclass.

    Closes pylint-dev/pylint#4220

  • Adds a brain for the ctypes module.

    Closes pylint-dev/pylint#4896

  • When processing dataclass attributes, exclude the same type hints from abc.collections
    as from typing.

    Closes pylint-dev/pylint#4895

  • Apply dataclass inference to pydantic's dataclasses.

    Closes pylint-dev/pylint#4899

v2.7.2

20 Aug 19:09
Compare
Choose a tag to compare
  • BaseContainer is now public, and will replace _BaseContainer completely in astroid 3.0.

  • astroid.const.BUILTINS and astroid.bases.BUILTINS are not used internally anymore
    and will be removed in astroid 3.0. Simply replace this by the string 'builtins' for better
    performances and clarity.

  • Add inference for dataclass initializer method.

    Closes pylint-dev/pylint#3201

v2.7.1

16 Aug 17:28
Compare
Choose a tag to compare
  • When processing dataclass attributes, only do typing inference on collection types.
    Support for instantiating other typing types is left for the future, if desired.

    Closes #1129

  • Fixed LookupMixIn missing from astroid.node_classes.

v2.7.0

16 Aug 10:59
Compare
Choose a tag to compare

v2.6.6

03 Aug 20:42
Compare
Choose a tag to compare
  • Added support to infer return type of typing.cast()

  • Fix variable lookup's handling of exclusive statements

    Closes pylint-dev/pylint#3711

  • Fix variable lookup's handling of function parameters

    Closes #180

  • Fix variable lookup's handling of except clause variables

  • Fix handling of classes with duplicated bases with the same name

    Closes #1088

v2.6.5

21 Jul 06:50
Compare
Choose a tag to compare
  • Fix a crash when there would be a 'TypeError object does not support
    item assignment' in the code we parse.

    Closes pylint-dev/pylint#4439

  • Fix a crash when a AttributeInferenceError was raised when
    failing to find the real name in infer_import_from.

    Closes pylint-dev/pylint#4692

v2.6.4

19 Jul 21:41
Compare
Choose a tag to compare
  • Fix a crash when a StopIteration was raised when inferring
    a faulty function in a context manager.

    Closes pylint-dev/pylint#4723