The NetBSD Project

CVS log for pkgsrc/devel/py-astroid/Makefile

[BACK] Up to [] / pkgsrc / devel / py-astroid

Request diff between arbitrary revisions

Default branch: MAIN

Revision 1.83 / (download) - annotate - [select for diffs], Sat Oct 28 19:56:57 2023 UTC (5 weeks, 4 days ago) by wiz
Branch: MAIN
Changes since 1.82: +3 -1 lines
Diff to previous 1.82 (colored)

python/ simplify a lot, and switch to 'installer' for installation

This follows the recommended bootstrap method (flit_core, build, installer).

However, installer installs different files than pip, so update PLISTs
for all packages using and bump their PKGREVISIONs.

Revision 1.82 / (download) - annotate - [select for diffs], Mon Oct 16 08:55:39 2023 UTC (7 weeks, 2 days ago) by adam
Branch: MAIN
Changes since 1.81: +2 -2 lines
Diff to previous 1.81 (colored)

py-astroid: updated to 3.0.1


Fix crashes linting code using PEP 695 (Python 3.12) generic type syntax.

Revision 1.81 / (download) - annotate - [select for diffs], Mon Oct 9 17:38:30 2023 UTC (8 weeks, 2 days ago) by adam
Branch: MAIN
Changes since 1.80: +2 -2 lines
Diff to previous 1.80 (colored)

py-astroid: updated to 3.0.0

What's New in astroid 3.0.0?

* Add support for Python 3.12, including PEP 695 type parameter syntax.

* Remove support for Python 3.7.

* Use the global inference cache when inferring, even without an explicit
  ``InferenceContext``. This is a significant performance improvement given how
  often methods default to ``None`` for the context argument. (Linting ``astroid``
  itself now takes ~5% less time on Python 3.12; other projects requiring more
  complex inference calculations will see greater speedups.)

* Following a deprecation period starting in astroid 2.7.0, the ``astroid.node_classes``
  and ``astroid.scoped_nodes`` modules have been removed in favor of ``astroid.nodes.node_classes``
  and ``astroid.nodes.scoped_nodes``.

* Following a deprecation period starting in astroid 2.12.0, the ``astroid.mixins`` module
  has been removed in favor of ``astroid.nodes._base_nodes`` (private).

* Return all existing arguments when calling ``Arguments.arguments()``. This also means ``find_argname`` will now
  use the whole list of arguments for its search.

* Exclude class attributes from the ``__members__`` container of an ``Enum`` class when they are
  ``nodes.AnnAssign`` nodes with no assigned value.

* Remove ``@cached`` and ``@cachedproperty`` decorator (just use ``@cached_property`` from the stdlib).

* Remove the ``inference`` module. Node inference methods are now in the module
  defining the node, rather than being associated to the node afterward.

* Move ``LookupMixIn`` to ``astroid.nodes._base_nodes`` and make it private.

* Remove the shims for ``OperationError``, ``BinaryOperationError``, and ``UnaryOperationError``
  in ``exceptions``. They were moved to ``util`` in astroid 1.5.0.

* Move ``safe_infer()`` from ``helpers`` to ``util``. This avoids some circular imports.

* Reduce file system access in ``ast_from_file()``.

* Reduce time to ``import astroid`` by delaying ``astroid_bootstrapping()`` until
  the first instantiation of ``AstroidBuilder``.

* Make ``igetattr()`` idempotent. This addresses some reports of varying results
  when running pylint with ``--jobs``.

* Fix incorrect cache keys for inference results, thereby correctly inferring types
  for calls instantiating types dynamically.

* Fix interrupted ``InferenceContext`` call chains, thereby addressing performance
  problems when linting ``sqlalchemy``.

* ``nodes.FunctionDef`` no longer inherits from ``nodes.Lambda``.
  This is a breaking change but considered a bug fix as the nodes did not share the same
  API and were not interchangeable.

  We have tried to minimize the amount of breaking changes caused by this change
  but some are unavoidable.

* ``infer_call_result`` now shares the same interface across all implementations. Namely:
  def infer_call_result(
                caller: SuccessfulInferenceResult | None,
                context: InferenceContext | None = None,
            ) -> Iterator[InferenceResult]:

  This is a breaking change for ``nodes.FunctionDef`` where previously ``caller`` had a default of
  ``None``. Passing ``None`` again will not create a behaviour change.
  The breaking change allows us to better type and re-use the method within ``astroid``.

* Improved signature of the ``__init__`` and ``__postinit__`` methods of most nodes.
  This includes making ``lineno``, ``col_offset``, ``end_lineno``, ``end_col_offset`` and ``parent``
  required arguments for ``nodes.NodeNG`` and its subclasses.
  For most other nodes, arguments of their ``__postinit__`` methods have been made required to better
  represent how they would normally be constructed by the standard library ``ast`` module.

Revision 1.80 / (download) - annotate - [select for diffs], Thu Sep 28 15:55:46 2023 UTC (2 months, 1 week ago) by adam
Branch: MAIN
Changes since 1.79: +2 -2 lines
Diff to previous 1.79 (colored)

py-astroid: updated to 2.15.8

Fix a regression in 2.15.7 for unsubscriptable-object.

Fix a crash when inferring a typing.TypeVar call.

Infer user-defined enum classes by checking if the class is a subtype of enum.Enum.

Fix inference of functions with @functools.lru_cache decorators without

Make sys.argv uninferable because it never is. (It's impossible to infer
the value it will have outside of static analysis where it's our own value.)v2.15.7
Fix a crash when inferring a typing.TypeVar call.

Infer user-defined enum classes by checking if the class is a subtype of enum.Enum.

Fix inference of functions with @functools.lru_cache decorators without

Make sys.argv uninferable because it never is. (It's impossible to infer
the value it will have outside of static analysis where it's our own value.)

Revision 1.79 / (download) - annotate - [select for diffs], Mon Jul 10 03:41:20 2023 UTC (4 months, 4 weeks ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2023Q3-base, pkgsrc-2023Q3
Changes since 1.78: +2 -2 lines
Diff to previous 1.78 (colored)

py-astroid: updated to 2.15.6

What's New in astroid 2.15.6?
* Harden ``get_module_part()`` against ``"."``.
* Avoid expensive list/tuple multiplication operations that would result in ``MemoryError``.

Revision 1.78 / (download) - annotate - [select for diffs], Sun May 21 17:42:11 2023 UTC (6 months, 2 weeks ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2023Q2-base, pkgsrc-2023Q2
Changes since 1.77: +2 -2 lines
Diff to previous 1.77 (colored)

py-astroid: update to 2.15.5.

    Handle objects.Super in helpers.object_type().
    Refs pylint-dev/pylint#8554

Revision 1.77 / (download) - annotate - [select for diffs], Thu Apr 27 17:52:25 2023 UTC (7 months, 1 week ago) by adam
Branch: MAIN
Changes since 1.76: +2 -2 lines
Diff to previous 1.76 (colored)

py-astroid: updated to 2.15.4

What's New in astroid 2.15.4?
* Add visitor function for ``TryStar`` to ``AsStringVisitor`` and
  add ``TryStar`` to ``astroid.nodes.ALL_NODE_CLASSES``.

Revision 1.76 / (download) - annotate - [select for diffs], Mon Apr 17 05:28:42 2023 UTC (7 months, 3 weeks ago) by adam
Branch: MAIN
Changes since 1.75: +2 -2 lines
Diff to previous 1.75 (colored)

py-astroid: updated to 2.15.3

What's New in astroid 2.15.3?
* Fix ``infer_call_result()`` crash on methods called ``with_metaclass()``.
* Suppress ``UserWarning`` when finding module specs.

Revision 1.75 / (download) - annotate - [select for diffs], Wed Apr 5 11:19:28 2023 UTC (8 months ago) by adam
Branch: MAIN
Changes since 1.74: +4 -5 lines
Diff to previous 1.74 (colored)

py-astroid: updated to 2.15.2

What's New in astroid 2.15.2?
* Support more possible usages of ``attrs`` decorators.

What's New in astroid 2.15.1?
* Restore behavior of setting a Call as a base for classes created using ``six.with_metaclass()``,
  and harden support for using enums as metaclasses in this case.

Revision 1.74 / (download) - annotate - [select for diffs], Wed Mar 29 09:34:05 2023 UTC (8 months, 1 week ago) by wiz
Branch: MAIN
Changes since 1.73: +3 -2 lines
Diff to previous 1.73 (colored)


Revision 1.73 / (download) - annotate - [select for diffs], Thu Mar 9 09:47:47 2023 UTC (8 months, 4 weeks ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2023Q1-base, pkgsrc-2023Q1
Changes since 1.72: +2 -2 lines
Diff to previous 1.72 (colored)

py-astroid: updated to 2.15.0

What's New in astroid 2.15.0?

* astroid now supports ``TryStar`` nodes from python 3.11 and should be fully compatible with python 3.11.

* ``Formattedvalue.postinit`` is now keyword only. This is to allow correct typing of the
  ``Formattedvalue`` class.

* ``Astroid`` now supports custom import hooks.

* ``astroid`` now infers return values from match cases.

* ``AstroidManager.clear_cache`` now also clears the inference context cache.

* ``Astroid`` now retrieves the default values of keyword only arguments and sets them on

* ``Uninferable`` now has the type ``UninferableBase``. This is to facilitate correctly type annotating
  code that uses this singleton.

* Deprecate ``modutils.is_standard_module()``. It will be removed in the next minor release.
  Functionality has been replaced by two new functions,
  ``modutils.is_stdlib_module()`` and ``modutils.module_in_path()``.

* Fix ``are_exclusive`` function when a walrus operator is used inside ``IfExp.test`` field.

Revision 1.72 / (download) - annotate - [select for diffs], Mon Feb 13 10:45:11 2023 UTC (9 months, 3 weeks ago) by adam
Branch: MAIN
Changes since 1.71: +2 -2 lines
Diff to previous 1.71 (colored)

py-astroid: updated to 2.14.2

What's New in astroid 2.14.2?
* '_infer_str_format_call' won't crash anymore when the string it analyses are uninferable.

Revision 1.71 / (download) - annotate - [select for diffs], Thu Feb 2 08:26:16 2023 UTC (10 months ago) by adam
Branch: MAIN
Changes since 1.70: +2 -2 lines
Diff to previous 1.70 (colored)

py-astroid: updated to 2.14.1

What's New in astroid 2.14.1?
* Revert ``CallContext`` change as it caused a ``RecursionError`` regression.

What's New in astroid 2.14.0?
* Add support for inferring binary union types added in Python 3.10.
* Capture and log messages emitted when inspecting a module for astroid.

Revision 1.70 / (download) - annotate - [select for diffs], Tue Jan 24 10:07:28 2023 UTC (10 months, 1 week ago) by adam
Branch: MAIN
Changes since 1.69: +6 -5 lines
Diff to previous 1.69 (colored)

py-astroid: updated to 2.13.3

What's New in astroid 2.13.3?
* Fix a regression in 2.13.2 where a RunTimeError could be raised unexpectedly.
* Fix overwritten attributes in inherited dataclasses not being ordered correctly.
* Fix a false positive when an attribute named ``Enum`` was confused with ``enum.Enum``.
  Calls to ``Enum`` are now inferred & the qualified name is checked.
* Remove unnecessary typing_extensions dependency on Python 3.11 and newer

What's New in astroid 2.13.2?
* Removed version conditions on typing_extensions dependency. Removed typing_extensions from
  our tests requirements as it was preventing issues to appear in our continuous integration.

What's New in astroid 2.13.1?
* Bumping typing_extensions to 4.0.0 that is required when using ``Self``

What's New in astroid 2.13.0?
* Fixed importing of modules that have the same name as the file that is importing.
  ``astroid`` will now correctly handle an ``import math`` statement in a file called ````
  by relying on the import system.
* Create ``ContextManagerModel`` and let ``GeneratorModel`` inherit from it.
* Added a ``regex`` brain.
* Support "is None" constraints from if statements during inference.

Revision 1.69 / (download) - annotate - [select for diffs], Sun Nov 20 17:50:20 2022 UTC (12 months, 2 weeks ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2022Q4-base, pkgsrc-2022Q4
Changes since 1.68: +3 -3 lines
Diff to previous 1.68 (colored)

py-astroid: updated to 2.12.13

What's New in astroid 2.12.13?
* Prevent returning an empty list for ``ClassDef.slots()`` when the mro list contains one class & it is not ``object``.
* Prevent a crash when inferring calls to ``str.format`` with inferred arguments
  that would be invalid.
* Infer the `length` argument of the ``random.sample`` function.
* Catch ``ValueError`` when indexing some builtin containers and sequences during inference.

Revision 1.68 / (download) - annotate - [select for diffs], Tue Nov 8 09:07:10 2022 UTC (12 months, 4 weeks ago) by adam
Branch: MAIN
Changes since 1.67: +1 -2 lines
Diff to previous 1.67 (colored)

py-astroid: no need to depend on py-typed-ast anymore

Revision 1.67 / (download) - annotate - [select for diffs], Tue Oct 25 09:27:33 2022 UTC (13 months, 1 week ago) by adam
Branch: MAIN
Changes since 1.66: +2 -2 lines
Diff to previous 1.66 (colored)

py-astroid: updated to 2.12.12

What's New in astroid 2.12.12?
* Add the ``length`` parameter to ``hash.digest`` & ``hash.hexdigest`` in the ``hashlib`` brain.
* Prevent a crash when a module's ``__path__`` attribute is unexpectedly missing.
* Fix inferring attributes with empty annotation assignments if parent
  class contains valid assignment.

Revision 1.66 / (download) - annotate - [select for diffs], Wed Oct 12 07:43:08 2022 UTC (13 months, 3 weeks ago) by adam
Branch: MAIN
Changes since 1.65: +2 -2 lines
Diff to previous 1.65 (colored)

py-astroid: updated to 2.12.11

What's New in astroid 2.12.11?
* Improve detection of namespace packages for the modules with ``__spec__`` set to None.
* Fixed a regression in the creation of the ``__init__`` of dataclasses with
  multiple inheritance.

Revision 1.65 / (download) - annotate - [select for diffs], Mon Sep 19 07:51:50 2022 UTC (14 months, 2 weeks ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2022Q3-base, pkgsrc-2022Q3
Changes since 1.64: +2 -2 lines
Diff to previous 1.64 (colored)

py-astroid: updated to 2.12.10

What's New in astroid 2.12.10?
* Fixed a crash when introspecting modules compiled by `cffi`.
* ``decorators.cached`` now gets its cache cleared by calling ``AstroidManager.clear_cache``.

Revision 1.64 / (download) - annotate - [select for diffs], Mon Sep 12 08:27:19 2022 UTC (14 months, 3 weeks ago) by adam
Branch: MAIN
Changes since 1.63: +2 -2 lines
Diff to previous 1.63 (colored)

py-astroid: updated to 2.12.9

What's New in astroid 2.12.9?
* Fixed creation of the ``__init__`` of ``dataclassess`` with multiple inheritance.
* Fixed a crash on ``namedtuples`` that use ``typename`` to specify their name.

Revision 1.63 / (download) - annotate - [select for diffs], Tue Sep 6 19:07:54 2022 UTC (15 months ago) by adam
Branch: MAIN
Changes since 1.62: +2 -2 lines
Diff to previous 1.62 (colored)

py-astroid: updated to 2.12.8

What's New in astroid 2.12.8?
* Fixed a crash in the ``dataclass`` brain for ``InitVars`` without subscript typing.
* Fixed parsing of default values in ``dataclass`` attributes.

What's New in astroid 2.12.7?
* Fixed a crash in the ``dataclass`` brain for uninferable bases.

Revision 1.62 / (download) - annotate - [select for diffs], Tue Sep 6 06:43:48 2022 UTC (15 months ago) by adam
Branch: MAIN
Changes since 1.61: +2 -2 lines
Diff to previous 1.61 (colored)

py-astroid: updated to 2.12.6

What's New in astroid 2.12.6?
* Fix a crash involving ``Uninferable`` arguments to ``namedtuple()``.
* The ``dataclass`` brain now understands the ``kw_only`` keyword in dataclass decorators.

Revision 1.61 / (download) - annotate - [select for diffs], Tue Aug 30 09:58:05 2022 UTC (15 months, 1 week ago) by adam
Branch: MAIN
Changes since 1.60: +2 -2 lines
Diff to previous 1.60 (colored)

py-astroid: updated to 2.12.5

What's New in astroid 2.12.5?
* Prevent first-party imports from being resolved to `site-packages`.
* Fix ``astroid.interpreter._import.util.is_namespace()`` incorrectly
  returning ``True`` for frozen stdlib modules on PyPy.

Revision 1.60 / (download) - annotate - [select for diffs], Fri Aug 26 07:43:30 2022 UTC (15 months, 1 week ago) by adam
Branch: MAIN
Changes since 1.59: +2 -2 lines
Diff to previous 1.59 (colored)

py-astroid: updated to 2.12.4

What's New in astroid 2.12.4?
* Fixed a crash involving non-standard type comments such as ``# type: # any comment``.

What's New in astroid 2.12.3?
* Fixed crash in ``ExplicitNamespacePackageFinder`` involving ``_SixMetaPathImporter``.
* Fix unhandled `FutureWarning` from pandas import in cython modules
* Fix false positive with inference of type-annotated Enum classes.
* Fix crash with inference of type-annotated Enum classes where the member has no value.
* Fix a crash inferring invalid old-style string formatting with `%`.
* Fix false positive with inference of ``http`` module when iterating ``HTTPStatus``.
* Bumped minimum requirement of ``wrapt`` to 1.14 on Python 3.11.
* Don't add dataclass fields annotated with ``KW_ONLY`` to the list of fields.

Revision 1.59 / (download) - annotate - [select for diffs], Mon Jul 18 18:57:41 2022 UTC (16 months, 2 weeks ago) by adam
Branch: MAIN
Changes since 1.58: +2 -2 lines
Diff to previous 1.58 (colored)

py-astroid: updated to 2.12.2

What's New in astroid 2.12.2?

* Fixed crash in modulo operations for divisions by zero.

* Fixed crash with recursion limits during inference.

What's New in astroid 2.12.1?

* Fix a crash when inferring old-style string formatting (``%``) using tuples.

* Fix a crash when ``None`` (or a value inferred as ``None``) participates in a
  ``**`` expression.

* Fix a crash involving properties within ``if`` blocks.

What's New in astroid 2.12.0?

* Fix signal has no ``connect`` member for PySide2 5.15.2+ and PySide6

* ``astroid`` now requires Python 3.7.2 to run.

* Avoid setting a Call as a base for classes created using ``six.with_metaclass()``.

* Fix detection of builtins on ``PyPy`` 3.9.

* Fix ``re`` brain on Python ``3.11``. The flags now come from ``re._compile``.

* Build ``nodes.Module`` for frozen modules which have location information in their

* The ``astroid.mixins`` module has been deprecated and marked for removal in 3.0.0.

* Capture and log messages emitted by C extensions when importing them.
  This prevents contaminating programmatic output, e.g. pylint's JSON reporter.

* Calls to ``str.format`` are now correctly inferred.

* ``__new__`` and ``__init__`` have been added to the ``ObjectModel`` and are now
  inferred as ``BoundMethods``.

* Old style string formatting (using ``%`` operators) is now correctly inferred.

* Adds missing enums from ``ssl`` module.

* Remove dependency on ``pkg_resources`` from ``setuptools``.

* Allowed ``AstroidManager.clear_cache`` to reload necessary brain plugins.

* Fixed incorrect inferences after rebuilding the builtins module, e.g. by calling

* On Python versions >= 3.9, ``astroid`` now understands subscripting
  builtin classes such as ``enumerate`` or ``staticmethod``.

* Fixed inference of ``Enums`` when they are imported under an alias.

* Rename ``ModuleSpec`` -> ``module_type`` constructor parameter to match attribute
  name and improve typing. Use ``type`` instead.

* ``ObjectModel`` and ``ClassModel`` now know about their ``__new__`` and ``__call__`` attributes.

* Fixed pylint ``not-callable`` false positive with nested-tuple assignment in a for-loop.

* Instances of builtins created with ``__new__(cls, value)`` are now inferred.

* Infer the return value of the ``.copy()`` method on ``dict``, ``list``, ``set``,
  and ``frozenset``.

* Fixed inference of elements of living container objects such as tuples and sets in the
  ``sys`` and ``ssl`` modules.

* Add ``pathlib`` brain to handle ``pathlib.PurePath.parents`` inference.

* Avoid inferring the results of ``**`` operations involving values greater than ``1e5``
  to avoid expensive computation.

* Fix test for Python ``3.11``. In some instances ``err.__traceback__`` will
  be uninferable now.

* Add brain for numpy core module ``einsumfunc``.

* Infer the ``DictUnpack`` value for ``Dict.getitem`` calls.

* Fix a crash involving properties within ``try ... except`` blocks.

* Prevent creating ``Instance`` objects that proxy other ``Instance``s when there is
  ambiguity (or user error) in calling ``__new__(cls)``.

Revision 1.58 / (download) - annotate - [select for diffs], Wed Jun 15 11:21:01 2022 UTC (17 months, 3 weeks ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2022Q2-base, pkgsrc-2022Q2
Changes since 1.57: +2 -2 lines
Diff to previous 1.57 (colored)

py-astroid: updated to 2.11.6

What's New in astroid 2.11.6?

* 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.

Revision 1.57 / (download) - annotate - [select for diffs], Tue May 10 05:31:58 2022 UTC (18 months, 4 weeks ago) by adam
Branch: MAIN
Changes since 1.56: +2 -2 lines
Diff to previous 1.56 (colored)

py-astroid: updated to 2.11.5


Fix crash while obtaining object_type() of an Unknown node.

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.

Revision 1.56 / (download) - annotate - [select for diffs], Tue May 3 17:50:49 2022 UTC (19 months ago) by adam
Branch: MAIN
Changes since 1.55: +2 -2 lines
Diff to previous 1.55 (colored)

py-astroid: updated to 2.11.4

What's New in astroid 2.11.4?
* 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.

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

* Fixed a crash when ``_filter_stmts`` encounters an ``EmptyNode``.

Revision 1.55 / (download) - annotate - [select for diffs], Wed Apr 20 10:42:10 2022 UTC (19 months, 2 weeks ago) by adam
Branch: MAIN
Changes since 1.54: +2 -2 lines
Diff to previous 1.54 (colored)

py-astroid: updated to 2.11.3

What's New in astroid 2.11.3?
* Fixed an error in the Qt brain when building ``instance_attrs``.

* Fixed a crash in the ``gi`` brain.

What's New in astroid 2.11.2?
* Avoided adding the name of a parent namedtuple to its child's locals.

What's New in astroid 2.11.1?
* Promoted ``getattr()`` from ``astroid.scoped_nodes.FunctionDef`` to its parent

* Fixed crash on direct inference via ``nodes.FunctionDef._infer``.

What's New in astroid 2.11.0?
* 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+.

* 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.

* Only pin ``wrapt`` on the major version.

What's New in astroid 2.10.0?
* Fixed inference of ``self`` in binary operations in which ``self``
  is part of a list or tuple.

* 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.

* Inlcude names of keyword-only arguments in ``astroid.scoped_nodes.Lambda.argnames``.

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

* Add support for [attrs v21.3.0]( which
  added a new `attrs` module alongside the existing `attr`.

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

* Add ``is_dataclass`` attribute to ``ClassDef`` nodes.

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

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

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

* 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.

Revision 1.54 / (download) - annotate - [select for diffs], Mon Jan 10 11:31:00 2022 UTC (22 months, 3 weeks ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2022Q1-base, pkgsrc-2022Q1
Changes since 1.53: +2 -2 lines
Diff to previous 1.53 (colored)

py-astroid: updated to 2.9.3

What's New in astroid 2.9.3?
* Fixed regression where packages without a ```` file were
  not recognized or imported correctly.

Revision 1.53 / (download) - annotate - [select for diffs], Fri Jan 7 17:13:30 2022 UTC (22 months, 4 weeks ago) by adam
Branch: MAIN
Changes since 1.52: +2 -3 lines
Diff to previous 1.52 (colored)

py-astroid: updated to 2.9.2

What's New in astroid 2.9.2?
Release date: 2022-01-04

* Fixed regression in ``astroid.scoped_nodes`` where ``_is_metaclass``
  was not accessible anymore.

What's New in astroid 2.9.1?
Release date: 2021-12-31

* ``NodeNG.frame()`` and ``NodeNG.statement()`` will start raising ``ParentMissingError``
  instead of ``AttributeError`` in astroid 3.0. This behaviour can already be triggered
  by passing ``future=True`` to a ``frame()`` or ``statement()`` call.

* Prefer the module loader get_source() method in AstroidBuilder's
  module_build() when possible to avoid assumptions about source
  code being available on a filesystem.  Otherwise the source cannot
  be found and application behavior changes when running within an
  embedded hermetic interpreter environment (pyoxidizer, etc.).

* Require Python 3.6.2 to use astroid.

* Removed custom ``distutils`` handling for resolving paths to submodules.

* Fix ``deque.insert()`` signature in ``collections`` brain.

* Fix ``Module`` nodes not having a ``col_offset``, ``end_lineno``, and ``end_col_offset``

* Fix typing and update explanation for ``Arguments.args`` being ``None``.

* Fix crash if a variable named ``type`` is subscripted in a generator expression.

* Enable inference of dataclass import from marshmallow_dataclass.
  This allows the dataclasses brain to recognize dataclasses annotated by marshmallow_dataclass.

* Resolve symlinks in the import path
  Fixes inference error when the import path includes symlinks (e.g. Python
  installed on macOS via Homebrew).

Revision 1.52 / (download) - annotate - [select for diffs], Tue Jan 4 20:52:50 2022 UTC (23 months ago) by wiz
Branch: MAIN
Changes since 1.51: +2 -1 lines
Diff to previous 1.51 (colored)

*: bump PKGREVISION for users

They now have a tool dependency on py-setuptools instead of a DEPENDS

Revision 1.51 / (download) - annotate - [select for diffs], Wed Dec 8 16:21:21 2021 UTC (23 months, 4 weeks ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2021Q4-base, pkgsrc-2021Q4
Changes since 1.50: +2 -2 lines
Diff to previous 1.50 (colored)

py-astroid: updated to 2.9.0

Add end_lineno and end_col_offset attributes to astroid nodes.
Always treat __class_getitem__ as a classmethod.
Add missing as_string visitor method for Unknown node.

Revision 1.50 / (download) - annotate - [select for diffs], Sun Nov 14 15:22:57 2021 UTC (2 years ago) by adam
Branch: MAIN
Changes since 1.49: +2 -2 lines
Diff to previous 1.49 (colored)

py-astroid: updated to 2.8.5

What's New in astroid 2.8.5?
* Use more permissive versions for the ``typed-ast`` dependencie (<2.0 instead of <1.5)
* Fix crash on inference of ``__len__``.
* Added missing ``kind`` (for ``Const``) and ``conversion`` (for ``FormattedValue``) fields to repr.
* Fix crash with assignment expressions, nested if expressions and filtering of statements
* Fix incorrect filtering of assignment expressions statements

Revision 1.49 / (download) - annotate - [select for diffs], Tue Oct 26 12:20:38 2021 UTC (2 years, 1 month ago) by adam
Branch: MAIN
Changes since 1.48: +4 -4 lines
Diff to previous 1.48 (colored)

py-astroid: updated to 2.8.4

What's New in astroid 2.8.4?
* Fix the ``scope()`` and ``frame()`` methods of ``NamedExpr`` nodes.
  When these nodes occur in ``Arguments``, ``Keyword``  or ``Comprehension`` nodes these
  methods now correctly point to the outer-scope of the ``FunctionDef``,
  ``ClassDef``, or ``Comprehension``.
* Fix the ``set_local`` function for ``NamedExpr`` nodes.
  When these nodes occur in ``Arguments``, ``Keyword``, or ``Comprehension`` nodes these
  nodes are now correctly added to the locals of the ``FunctionDef``,
  ``ClassDef``, or ``Comprehension``.

What's New in astroid 2.8.3?
* Add support for wrapt 1.13
* Fixes handling of nested partial functions
* Fix regression with the import resolver
* Fix crash with invalid dataclass field call

What's New in astroid 2.8.2?
Same content than 2.8.2-dev0 / 2.8.1, released in order to fix a
mistake when creating the tag.

What's New in astroid 2.8.1?
* Adds support of type hints inside numpy's brains.
* Enable inference of dataclass import from pydantic.dataclasses.
  This allows the dataclasses brain to recognize pydantic dataclasses.
* Fix regression on ClassDef inference
* Fix regression on Compare node inference
* 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
* 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 ```` function.

What's New in astroid 2.8.0?
* 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
* Add ``node_ancestors`` method to ``NodeNG`` for obtaining the ancestors of nodes.
* It's now possible to infer the value of comparison nodes
* Fixed bug in inference of dataclass field calls.

Revision 1.48 / (download) - annotate - [select for diffs], Mon Sep 13 06:50:20 2021 UTC (2 years, 2 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2021Q3-base, pkgsrc-2021Q3
Changes since 1.47: +2 -2 lines
Diff to previous 1.47 (colored)

py-astroid: updated to 2.7.3

What's New in astroid 2.7.3?
* 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.
* Fixed bug in attribute inference from inside method calls.
* Fixed bug in inference for superclass instance methods called
  from the class rather than an instance.
* Fixed bug in inference of chained attributes where a subclass
  had an attribute that was an instance of its superclass.
* Adds a brain for the ctypes module.
* When processing dataclass attributes, exclude the same type hints from abc.collections
  as from typing.
* Apply dataclass inference to pydantic's dataclasses.

What's New in astroid 2.7.2?
* ``BaseContainer`` is now public, and will replace ``_BaseContainer`` completely in astroid 3.0.
* The call cache used by inference functions produced by ``inference_tip``
  can now be cleared via ``clear_inference_tip_cache``.
* ``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.

What's New in astroid 2.7.1?
* When processing dataclass attributes, only do typing inference on collection types.
  Support for instantiating other typing types is left for the future, if desired.
* Fixed LookupMixIn missing from ``astroid.node_classes``.

What's New in astroid 2.7.0?
* Import from ``astroid.node_classes`` and ``astroid.scoped_nodes`` has been deprecated in favor of
  ``astroid.nodes``. Only the imports from ``astroid.nodes`` will work in astroid 3.0.0.
* Add support for arbitrary Enum subclass hierachies
* Add inference tips for dataclass attributes, including dataclasses.field calls.
  Also add support for InitVar.
* Adds a brain that deals with dynamic import of `IsolatedAsyncioTestCase` class of the `unittest` module.

Revision 1.47 / (download) - annotate - [select for diffs], Wed Aug 4 09:07:38 2021 UTC (2 years, 4 months ago) by adam
Branch: MAIN
Changes since 1.46: +2 -2 lines
Diff to previous 1.46 (colored)

py-astroid: updated to 2.6.6

Added support to infer return type of typing.cast()
Fix variable lookup's handling of exclusive statements
Fix variable lookup's handling of function parameters
Fix variable lookup's handling of except clause variables
Fix handling of classes with duplicated bases with the same name

Revision 1.46 / (download) - annotate - [select for diffs], Thu Jul 22 08:40:56 2021 UTC (2 years, 4 months ago) by adam
Branch: MAIN
Changes since 1.45: +2 -2 lines
Diff to previous 1.45 (colored)

py-astroid: updated to 2.6.5

What's New in astroid 2.6.5?
* Fix a crash when there would be a 'TypeError object does not support
  item assignment' in the code we parse.
* Fix a crash when a AttributeInferenceError was raised when
 failing to find the real name in infer_import_from.

What's New in astroid 2.6.4?
* Fix a crash when a StopIteration was raised when inferring
  a faulty function in a context manager.

What's New in astroid 2.6.3?
* Added ``If.is_sys_guard`` and ``If.is_typing_guard`` helper methods
* Fix a bad inferenece type for yield values inside of a derived class.
* Fix a crash when the node is a 'Module' in the brain builtin inference
* Fix issues when inferring match variables
* Fix lookup for nested non-function scopes
* Fix issue that ``TypedDict`` instance wasn't callable.
* Add dependency on setuptools and a guard to prevent related exceptions.

Revision 1.45 / (download) - annotate - [select for diffs], Thu Jul 1 21:01:20 2021 UTC (2 years, 5 months ago) by adam
Branch: MAIN
Changes since 1.44: +2 -2 lines
Diff to previous 1.44 (colored)

py-astroid: updated to 2.6.2


Fix a crash when the inference of the length of a node failed

Fix unhandled StopIteration during inference, following the implementation
of PEP479 in python 3.7+

Revision 1.44 / (download) - annotate - [select for diffs], Wed Jun 30 05:59:28 2021 UTC (2 years, 5 months ago) by adam
Branch: MAIN
Changes since 1.43: +2 -3 lines
Diff to previous 1.43 (colored)

py-astroid: updated to 2.6.1

What's New in astroid 2.6.1?
Release date: 2021-06-29

* Fix issue with ``TypedDict`` for Python 3.9+

What's New in astroid 2.6.0?
Release date: 2021-06-22

* Appveyor and travis are no longer used in the continuous integration

* ``setuptools_scm`` has been removed and replaced by ``tbump`` in order to not
  have hidden runtime dependencies to setuptools

* ``NodeNg``, the base node class, is now accessible from ``astroid`` or
  ``astroid.nodes`` as it can be used for typing.

* Update enum brain to improve inference of .name and .value dynamic class

* Removed ``Repr``, ``Exec``, and ``Print`` nodes as the ``ast`` nodes
  they represented have been removed with the change to Python 3

* Deprecate ``Ellipsis`` node. It will be removed with the next minor release.
  Checkers that already support Python 3.8+ work without issues. It's only
  necessary to remove all references to the ``astroid.Ellipsis`` node.
  This changes will make development of checkers easier as the resulting tree for Ellipsis
  will no longer depend on the python version. **Background**: With Python 3.8 the
  ``ast.Ellipsis`` node, along with ``ast.Str``, ``ast.Bytes``, ``ast.Num``,
  and ``ast.NamedConstant`` were merged into ``ast.Constant``.

* Deprecated ``Index`` and ``ExtSlice`` nodes. They will be removed with the
  next minor release. Both are now part of the ``Subscript`` node.
  Checkers that already support Python 3.9+ work without issues.
  It's only necessary to remove all references to the ``astroid.Index`` and
  ``astroid.ExtSlice`` nodes. This change will make development of checkers
  easier as the resulting tree for ``ast.Subscript`` nodes will no longer
  depend on the python version. **Background**: With Python 3.9 ``ast.Index``
  and ``ast.ExtSlice`` were merged into the ``ast.Subscript`` node.

* Updated all Match nodes to be internally consistent.

* Add ``Pattern`` base class.

What's New in astroid 2.5.8?
Release date: 2021-06-07

* Improve support for Pattern Matching

* Add lineno and col_offset for ``Keyword`` nodes and Python 3.9+

* Add global inference cache to speed up inference of long statement blocks

* Add a limit to the total number of nodes inferred indirectly as a result
  of inferring some node

Revision 1.43 / (download) - annotate - [select for diffs], Tue Jun 1 05:14:56 2021 UTC (2 years, 6 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2021Q2-base, pkgsrc-2021Q2
Changes since 1.42: +4 -2 lines
Diff to previous 1.42 (colored)

py-astroid: updated to 2.5.7

What's New in astroid 2.5.7?

* Fix six.with_metaclass transformation so it doesn't break user defined transformations.
* Fix detection of relative imports.
* Fix inference of instance attributes defined in base classes
* Update `infer_named_tuple` brain to reject namedtuple definitions
  that would raise ValueError
* Do not set instance attributes on builtin object()
* Fix some spurious cycles detected in ``context.path`` leading to more cases
  that can now be inferred
* Add ``kind`` field to ``Const`` nodes, matching the structure of the built-in ast Const.
  The kind field is "u" if the literal is a u-prefixed string, and ``None`` otherwise.
* Fix property inference in class contexts for properties defined on the metaclass
* Update enum brain to fix definition of __members__ for subclass-defined Enums
* Update random brain to fix a crash with inference of some sequence elements
* Fix inference of attributes defined in a base class that is an inner class
* Allow inferring a return value of None for non-abstract empty functions and
  functions with no return statements (implicitly returning None)
* scm_setuptools has been added to the packaging.
* Astroid's tags are now the standard form ``vX.Y.Z`` and not ``astroid-X.Y.Z`` anymore.
* Add initial support for Pattern Matching in Python 3.10

Revision 1.42 / (download) - annotate - [select for diffs], Mon Apr 26 12:58:24 2021 UTC (2 years, 7 months ago) by adam
Branch: MAIN
Changes since 1.41: +3 -5 lines
Diff to previous 1.41 (colored)

py-astroid: updated to 2.5.6

What's New in astroid 2.5.6?
Release Date: 2021-04-25

* Fix retro-compatibility issues with old version of pylint

What's New in astroid 2.5.5?
Release Date: 2021-04-24

* Fixes the discord link in the project urls of the package.

What's New in astroid 2.5.4?
Release Date: 2021-04-24

* The packaging is now done via setuptools exclusively. ``doc``, ``tests``, and ``Changelog`` are
  not packaged anymore - reducing the size of the package greatly.

* Debian packaging is now  (officially) done in

* ``__pkginfo__`` now  only contain ``__version__`` (also accessible with ``astroid.__version__``),
  other meta-information are still accessible with ``import importlib;metadata.metadata('astroid')``.

* Added inference tip for ``typing.Tuple`` alias

* Fix crash when evaluating ``typing.NamedTuple``

* COPYING was removed in favor of COPYING.LESSER and the latter was renamed to LICENSE to make more apparent
  that the code is licensed under LGPLv2 or later.

* Moved from appveyor and travis to Github Actions for continuous integration.

Revision 1.41 / (download) - annotate - [select for diffs], Fri Apr 16 05:44:05 2021 UTC (2 years, 7 months ago) by adam
Branch: MAIN
Changes since 1.40: +2 -2 lines
Diff to previous 1.40 (colored)

py-astroid: updated to 2.5.3

What's New in astroid 2.5.3?
* Takes into account the fact that subscript inferring for a ClassDef may involve __class_getitem__ method
* Reworks the `collections` and `typing` brain so that `pylint`s acceptance tests are fine.
* Use ``inference_tip`` for ``typing.TypedDict`` brain.
* Fix mro for classes that inherit from typing.Generic
* Add inference tip for typing.Generic and typing.Annotated with ``__class_getitem__``

Revision 1.40 / (download) - annotate - [select for diffs], Wed Mar 31 06:36:50 2021 UTC (2 years, 8 months ago) by adam
Branch: MAIN
Changes since 1.39: +3 -3 lines
Diff to previous 1.39 (colored)

py-astroid: move PYTHON_VERSIONS_INCOMPATIBLE before

Revision 1.39 / (download) - annotate - [select for diffs], Tue Mar 30 09:20:16 2021 UTC (2 years, 8 months ago) by adam
Branch: MAIN
Changes since 1.38: +7 -3 lines
Diff to previous 1.38 (colored)

py-astroid: updated to 2.5.2

What's New in astroid 2.5.2?
* Detects `import numpy` as a valid `numpy` import.
* Iterate over ``Keywords`` when using ``ClassDef.get_children``

Revision 1.38 / (download) - annotate - [select for diffs], Mon Mar 1 08:49:11 2021 UTC (2 years, 9 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2021Q1-base, pkgsrc-2021Q1
Changes since 1.37: +2 -2 lines
Diff to previous 1.37 (colored)

py-astroid: updated to 2.5.1

What's New in astroid 2.5.1?
* The ``context.path`` is reverted to a set because otherwise it leads to false positives
  for non `numpy` functions.
* Don't transform dataclass ClassVars
* Improve typing.TypedDict inference
* Fix the `Duplicates found in MROs` false positive.

Revision 1.37 / (download) - annotate - [select for diffs], Mon Feb 22 09:22:05 2021 UTC (2 years, 9 months ago) by adam
Branch: MAIN
Changes since 1.36: +4 -5 lines
Diff to previous 1.36 (colored)

py-astroid: updated to 2.5

What's New in astroid 2.5?

* Adds `attr_fset` in the `PropertyModel` class.
* Remove support for Python 3.5.
* Remove the runtime dependency on ``six``. The ``six`` brain remains in
* Enrich the ``brain_collection`` module so that ``__class_getitem__`` method is added to `deque` for
  ``python`` version above 3.9.
* The ``context.path`` is now a ``dict`` and the ``context.push`` method
  returns ``True`` if the node has been visited a certain amount of times.
* Adds a brain for type object so that it is possible to write `type[int]` in annotation.
* Add ``__class_getitem__`` method to ``subprocess.Popen`` brain under Python 3.9 so that it is seen as subscriptable by pylint.
* Adds `degrees`, `radians`, which are `numpy ufunc` functions, in the `numpy` brain. Adds `random` function in the `numpy.random` brain.
* Fix deprecated importlib methods
* Fix a crash in inference caused by `Uninferable` container elements
* Add `python 3.9` support.
* The flat attribute of ``numpy.ndarray`` is now inferred as an ``numpy.ndarray`` itself.
  It should be a ``numpy.flatiter`` instance, but this class is not yet available in the numpy brain.
* Fix a bug for dunder methods inference of function objects
* Fixes a bug in the signature of the ``ndarray.__or__`` method,
  in the ```` module.
* Fixes a to-list cast bug in ``starred_assigned_stmts`` method,
  in the ``` module.
* Added a brain for ``hypothesis.strategies.composite``
* The transpose of a ``numpy.ndarray`` is also a ``numpy.ndarray``
* Added a brain for ``sqlalchemy.orm.session``
* Separate string and bytes classes patching
* Prevent recursion error for self referential length calls
* Added missing methods to the brain for ``mechanize``, to fix pylint false positives
* Added more supported parameters to ``subprocess.check_output``
* Fix recursion errors with pandas
* Added exception inference for `UnicodeDecodeError`
* `FunctionDef.is_generator` properly handles `yield` nodes in `If` tests
* Fixed exception-chaining error messages.
* Fix failure to infer base class type with multiple inheritance and qualified names
* Fix interpretation of ``six.with_metaclass`` class definitions.
* Reduce memory usage of astroid's module cache.
* Remove dependency on `imp`.
* Do not crash when encountering starred assignments in enums.
* Fix a crash in functools.partial inference when the arguments cannot be determined
* Fix a crash caused by a lookup of a monkey-patched method
* ``is_generator`` correctly considers `Yield` nodes in `AugAssign` nodes
  This fixes a false positive with the `assignment-from-no-return` pylint check.
* Corrected the parent of function type comment nodes.
  These nodes used to be parented to their original ast.FunctionDef parent
  but are now correctly parented to their astroid.FunctionDef parent.

Revision 1.36 / (download) - annotate - [select for diffs], Mon Jun 8 16:08:01 2020 UTC (3 years, 5 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2020Q4-base, pkgsrc-2020Q4, pkgsrc-2020Q3-base, pkgsrc-2020Q3, pkgsrc-2020Q2-base, pkgsrc-2020Q2
Changes since 1.35: +2 -2 lines
Diff to previous 1.35 (colored)

py-astroid: updated to 2.4.2

What's New in astroid 2.4.2?
* `FunctionDef.is_generator` properly handles `yield` nodes in `While` tests
* Properly construct the arguments of infered property descriptors

Revision 1.35 / (download) - annotate - [select for diffs], Tue May 5 18:18:55 2020 UTC (3 years, 7 months ago) by adam
Branch: MAIN
Changes since 1.34: +4 -4 lines
Diff to previous 1.34 (colored)

py-astroid: updated to 2.4.1

What's New in astroid 2.4.1?
* Handle the case where the raw builder fails to retrieve the ``__all__`` attribute
* Restructure the AST parsing heuristic to always pick the same module
* Changed to work with [distlib](
* Do not crash with SyntaxError when parsing namedtuples with invalid label
* Protect against ``infer_call_result`` failing with `InferenceError` in `Super.getattr()`

What's New in astroid 2.4.0?
* Expose a ast_from_string method in AstroidManager, which will accept
  source code as a string and return the corresponding astroid object
* ``BoundMethod.implicit_parameters`` returns a proper value for ``__new__``
* Allow slots added dynamically to a class to still be inferred
* Allow `FunctionDef.getattr` to look into both instance attrs and special attributes
* Infer qualified ``classmethod`` as a classmethod.
* Prevent a recursion error to happen when inferring the declared metaclass of a class
* Raise ``AttributeInferenceError`` when ``getattr()`` receives an empty name
* Prevent a recursion error for self reference variables and `type()` calls.
* Do not infer the first argument of a staticmethod in a metaclass as the class itself
* ``NodeNG.bool_value()`` gained an optional ``context`` parameter
  We need to pass an inference context downstream when inferring the boolean
  value of a node in order to prevent recursion errors and double inference.
  This fix prevents a recursion error with dask library.
* Pass a context argument to ``astroid.Arguments`` to prevent recursion errors
* Better inference of class and static methods decorated with custom methods
* Reverse the order of decorators for `infer_subscript`
  `path_wrapper` needs to come first, followed by `raise_if_nothing_inferred`,
  otherwise we won't handle `StopIteration` correctly.
* Prevent a recursion error when inferring self-referential variables without definition
* Numpy `datetime64.astype` return value is inferred as a `ndarray`.
* Skip non ``Assign`` and ``AnnAssign`` nodes from enum reinterpretation
* Numpy ``ndarray`` attributes ``imag`` and ``real`` are now inferred as ``ndarray``.
* Added a call to ``register_transform`` for all functions of the ``brain_numpy_core_multiarray``
  module in case the current node is an instance of ``astroid.Name``
* Use the parent of the node when inferring aug assign nodes instead of the statement
* Added some functions to the ``brain_numpy_core_umath`` module
* Added some functions of the ``numpy.core.multiarray`` module
* All the ``numpy ufunc`` functions derived now from a common class that
  implements the specific ``reduce``, ``accumulate``, ``reduceat``,
        ``outer`` and ``at`` methods.
* ``nodes.Const.itered`` returns a list of ``Const`` nodes, not strings
* The ``shape`` attribute of a ``numpy ndarray`` is now a ``ndarray``
* Don't ignore special methods when inspecting gi classes
* Added transform for ``scipy.gaussian``
* Add suport for inferring properties.
* Added a brain for ``responses``
* Allow inferring positional only arguments.
* Retry parsing a module that has invalid type comments
  It is possible for a module to use comments that might be interpreted
  as type comments by the `ast` library. We do not want to completely crash on those
  invalid type comments.
* Scope the inference to the current bound node when inferring instances of classes
  When inferring instances of classes from arguments, such as ``self``
  in a bound method, we could use as a hint the context's ``boundnode``,
  which indicates the instance from which the inference originated.
  As an example, a subclass that uses a parent's method which returns
  ``self``, will override the ``self`` to point to it instead of pointing
  to the parent class.
* Add support for inferring exception instances in all contexts
  We were able to infer exception instances as ``ExceptionInstance``
  only for a handful of cases, but not all. ``ExceptionInstance`` has
  support for better inference of `.args` and other exception related
  attributes that normal instances do not have.
  This additional support should remove certain false positives related
  to ``.args`` and other exception attributes in ``pylint``.
* Add more supported parameters to ``subprocess.check_output``
* Infer args unpacking of ``self``
  Certain stdlib modules use ``*args`` to encapsulate
  the ``self`` parameter, which results in uninferable
  instances given we rely on the presence of the ``self``
  argument to figure out the instance where we should be
  setting attributes.
* Clean up
  Make pytest-runner a requirement only if running tests, similar to what was
  done with McCabe.
  Clean up the file, resolving a handful of minor warnings with it.
* Handle StopIteration error in infer_int.
* Can access per argument type comments for positional only and keyword only arguments.
  The comments are accessed through through the new
  ``Arguments.type_comment_posonlyargs`` and
  ``Arguments.type_comment_kwonlyargs`` attributes respectively.
* Relax upper bound on `wrapt`
* Properly analyze CFFI compiled extensions.

Revision 1.34 / (download) - annotate - [select for diffs], Thu Nov 7 10:56:42 2019 UTC (4 years, 1 month ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2020Q1-base, pkgsrc-2020Q1, pkgsrc-2019Q4-base, pkgsrc-2019Q4
Changes since 1.33: +2 -3 lines
Diff to previous 1.33 (colored)

py-astroid: updated to 2.3.3

What's New in astroid 2.3.3?
* Relaxed `six` dependency.

Revision 1.33 / (download) - annotate - [select for diffs], Wed Nov 6 12:46:40 2019 UTC (4 years, 1 month ago) by adam
Branch: MAIN
Changes since 1.32: +2 -1 lines
Diff to previous 1.32 (colored)

py-astroid: allow newer version of lang/py-six

Revision 1.32 / (download) - annotate - [select for diffs], Sat Oct 19 06:31:25 2019 UTC (4 years, 1 month ago) by adam
Branch: MAIN
Changes since 1.31: +2 -2 lines
Diff to previous 1.31 (colored)

py-astroid: updated to 2.3.2

What's New in astroid 2.3.2?

* All type comments have as parent the corresponding `astroid` node

  Until now they had as parent the builtin `ast` node which meant
  we were operating with primitive objects instead of our own.

* Pass an inference context to `metaclass()` when inferring an object type

  This should prevent a bunch of recursion errors happening in pylint.
  Also refactor the inference of `IfExp` nodes to use separate contexts
  for each potential branch.

Revision 1.31 / (download) - annotate - [select for diffs], Tue Oct 15 08:00:22 2019 UTC (4 years, 1 month ago) by adam
Branch: MAIN
Changes since 1.30: +2 -2 lines
Diff to previous 1.30 (colored)

py-astroid: requires newer py-lazy-object-proxy

Revision 1.30 / (download) - annotate - [select for diffs], Tue Oct 1 11:34:55 2019 UTC (4 years, 2 months ago) by adam
Branch: MAIN
Changes since 1.29: +2 -2 lines
Diff to previous 1.29 (colored)

py-astroid: updated to 2.3.1

What's New in astroid 2.3.1?
* A transform for the builtin `dataclasses` module was added.
  This should address various `dataclasses` issues that were surfaced
  even more after the release of pylint 2.4.0.
  In the previous versions of `astroid`, annotated assign nodes were
  allowed to be retrieved via `getattr()` but that no longer happens
  with the latest `astroid` release, as those attribute are not actual
  attributes, but rather virtual ones, thus an operation such as `getattr()`
  does not make sense for them.
* Update attr brain to partly understand annotated attributes

What's New in astroid 2.3.0?
* Add a brain tip for ``subprocess.check_output``
* Remove NodeNG.nearest method because of lack of usage in astroid and pylint.
* Allow importing wheel files.
* Annotated AST follows PEP8 coding style when converted to string.
* Fix a bug where defining a class using type() could cause a DuplicateBasesError.
* Dropped support for Python 3.4.
* Numpy brain support is improved.
  Numpy's fundamental type ``numpy.ndarray`` has its own brain : ``brain_numpy_ndarray`` and
  each numpy module that necessitates brain action has now its own numpy brain :
    - ``numpy.core.numeric``
    - ``numpy.core.function_base``
    - ``numpy.core.multiarray``
    - ``numpy.core.numeric``
    - ``numpy.core.numerictypes``
    - ``numpy.core.umath``
    - ``numpy.random.mtrand``
* ``assert`` only functions are properly inferred as returning ``None``
* Add support for Python 3.8's `NamedExpr` nodes, which is part of assignment expressions.
* Added support for inferring `IfExp` nodes.
* Instances of exceptions are inferred as such when inferring in non-exception context
  This allows special inference support for exception attributes such as `.args`.
* Drop a superfluous and wrong callcontext when inferring the result of a context manager
* ``igetattr`` raises ``InferenceError`` on re-inference of the same object
  This prevents ``StopIteration`` from leaking when we encounter the same
  object in the current context, which could result in various ``RuntimeErrors``
  leaking in other parts of the inference.
  Until we get a global context per inference, the solution is sort of a hack,
  as with the suggested global context improvement, we could theoretically
  reuse the same inference object.
* Variable annotations can no longer be retrieved with `ClassDef.getattr`
  Unless they have an attached value, class variable annotations can no longer
  be retrieved with `ClassDef.getattr.`
* Improved builtin inference for ``tuple``, ``set``, ``frozenset``, ``list`` and ``dict``
  We were properly inferring these callables *only* if they had consts as
  values, but that is not the case most of the time. Instead we try to infer
  the values that their arguments can be and use them instead of assuming
  Const nodes all the time.
* The last except handler wins when inferring variables bound in an except handler.
* ``threading.Lock.locked()`` is properly recognized as a member of ``threading.Lock``
* Fix recursion error involving ``len`` and self referential attributes
* Can access per argument type comments through new ``Arguments.type_comment_args`` attribute.
* Fix being unable to access class attributes on a NamedTuple.
* Fixed being unable to find distutils submodules by name when in a virtualenv.

Revision 1.29 / (download) - annotate - [select for diffs], Thu May 2 09:16:47 2019 UTC (4 years, 7 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2019Q3-base, pkgsrc-2019Q3, pkgsrc-2019Q2-base, pkgsrc-2019Q2
Changes since 1.28: +1 -6 lines
Diff to previous 1.28 (colored)

Forget about Python 3.4

Revision 1.28 / (download) - annotate - [select for diffs], Wed Mar 13 19:19:27 2019 UTC (4 years, 8 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2019Q1-base, pkgsrc-2019Q1
Changes since 1.27: +2 -2 lines
Diff to previous 1.27 (colored)

py-astroid: updated to 2.2.5

What's New in astroid 2.2.5?
* The last except handler wins when inferring variables bound in an except handler.

Revision 1.27 / (download) - annotate - [select for diffs], Wed Mar 6 18:39:43 2019 UTC (4 years, 9 months ago) by adam
Branch: MAIN
Changes since 1.26: +2 -2 lines
Diff to previous 1.26 (colored)

py-astroid: updated to 2.2.4

What's New in astroid 2.2.4?
* Latest typed_ast gets installed for all CPython versions.

Revision 1.26 / (download) - annotate - [select for diffs], Mon Mar 4 18:47:56 2019 UTC (4 years, 9 months ago) by adam
Branch: MAIN
Changes since 1.25: +2 -2 lines
Diff to previous 1.25 (colored)

py-astroid: updated to 2.2.3

What's New in astroid 2.2.3?

* Replace any with uninferable when returning values from numpy transform

  Turns out that this was conflicting with the any builtin, while the original
  intention was to return a value that cannot be inferred, until we have support
  for types.

  This should fix a couple of false positives on pylint's side where the return
  value of numpy functions was considered to be itself a function.

Revision 1.25 / (download) - annotate - [select for diffs], Sat Mar 2 14:10:14 2019 UTC (4 years, 9 months ago) by adam
Branch: MAIN
Changes since 1.24: +2 -2 lines
Diff to previous 1.24 (colored)

py-astroid: updated to 2.2.2

What's New in astroid 2.2.2?
* Generated proper environment markers for installing typed-ast.

What's New in astroid 2.2.1?
* Make sure to infer the arguments to the slice() builtin
* Correctly instantiate exception instances when inferring their attributes with objectmodel

Revision 1.24 / (download) - annotate - [select for diffs], Thu Feb 28 09:17:41 2019 UTC (4 years, 9 months ago) by adam
Branch: MAIN
Changes since 1.23: +4 -6 lines
Diff to previous 1.23 (colored)

py-astroid: updated to 2.2.0

What's New in astroid 2.2.0?
* Fix a bug concerning inference of calls to numpy function that should not return Tuple or List instances.
* typed_ast gets installed for Python 3.7, meaning type comments can now work on 3.7.
* Fix a bug concerning inference of unary operators on numpy types.
* Fix a crash with typing.NamedTuple and empty fields.
* Add a proper strerror inference to the OSError exceptions.
* Support non-const nodes as values of Enum attributes.
* Fix a crash in the enum brain tip caused by non-assign members in class definitions.
* brain_numpy returns an undefined type for numpy methods to avoid assignment-from-no-return
* Fix a bug where a call to a function that has been previously called via
  functools.partial was wrongly inferred
* Fix a recursion error caused by inferring the slice builtin.
* Remove the restriction that "old style classes" cannot have a MRO.
  This does not make sense any longer given that we run against Python 3
* Added more builtin exceptions attributes.
* Add a registry for builtin exception models.
* Add brain tips for http.client.
* Prevent crashing when processing enums with mixed single and double quotes.
* typing types have the __args__ property.
* Fix a bug where an Attribute used as a base class was triggering a crash
* Added special support for enum.IntFlag
* Extend detection of data classes defined with attr
* Fix typo in description for brain_attrs

Revision 1.23 / (download) - annotate - [select for diffs], Thu Dec 27 16:03:09 2018 UTC (4 years, 11 months ago) by joerg
Branch: MAIN
CVS Tags: pkgsrc-2018Q4-base, pkgsrc-2018Q4
Changes since 1.22: +3 -3 lines
Diff to previous 1.22 (colored)

PYTHON_VERSIONS_INCOMPATIBLE must be set before is included.

Revision 1.22 / (download) - annotate - [select for diffs], Mon Nov 26 09:00:52 2018 UTC (5 years ago) by adam
Branch: MAIN
Changes since 1.21: +2 -2 lines
Diff to previous 1.21 (colored)

py-astroid: updated to 2.1.0

What's New in astroid 2.1.0?

* threading.Lock.acquire has the timeout parameter now.

* Pass parameters by keyword name when inferring sequences.

* Correct line numbering for f-strings for complex embedded expressions

  When a f-string contained a complex expression, such as an attribute access,
  we weren't cloning all the subtree of the f-string expression for attaching the correct
  line number. This problem is coming from the builtin AST parser which gives for the f-string
  and for its underlying elements the line number 1, but this is causing all sorts of bugs and
  problems in pylint, which expects correct line numbering.

* Add support for argparse.Namespace

* async functions are now inferred as AsyncGenerator when inferring their call result.

* Filter out Uninferable when inferring the call result result of a class with an uninferable __call__ method.

* Make compatible with AST changes in Python 3.8.

* Subscript inference (e.g. "a[i]") now pays attention to multiple inferred values for value
  (e.g. "a") and slice (e.g. "i")

Revision 1.21 / (download) - annotate - [select for diffs], Fri Aug 10 12:16:23 2018 UTC (5 years, 3 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2018Q3-base, pkgsrc-2018Q3
Changes since 1.20: +2 -2 lines
Diff to previous 1.20 (colored)

py-astroid: updated to 2.0.4

Make sure that assign nodes can find ``yield`` statements in their values

The environment markers for PyPy were invalid.

Revision 1.20 / (download) - annotate - [select for diffs], Thu Aug 2 15:13:34 2018 UTC (5 years, 4 months ago) by adam
Branch: MAIN
Changes since 1.19: +2 -2 lines
Diff to previous 1.19 (colored)

py-astroid: updated to 2.0.2

What's New in astroid 2.0.2?
   * Stop repeat inference attempt causing a RuntimeError in Python3.7

   *  infer_call_result can raise InferenceError so make sure to handle that for the call sites
      where it is used

     infer_call_result started recently to raise InferenceError for objects for which it
     could not find any returns. Previously it was silently raising a StopIteration,
     which was especially leaking when calling builtin methods.
     Since it is after all an inference method, it is expected that it
     could raise an InferenceError rather than returning nothing.

Revision 1.19 / (download) - annotate - [select for diffs], Tue Jul 24 06:13:53 2018 UTC (5 years, 4 months ago) by adam
Branch: MAIN
Changes since 1.18: +2 -2 lines
Diff to previous 1.18 (colored)

py-astroid: updated to 2.0.1

Released to clear an old wheel package on PyPI

Revision 1.18 / (download) - annotate - [select for diffs], Tue Jul 17 10:05:46 2018 UTC (5 years, 4 months ago) by adam
Branch: MAIN
Changes since 1.17: +11 -6 lines
Diff to previous 1.17 (colored)

py-astroid: updated to 2.0

astroid 2.0:
* String representation of nodes takes in account precedence and associativity rules of operators.
* Fix loading files with modutils.load_from_module when
  the path that contains it in sys.path is a symlink and
  the file is contained in a symlinked folder.
* Reworking of the numpy brain dealing with numerictypes
  (use of inspect module to determine the class hierarchy of
   numpy.core.numerictypes module)
* Added inference support for starred nodes in for loops
* Support unpacking for dicts in assignments
* Add support for inferring functools.partial
* Inference support for dict.fromkeys
* int() builtin is inferred as returning integers.
* str() builtin is inferred as returning strings.
* DescriptorBoundMethod has the correct number of arguments defined.
* Improvement of the numpy numeric types definition.
* Subclasses of *property* are now interpreted as properties
* AsStringRegexpPredicate has been removed.
  Use transform predicates instead of it.
* Switched to using typed_ast for getting access to type comments
  As a side effect of this change, some nodes gained a new type_annotation attribute,
  which, if the type comments were correctly parsed, should contain a node object
  with the corresponding objects from the type comment.
* typing.X[...] and typing.NewType are inferred as classes instead of instances.
* Module.__path__ is now a list
  It used to be a string containing the path, but it doesn't reflect the situation
  on Python, where it is actually a list.
* Fix a bug with namespace package's __path__ attribute.
* Added brain tips for random.sample
* Add brain tip for issubclass builtin
* Fix submodule imports from six
* Fix missing __module__ and __qualname__ from class definition locals
* Fix a crash when __annotations__ access a parent's __init__ that does not have arguments
* Fix multiple objects sharing the same InferenceContext.path causing uninferable results
* Fix improper modification of col_offset, lineno upon inference of builtin functions
* Subprocess.Popen brain now knows of the args member
* add move_to_end method to collections.OrderedDict brain
* Include new hashlib classes added in python 3.6
* Fix RecursionError for augmented assign
* Add missing attrs special attribute
* Inference now understands the 'isinstance' builtin
* Stop duplicate nodes with the same key values
  from appearing in dictionaries from dictionary unpacking.
* Fix contextlib.contextmanager inference for nested context managers
* Implement inference for len builtin
* Add qname method to Super object preventing potential errors in upstream
* Stop astroid from getting stuck in an infinite loop if a function shares
its name with its decorator
* Fix issue with inherited __call__ improperly inferencing self
* Fix __call__ precedence for classes with custom metaclasses
* Limit the maximum amount of interable result in an NodeNG.infer() call to
 100 by default for performance issues with variables with large amounts of
 possible values.
 The max inferable value can be tuned by setting the max_inferable_values flag on

Revision 1.17 / (download) - annotate - [select for diffs], Thu Jun 7 06:33:54 2018 UTC (5 years, 6 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2018Q2-base, pkgsrc-2018Q2
Changes since 1.16: +3 -3 lines
Diff to previous 1.16 (colored)

py-astroid: updated to 1.6.5

*  Don't propagate Uninferable objects when inferring BinOps
*  Protect against passing lookup_class to non-class proxied objects
   In some cases the _proxied object points to another Instance, not to the
   Class of an Instance node (usually this happens with enum and with our
   hardcoded inference support for this library). Instead of getting a TypeError,
   we check before if the _proxied matches what we expect.

Revision 1.16 / (download) - annotate - [select for diffs], Wed May 16 06:54:20 2018 UTC (5 years, 6 months ago) by adam
Branch: MAIN
Changes since 1.15: +2 -2 lines
Diff to previous 1.15 (colored)

py-astroid: updated to 1.6.4

* Skip non-attrs specific attributes in attr wrapped classes.
* Add brain tip for numpy.sum.
* deque.rotate has a default parameter.

Revision 1.15 / (download) - annotate - [select for diffs], Fri Apr 6 11:51:27 2018 UTC (5 years, 8 months ago) by adam
Branch: MAIN
Changes since 1.14: +2 -2 lines
Diff to previous 1.14 (colored)

py-astroid: updated to 1.6.3

Bug fixes.

Revision 1.14 / (download) - annotate - [select for diffs], Sat Mar 17 06:52:50 2018 UTC (5 years, 8 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2018Q1-base, pkgsrc-2018Q1
Changes since 1.13: +2 -2 lines
Diff to previous 1.13 (colored)

py-astroid: updated to 1.6.2

* Fix submodule imports from six
* Enhancement of brain_numpy by adding different types from
* Fix RecursionError for augmented assign
* Stop most inference tip overwrites from happening by using
  predicates on existing inference_tip transforms.
* Add missing attrs special attribute
* Fix contextlib.contextmanager inference for nested context managers

Revision 1.13 / (download) - annotate - [select for diffs], Wed Jan 31 11:50:08 2018 UTC (5 years, 10 months ago) by adam
Branch: MAIN
Changes since 1.12: +2 -2 lines
Diff to previous 1.12 (colored)

py-astroid: updated to 1.6.1

* Fix a crash when __annotations__ access a parent's __init__ that does not have arguments

Revision 1.12 / (download) - annotate - [select for diffs], Thu Dec 21 09:57:44 2017 UTC (5 years, 11 months ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2017Q4-base, pkgsrc-2017Q4
Changes since 1.11: +2 -6 lines
Diff to previous 1.11 (colored)

astroid: updated to 1.6.0

* 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
* 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
 * The func form of namedtuples with keywords is now understood
 * Dunder class at method level is now inferred as the class of the method

Revision 1.11 / (download) - annotate - [select for diffs], Sun Sep 3 08:53:07 2017 UTC (6 years, 3 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2017Q3-base, pkgsrc-2017Q3
Changes since 1.10: +2 -2 lines
Diff to previous 1.10 (colored)

Follow some redirects.

Revision 1.10 / (download) - annotate - [select for diffs], Sun Jul 16 20:14:15 2017 UTC (6 years, 4 months ago) by adam
Branch: MAIN
Changes since 1.9: +12 -4 lines
Diff to previous 1.9 (colored)


* enum34 dependency is forced to be at least version 1.1.3. Fixes spurious
bug related to enum classes being falsy in boolean context, which caused
_Inconsistent Hierarchy_ `RuntimeError` in `singledispatch` module.

* Do not raise an exception when uninferable value is unpacked in ``with`` statement.

* Lock objects from ``threading`` module are now correctly recognised
  as context managers.

Revision 1.9 / (download) - annotate - [select for diffs], Tue Feb 28 17:15:24 2017 UTC (6 years, 9 months ago) by fhajny
Branch: MAIN
CVS Tags: pkgsrc-2017Q2-base, pkgsrc-2017Q2, pkgsrc-2017Q1-base, pkgsrc-2017Q1
Changes since 1.8: +7 -5 lines
Diff to previous 1.8 (colored)

Update devel/py-astroid to 1.4.9.

2016-12-18 -- 1.4.9
- Cast __path__ to a list in _module_file
- Add support for pytest 3.0.

2016-07-27 -- 1.4.8
- Add `returns` into the proper order in FunctionDef._astroid_fields

2016-07-07 -- 1.4.7
- Stop saving assignment locals in ExceptHandlers, when the context is a

2016-06-06 -- 1.4.6
- Fix a crash which occurred when the class of a namedtuple could not be
- Functional form of enums support accessing values through __call__.
- Brain tips for the ssl library.

2016-03-21 -- 1.4.5
- decoratornames() does not leak InferenceError anymore.
- wildcard_imported_names() got replaced by _public_names()

2016-01-15 -- 1.4.4
- unpack_infer raises InferenceError if it can't operate
  with the given sequences of nodes.
- Support accessing properties with super().
- Enforce strong updates per frames.

2015-12-24 -- 1.4.3
- pkg_resources brain tips are a bit more specific,
  by specifiying proper returns.
- Standard library modules are properly detected by is_standard_module.

2015-12-21 -- 1.4.2
- The slots() method conflates all the slots from the ancestors
  into a list of current and parent slots.
- Revert to using printf-style formatting in as_string, in order
  to avoid a potential problem with encodings when using .format.
- assigned_stmts methods have the same signature from now on.

2015-11-29 -- 1.4.1
- Add support for handling Uninferable nodes when calling as_string

2015-11-29 -- 1.4.0
- Class.getattr('__mro__') returns the actual MRO.
- The logilab-common dependency is not needed anymore as the needed code
  was integrated into astroid.
- Add 'assert_equals' method in's brain plugin.
- Generated enum member stubs now support IntEnum and multiple
  base classes.
- Add brain tips for multiprocessing.Manager and
- Add brain tips for multiprocessing post Python 3.4+,
  where the module level functions are retrieved with getattr
  from a context object, leading to many no-member errors
  in Pylint.
- The Generator objects inferred with `infer_call_result`
  from functions have as parent the function from which they
  are returned.
- Understand partially the 3-argument form of `type`.
  The only change is that astroid understands members
  passed in as dictionaries as the third argument.
- Improve the inference of Getattr nodes when dealing with
  abstract properties from the abc module.
- UnboundMethod.getattr calls the getattr of its _proxied object
  and doesn't call super(...) anymore.
- Don't hard fail when calling .mro() on a class which has
  combined both newstyle and old style classes. The class
  in question is actually newstyle (and the __mro__ can be
  retrieved using Python).
- Class.local_attr and Class.local_attr_ancestors uses internally
  a mro lookup, using .mro() method, if they can.
- Expose a implicit_metaclass() method in Class. This will return
  a builtins.type instance for newstyle classes.
- Add two new exceptions for handling MRO error cases.
  is emitted when duplicate bases are found in a class,
- Classes aren't marked as interfaces anymore, in the `type` attribute.
- Class.has_dynamic_getattr doesn't return True for special methods
  which aren't implemented in pure Python, as it is the case for
  extension modules.
- Add `igetattr` method to scoped_nodes.Function.
- Add support for Python 3.5's MatMul operation: see PEP 465 for more
- NotImplemented is detected properly now as being part of the
  builtins module. Previously trying to infer the Name(NotImplemented)
  returned an YES object.
- Add proper grammatical names for `infered` and `ass_type` methods,
  namely `inferred` and `assign_type`.
- Add new AST names in order to be similar to the ones
  from the builtin ast module.
- Star unpacking in assignments returns properly a list,
  not the individual components.
- Lambdas found at class level, which have a `self` argument, are
- Add annotation support for function.as_string().
- Add support for indexing bytes on Python 3.
- Add support for inferring subscript on instances, which will
  use __getitem__.
- Understand metaclasses added with six.add_metaclass decorator.
- Add a new convenience API, `astroid.parse`, which can be used to
  retrieve an astroid AST from a source code string, similar to how
  ast.parse can be used to obtain a Python AST from a source string.
- do_import_module passes the proper relative_only flag if the level is
  higher than 1.
- There's a new separate step for transforms.
- Add a new node, DictUnpack, which is used to represent the unpacking
  of a dictionary into another dictionary, using PEP 448 specific syntax
  ({1:2, **{2:3})
- Add a new type of node, called *inference objects*.
- Add a new *inference object* called Super, which also adds support for
  understanding super calls.
- astroid.utils.ASTWalker and astroid.utils.LocalsVisitor
  were moved to pylint.pyreverse.utils.

2015-08-02 -- 1.3.8
- Backport of 40e3176, which fixes issue #84.

2015-07-27 -- 1.3.7
- Improve the inference of six.moves, especially when using `from ...
  import ...` syntax. Also, we added a new fail import hook for six.moves,
  which fixes the import-error false positive from pylint.

Revision 1.8 / (download) - annotate - [select for diffs], Mon Aug 29 15:44:25 2016 UTC (7 years, 3 months ago) by darcy
Branch: MAIN
CVS Tags: pkgsrc-2016Q4-base, pkgsrc-2016Q4, pkgsrc-2016Q3-base, pkgsrc-2016Q3
Changes since 1.7: +1 -3 lines
Diff to previous 1.7 (colored)

Update devel/py-logilab-common to version 1.2.0.
This is mainly to remove dependency on time/py-mxDateTime so that it can
build on Python >= 3.4.
Removed PYTHON_VERSIONS_INCOMPATIBLE line from this and other packages
that had it for this incompatibility.

Revision 1.7 / (download) - annotate - [select for diffs], Sat Jul 9 13:03:39 2016 UTC (7 years, 4 months ago) by wiz
Branch: MAIN
Changes since 1.6: +2 -2 lines
Diff to previous 1.6 (colored)

Remove python33: adapt all packages that refer to it.

Revision 1.6 / (download) - annotate - [select for diffs], Wed Jun 8 17:43:28 2016 UTC (7 years, 6 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2016Q2-base, pkgsrc-2016Q2
Changes since 1.5: +2 -2 lines
Diff to previous 1.5 (colored)


Revision 1.5 / (download) - annotate - [select for diffs], Sat Dec 5 21:25:36 2015 UTC (8 years ago) by adam
Branch: MAIN
CVS Tags: pkgsrc-2016Q1-base, pkgsrc-2016Q1, pkgsrc-2015Q4-base, pkgsrc-2015Q4
Changes since 1.4: +2 -2 lines
Diff to previous 1.4 (colored)


Revision 1.4 / (download) - annotate - [select for diffs], Sun Apr 5 15:36:27 2015 UTC (8 years, 8 months ago) by wen
Branch: MAIN
CVS Tags: pkgsrc-2015Q3-base, pkgsrc-2015Q3, pkgsrc-2015Q2-base, pkgsrc-2015Q2
Changes since 1.3: +5 -2 lines
Diff to previous 1.3 (colored)

Update to 1.3.6
Add test target

Upstream changes:
2015-03-14 -- 1.3.6

    * Class.slots raises NotImplementedError for old style classes.
      Closes issue #67.

    * Add a new option to AstroidManager, `optimize_ast`, which
      controls if peephole optimizer should be enabled or not.
      This prevents a regression, where the visit_binop method
      wasn't called anymore with astroid 1.3.5, due to the differences
      in the resulting AST. Closes issue #82.

2015-03-11 -- 1.3.5

    * Add the ability to optimize small ast subtrees,
      with the first use in the optimization of multiple
      BinOp nodes. This removes recursivity in the rebuilder
      when dealing with a lot of small strings joined by the
      addition operator. Closes issue #59.

    * Obtain the methods for the nose brain tip through an
      unittest.TestCase instance. Closes Pylint issue #457.

    * Fix a crash which occurred when a class was the ancestor
      of itself. Closes issue #78.

    * Improve the scope_lookup method for Classes regarding qualified
      objects, with an attribute name exactly as one provided in the
      class itself.

      For example, a class containing an attribute 'first',
      which was also an import and which had, as a base, a qualified name
      or a Gettattr node, in the form 'module.first', then Pylint would
      have inferred the `first` name as the function from the Class,
      not the import. Closes Pylint issue #466.

    * Implement the assigned_stmts operation for Starred nodes,
      which was omitted when support for Python 3 was added in astroid.
      Closes issue #36.

2015-01-17 -- 1.3.4

    * Get the first element from the method list when obtaining
      the functions from Closes Pylint issue #448.

2015-01-16 -- 1.3.3

    * Restore file_stream to a property, but deprecate it in favour of
      the newly added method By using a method instead of a
      property, it will be easier to properly close the file right
      after it is used, which will ensure that no file descriptors are
      leaked. Until now, due to the fact that a module was cached,
      it was not possible to close the file_stream anywhere.
      file_stream will start emitting PendingDeprecationWarnings in
      astroid 1.4, DeprecationWarnings in astroid 1.5 and it will
      be finally removed in astroid 1.6.

    * Add inference tips for 'tuple', 'list', 'dict' and 'set' builtins.

    * Add brain definition for most string and unicode methods

    * Changed the API for Class.slots. It returns None when the class
      doesn't define any slots. Previously, for both the cases where
      the class didn't have slots defined and when it had an empty list
      of slots, Class.slots returned an empty list.

    * Add a new method to Class nodes, 'mro', for obtaining the
      the method resolution order of the class.

    * Add brain tips for six.moves. Closes issue #63.

    * Improve the detection for functions decorated with decorators
      which returns static or class methods.

    * .slots() can contain unicode strings on Python 2.

    * Add inference tips for

2014-11-22 -- 1.3.2

    * Fixed a crash with invalid subscript index.

    * Implement proper base class semantics for Python 3, where
      every class derives from object.

    * Allow more fine-grained control over C extension loading
      in the manager.

2014-11-21 -- 1.3.1

    * Fixed a crash issue with the pytest brain module.

2014-11-20 -- 1.3.0

    * Fix a maximum recursion error occured during the inference,
      where statements with the same name weren't filtered properly.
      Closes pylint issue #295.

    * Check that EmptyNode has an underlying object in

    * Simplify the understanding of enum members.

    * Fix an infinite loop with decorator call chain inference,
      where the decorator returns itself. Closes issue #50.

    * Various speed improvements. Patch by Alex Munroe.

    * Add pytest brain plugin. Patch by Robbie Coomber.

    * Support for Python versions < 2.7 has been dropped, and the
      source has been made compatible with Python 2 and 3. Running
      2to3 on installation for Python 3 is not needed anymore.

    * astroid now depends on six.

    * modutils._module_file opens in binary mode.
      Closes issues #51 and #13.

    * Only C extensions from trusted sources (the standard library)
      are loaded into the examining Python process to build an AST
      from the live module.

    * Path names on case-insensitive filesystems are now properly
      handled. This fixes the stdlib detection code on Windows.

    * Metaclass-generating functions like six.with_metaclass
      are now supported via some explicit detection code.

    * astroid.register_module_extender has been added to generalize
      the support for module extenders as used by many brain plugins.

    * brain plugins can now register hooks to handle failed imports,
      as done by the gobject-introspection plugin.

    * The modules have been moved to a separate package directory,
      ` develop` now works correctly.

2014-08-24 -- 1.2.1

    * Fix a crash occurred when inferring decorator call chain.
      Closes issue #42.

    * Set the parent of vararg and kwarg nodes when inferring them.
      Closes issue #43.

    * namedtuple inference knows about '_fields' attribute.

    * enum members knows about the methods from the enum class.

    * Name inference will lookup in the parent function
      of the current scope, in case searching in the current scope

    * Inference of the functional form of the enums takes into
      consideration the various inputs that enums accepts.

    * The inference engine handles binary operations (add, mul etc.)
      between instances.

    * Fix an infinite loop in the inference, by returning a copy
      of instance attributes, when calling 'instance_attr'.
      Closes issue #34 (patch by Emile Anclin).

    * Don't crash when trying to infer unbound object.__new__ call.
      Closes issue #11.

2014-07-25  --  1.2.0

    * Function nodes can detect decorator call chain and see if they are
      decorated with builtin descriptors (`classmethod` and `staticmethod`).

    * infer_call_result called on a subtype of the builtin type will now
      return a new `Class` rather than an `Instance`.

    * `Class.metaclass()` now handles module-level __metaclass__ declaration
      on python 2, and no longer looks at the __metaclass__ class attribute on
      python 3.

    * Function nodes can detect if they are decorated with subclasses
      of builtin descriptors when determining their type
      (`classmethod` and `staticmethod`).

    * Add `slots` method to `Class` nodes, for retrieving
      the list of valid slots it defines.

    * Expose function annotation to astroid: `Arguments` node
      exposes 'varargannotation', 'kwargannotation' and 'annotations'
      attributes, while `Function` node has the 'returns' attribute.

    * Backported most of the logilab.common.modutils module there, as
      most things there are for pylint/astroid only and we want to be
      able to fix them without requiring a new logilab.common release

    * Fix names grabed using wildcard import in "absolute import mode"
      (ie with absolute_import activated from the __future__ or with
      python 3). Fix pylint issue #58.

    * Add support in pylint-brain for understanding enum classes.

2014-04-30  --  1.1.1
    * `Class.metaclass()` looks in ancestors when the current class
      does not define explicitly a metaclass.

    * Do not cache modules if a module with the same qname is already
      known, and only return cached modules if both name and filepath
      match. Fixes pylint Bitbucket issue #136.

2014-04-18  --  1.1.0
    * All class nodes are marked as new style classes for Py3k.

    * Add a `metaclass` function to `Class` nodes to
      retrieve their metaclass.

    * Add a new YieldFrom node.

    * Add support for inferring arguments to namedtuple invocations.

    * Make sure that objects returned for namedtuple
      inference have parents.

    * Don't crash when inferring nodes from `with` clauses
      with multiple context managers. Closes #18.

    * Don't crash when a class has some __call__ method that is not
      inferable. Closes #17.

    * Unwrap instances found in `.ancestors()`, by using their _proxied

Revision 1.3 / (download) - annotate - [select for diffs], Sat Dec 6 11:00:52 2014 UTC (9 years ago) by obache
Branch: MAIN
CVS Tags: pkgsrc-2015Q1-base, pkgsrc-2015Q1, pkgsrc-2014Q4-base, pkgsrc-2014Q4
Changes since 1.2: +3 -2 lines
Diff to previous 1.2 (colored)

No need to buildlink with devel/py-logilab-common, just DEPENDS.

Revision 1.2 / (download) - annotate - [select for diffs], Fri May 9 07:37:00 2014 UTC (9 years, 7 months ago) by wiz
Branch: MAIN
CVS Tags: pkgsrc-2014Q3-base, pkgsrc-2014Q3, pkgsrc-2014Q2-base, pkgsrc-2014Q2
Changes since 1.1: +2 -2 lines
Diff to previous 1.1 (colored)

Mark packages that are not ready for python-3.3 also not ready for 3.4,
until proven otherwise.

Revision 1.1 / (download) - annotate - [select for diffs], Wed Mar 12 01:06:05 2014 UTC (9 years, 8 months ago) by rodent
Branch: MAIN
CVS Tags: pkgsrc-2014Q1-base, pkgsrc-2014Q1

Import py27-astroid-1.0.1 as devel/py-astroid.

The aim of this module is to provide a common base representation of
python source code for projects such as pychecker, pyreverse,
pylint... Well, actually the development of this library is essentially
governed by pylint's needs. It used to be called logilab-astng

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.

CVSweb <>