Skip to main content

poetry-version (deprecated)

What to use instead

Now there is a better way to extract the version of the package.

Assuming your package is named mypackage:

import importlib.metadata

__version__ = importlib.metadata.version("mypackage")

This code should work as is if you are using Python >= 3.8.

For Python 3.6 and 3.7 you need to install a backport: https://pypi.org/project/importlib-metadata/

Release files for poetry-version 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for poetry-version 0.2.0
File Size Uploaded
poetry-version-0.2.0.tar.gz 5.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for poetry-version 0.2.0
File Interpreter ABI Platform
poetry_version-0.2.0-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 11.9 kB

Release files / poetry-version-0.2.0.tar.gz

Download URL poetry-version-0.2.0.tar.gz
Size 5.8 kB
Tags Source
SHA-256 checksum
How to use checksums
1b77715b8935589be7977580ecbe454519d1c206d6f99f0d66d4832fa7ac867f
BLAKE2b-256 checksum
How to use checksums
0ab168034358aef14bc53e4a942fb19510814418c380af1f1a1debd1d144a47c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.11 CPython/3.9.7 Linux/5.15.2-1-default

Release files / poetry_version-0.2.0-py2.py3-none-any.whl

Download URL poetry_version-0.2.0-py2.py3-none-any.whl
Size 6.0 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
82445fe406699d84d7b5011d153bf97f2da04f94006e091dbaf302489e01b5b0
BLAKE2b-256 checksum
How to use checksums
176247db245e391350100ce1459b588e015f8a8543030e193a5cc3b0cdcabab5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.11 CPython/3.9.7 Linux/5.15.2-1-default

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files

0.1.5

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page