Pytype

Latest version: v2024.4.11

Safety actively analyzes 631249 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 18 of 34

2021.05.11

Bug fixes:
* Report [not-supported-yet] instead of [import-error] for importing TypedDict.
* Fix a bug in attribute lookup from parent classes.
* Fix a Python 3.7 failure in typeshed/tests/pytype_test.py.
* pytd: populated mutated_type from annotated `self` parameters.
* Preserve kw_only attribute when inheriting attrs from a different module.
* Add a vm state to allow recursive construction of pytd values.

2021.05.06

New features and updates:
* Update typeshed pin to commit 2c8cb60 from Apr 27.

Bug fixes:
* Add typing._Alias.
* Pin attrs to 20.3.0.

2021.05.04

New features and updates:
* Remove --check-attribute-types, --check-container-types, and
--check-variable-types flags. Their behaviors are now enabled by default.
* Add a temporary --preserve-union-macros flag that preserves Union generic type
aliases in type stubs. This behavior will ultimately be enabled by default and
the flag removed.
* Support max versions in typeshed VERSIONS file.

Bug fixes:
* Add typing.GenericMeta stub.
* Fix handling of typeshed/stdlib/python2.

2021.04.26

New features and updates:
* Enable --check-attribute-types, --check-container-types, and
--check-variable-types by default. These flags will soon be removed.
* Add a fix suggestion for [annotation-type-mismatch] with a None value.
* Add a temporary --attribute-variable-annotations flag that applies PEP
526-style annotations on attribute assignments. This behavior will ultimately
be enabled by default and the flag removed.
* Add a temporary --create-pyi-dataclasses flag that creates dataclasses from
dataclass-annotated classes in type stubs. This behavior will ultimately be
enabled by default and the flag removed.

Bug fixes:
* Don't lose track of attributes when typing.final is used.
* Fix generation of type information for nested typing.NamedTuple classes.
* Fix some bugs in handling of generic type aliases.
* Fix a pytype crash on a generic protocol.
* For method aliasing in pyi files, consider base classes when doing lookup.

2021.04.15

New features and updates:
* Update typeshed pin to commit ce24720 from Jan 27, and drop support for the
old typeshed directory structure.
* Delete the --check-nonnull-parameter-types flag.

Bug fixes:
* Add "from typing import overload" statement when using overload.
* Add object.__delattr__ to our builtins stubs.
* Add some more support for generic type aliases.

2021.04.09

New features and updates:
* Enable --check-parameter-types by default for non-None default values.
* Add some minimal support for PEP 612 in type stubs.
* Add support for typing.Annotated in pyi files.

Bug fixes:
* Fix a crash when analysed code accessed an undefined closure cell.
* Fix a minor bug in pytype's expansion of Protocol[T].
* Check starargs and starstarargs when gathering TypeVars in function sigs.
* Fix some bugs in pytype's handling of the new typeshed directory structure.
* Make sure `collections.defaultdict.__init__` always accepts kwargs.
* Filter out properties from class attributes when constructing dataclasses.
* Add gi_* fields to Generators.

Page 18 of 34

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.