BSD Ports

devel/py-eval-type-backport 0.3.1_1 MidnightBSD

Like typing._eval_type, but lets older Python versions use newer typing features

System
MidnightBSD
Repository
mports
Maintainer
[email protected]
License
mit
Categories
devel, python

Description

eval_type_backport is a tiny package providing a replacement for typing._eval_type to support newer typing features in older Python versions.

Yes, that's very specific, and yes, typing._eval_type is a protected function that you shouldn't normally be using. Really this package is specifically made for pydantic/pydantic#7873.

Specifically, this transforms X | Y into typing.Union[X, Y] and list[X] into typing.List[X] etc. (for all the types made generic in PEP 585) if the original syntax is not supported in the current Python version.

In the other systems

The newest version among them is 0.4.0, as upstream numbers it.

SystemPortVersionVulnerabilitiesStatusMaintainerLast update
MidnightBSDdevel/py-eval-type-backport0.3.1_1 behind since 2026-07-08no data-[email protected]-
FreeBSDdevel/py-eval-type-backport0.4.0 newestnone known-[email protected]2026-07-08
HardenedBSDdevel/py-eval-type-backport0.4.0 newestno data-[email protected]-
GhostBSDdevel/py-eval-type-backport0.4.0 newestno data-[email protected]-

Install

Binary package:

mport install ${PYTHON_PKGNAMEPREFIX}eval-type-backport

From mports:

cd /usr/mports/devel/py-eval-type-backport && make install clean

To depend on this port in another port's Makefile:

RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}eval-type-backport>0:devel/py-eval-type-backport

Dependency graph

Ports that need it on the left, what it needs to run on the right (to build, as it needs nothing to run); at most 8 of each. "Dependencies" below lists them all.

Dependencies

As this port's Makefile names them.

Build 3

Build dependencies 3

Configuration

No options to configure.

USES
python
Service scripts
none

Files

distinfo 1
FileSizeSHA256
eval_type_backport-0.3.1.tar.gz944557e993f7b5b69d271e37482e62f74e76a0276c82490cf8e4f0dffeb6b332d5ed
Master sites 1
  • PYPI