Poetry Plugin: Export

1.10.0 · active · verified Sat Mar 28

poetry-plugin-export is an official Poetry plugin, currently at version 1.10.0, that extends Poetry's functionality by providing an `export` command. This command allows users to convert locked dependencies from `poetry.lock` files into various standardized formats such as `requirements.txt`, `constraints.txt`, and `pylock.toml`. It aims to eventually replace the functionality of Poetry's built-in `export` command (which is no longer bundled by default in Poetry 2.0+). The plugin is actively maintained, with releases tied to the evolution of Poetry itself.

Warnings

Install

Quickstart

The plugin provides an `export` command that integrates directly into the Poetry CLI. You can specify the output format, file, and control which dependency groups are included or excluded. The most common use case is generating a `requirements.txt` for environments that rely on `pip`.

# Assuming a pyproject.toml and poetry.lock exist in the current directory
# and poetry-plugin-export is installed.

# Export to a standard requirements.txt file
poetry export -f requirements.txt --output requirements.txt

# Export with development dependencies and without package hashes
poetry export -f requirements.txt --output dev_requirements.txt --with dev --without-hashes

# Export to a constraints.txt file including all dependency groups
poetry export -f constraints.txt --output constraints.txt --all-groups

view raw JSON →