Description
# typing-inspection [](https://github.com/pydantic/typing-inspection/actions?query=event%3Apush+branch%3Amain+workflow%3ACI) [](https://coverage-badge.samuelcolvin.workers.dev/redirect/pydantic/typing-inspection) [](https://pypi.org/project/typing-inspection/) [](https://github.com/pydantic/typing-inspection) [](https://github.com/pydantic/typing-inspection/blob/main/LICENSE) [](https://github.com/astral-sh/ruff) `typing-inspection` provides tools to inspect type annotations at runtime. ## Installation From [PyPI](https://pypi.org/project/typing-inspection/): ```bash pip install typing-inspection ``` The library can be imported from the `typing_inspection` module.
Release History
| Version | Changes | Urgency | Date |
|---|---|---|---|
| 0.4.2 | Imported from PyPI (0.4.2) | Low | 4/21/2026 |
| v0.4.2 | ## What's Changed * Add `typing_objects.is_noextraitems()` by @Viicos in https://github.com/pydantic/typing-inspection/pull/47 **Full Changelog**: https://github.com/pydantic/typing-inspection/compare/v0.4.1...v0.4.2 | Low | 10/1/2025 |
| v0.4.1 | ## What's Changed * Fix compatibility with latest Python 3.14 release by @Viicos in https://github.com/pydantic/typing-inspection/pull/37 * Add `typing_objects.is_forwardref()` by @Viicos in https://github.com/pydantic/typing-inspection/pull/38 * Fix implementation of `is_union_origin()` by @Viicos in https://github.com/pydantic/typing-inspection/pull/40 * Add SPDX license identifier by @cdce8p in https://github.com/pydantic/typing-inspection/pull/42 * Use `list` as a type hint for `Inspe | Low | 6/12/2025 |
| v0.4.0 | ## What's Changed - Add support for `dataclasses.InitVar` as a type qualifier by @Viicos in [#31](https://github.com/pydantic/typing-inspection/pull/31) A new `DATACLASS` annotation source is added. - Add explicit annotation for `ForbiddenQualifier` exception by @Viicos in [#30](https://github.com/pydantic/typing-inspection/pull/30) **Full Changelog**: https://github.com/pydantic/typing-inspection/compare/v0.3.1...v0.4.0 | Low | 2/25/2025 |
| v0.3.1 | ## What's Changed * Allow unhashable items in `Literal` forms by @Viicos in https://github.com/pydantic/typing-inspection/pull/28 **Full Changelog**: https://github.com/pydantic/typing-inspection/compare/v0.3.0...v0.3.1 | Low | 2/24/2025 |
| v0.3.0 | ## What's Changed - Handle bare `ClassVar` type qualifiers, rename `INFERRED` sentinel by @Viicos in [#26](https://github.com/pydantic/typing-inspection/pull/26) While currently not explicitly allowed by the typing specification, `ClassVar` is allowed as a bare type qualifier. Unlike `Final`, the actual type doesn't have to be inferred from the assignment (e.g. one can use `Any`). For this reason, the `INFERRED` sentinel was renamed to `UNKNOWN`. **Full Changelog**: https://github | Low | 2/24/2025 |
| v0.2.0 | ## What's Changed - Add `typing_objects.is_deprecated()` by @Viicos in [#24](https://github.com/pydantic/typing-inspection/pull/24) - Add missing positional only parameter markers in `typing_objects` stub file by @Viicos in [#23](https://github.com/pydantic/typing-inspection/pull/23) - Add project URLs by @Viicos in [#22](https://github.com/pydantic/typing-inspection/pull/22) **Full Changelog**: https://github.com/pydantic/typing-inspection/compare/v0.1.0...v0.2.0 | Low | 2/23/2025 |
| v0.1.0 | Initial release. | Low | 2/23/2025 |
