Skip to content

Commit 3fbfad0

Browse files
finswimmerradoering
authored andcommitted
blog: announce Poetry 2.1.0
1 parent c8d2e5d commit 3fbfad0

File tree

2 files changed

+82
-1
lines changed

2 files changed

+82
-1
lines changed
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
---
2+
layout: single
3+
title: "Announcing Poetry 2.1.0"
4+
date: 2025-02-xx
5+
categories: [ releases ]
6+
tags: [ "2.x", "2.1" ]
7+
---
8+
9+
The Poetry team is pleased to announce the immediate availability of Poetry **2.1.0**.
10+
11+
<!--more-->
12+
13+
If you have a previous version of Poetry installed via `pipx`,
14+
getting Poetry **2.1.0** is as easy as:
15+
16+
```bash
17+
$ pipx upgrade poetry
18+
```
19+
20+
If you used the [official installer](/docs/#installation), you can run:
21+
22+
```bash
23+
$ poetry self update
24+
```
25+
26+
## Highlights
27+
28+
### Support for Alternative Build Backends in Poetry
29+
30+
Poetry now supports customizable build backends, allowing greater flexibility based on your project's needs. Previously,
31+
Poetry exclusively used its own build backend, `poetry-core`, when creating packages via the `poetry build` command.
32+
Thanks to [PEP 621](https://peps.python.org/pep-0621/), this limitation is being lifted.
33+
34+
With this change, the `poetry build` command will fully respect the `[build-system]` section defined in your
35+
`pyproject.toml` file. If the specified build backend differs from the version of `poetry-core` bundled with Poetry, the
36+
build will take place in an isolated environment.
37+
38+
#### Defining Custom Build Backends
39+
40+
You can define the build backend in your `pyproject.toml`. For example, to use `maturin` as your build system, specify
41+
it like this:
42+
43+
```toml
44+
[build-system]
45+
requires = ["maturin>=0.8.1,<0.9"]
46+
build-backend = "maturin"
47+
```
48+
49+
When running `poetry build`, Poetry will create an isolated environment with the specified requirements.
50+
51+
#### Passing Configuration to Build Systems
52+
53+
If your chosen build system supports custom configuration settings, these can be passed via the new `--config-settings`
54+
parameter. Use the format `--config-settings <key>=<value>`. You can pass multiple settings by using the parameter
55+
repeatedly.
56+
57+
For example, `poetry-core` allows you to specify a local version identifier during the build:
58+
59+
```bash
60+
poetry build --config-settings local-version=some-local
61+
```
62+
63+
This parameter ensures compatibility with advanced use cases and third-party build backends.
64+
65+
#### Default Behavior When No Build System Is Defined
66+
67+
Per [PEP 517](https://peps.python.org/pep-0517/), a build tool should fall back to `setuptools` if no build system is
68+
defined in the `[build-system]` section of `pyproject.toml`. However, to avoid immediate disruption, Poetry will
69+
currently issue a **warning** in such cases and continue using the built-in `poetry-core` backend by default.
70+
71+
**Note:** This behavior will change in the next minor release of Poetry. When a `[build-system]` section is not defined,
72+
Poetry will then default to using `setuptools`.
73+
74+
## Changelog
75+
76+
TODO

content/history.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ layout: single
44
title: History
55
---
66

7+
## [2.1.0] - 2025-02-xx
8+
9+
TODO
10+
711
## [2.0.1] - 2025-01-11
812

913
### Added
@@ -2268,7 +2272,8 @@ This release **must** be downloaded via the `get-poetry.py` script and not via t
22682272

22692273
Initial release
22702274

2271-
[Unreleased]: https://github.com/python-poetry/poetry/compare/2.0.1...main
2275+
[Unreleased]: https://github.com/python-poetry/poetry/compare/2.1.0...main
2276+
[2.1.0]: https://github.com/python-poetry/poetry/releases/tag/2.1.0
22722277
[2.0.1]: https://github.com/python-poetry/poetry/releases/tag/2.0.1
22732278
[2.0.0]: https://github.com/python-poetry/poetry/releases/tag/2.0.0
22742279
[1.8.5]: https://github.com/python-poetry/poetry/releases/tag/1.8.5

0 commit comments

Comments
 (0)