Skip to content

ci: build releases on Python 3.13 so poetry installs - #57

Closed
devin-ai-integration[bot] wants to merge 1 commit into
mainfrom
devin/1789057091-fix-release-poetry-python
Closed

ci: build releases on Python 3.13 so poetry installs#57
devin-ai-integration[bot] wants to merge 1 commit into
mainfrom
devin/1789057091-fix-release-poetry-python

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Sep 10, 2026

Copy link
Copy Markdown
Contributor

Requirements

  • I have added test coverage for new or changed functionality
  • I have followed the repository's pull request submission guidelines
  • I have validated my changes against all supported platform versions

Related issues

Describe the solution you've provided

Both release workflows ran actions/setup-python with python-version: 3.9 and then installed poetry into that interpreter, so the Install poetry step now fails with:

Fatal error from pip prevented installation.
    TypeError: dataclass() got an unexpected keyword argument 'slots'

setup-python upgrades pip in the selected interpreter (log shows Successfully installed pip-26.0.1), and pip 26 requires Python >= 3.10 — dataclass(slots=...) is 3.10+ — so pipx can no longer install poetry under 3.9 at any poetry version. This is why pinning poetry-version: 1.8.5 in #56 did not help.

This bumps the release/publish interpreter to 3.13. Release builds only run poetry build and make docs, neither of which needs the oldest supported interpreter, and the produced wheel/sdist keep python = ">=3.9" from pyproject.toml. ci.yml still tests 3.9–3.13 and is unaffected (it installs poetry before setup-python, using the runner's default interpreter, which is why CI stayed green).

Note: 1.2.1 was never published — PyPI is still at 1.2.0 — so after this merges the Publish Package workflow needs to be re-run for 1.2.1.

Describe alternatives you've considered

  • Move Install poetry before setup-python, as ci.yml does, so poetry installs into the runner's default interpreter. Works, but leaves the release step implicitly dependent on step ordering.
  • Pin poetry (already done in ci: Pin poetry to 1.8.5 in the release workflows #56) — insufficient, since the failure comes from pip on 3.9, not the poetry version.

Additional context

Same 3.9 setup existed in release-please.yml and manual-publish.yml; both are updated.

Link to Devin session: https://app.devin.ai/sessions/27c11423375c4470807e81afc8567bb1
Open in Devin Desktop: https://app.devin.ai/desktop/session/27c11423375c4470807e81afc8567bb1?variant=devin


Note

Overview
Fixes broken release and manual publish jobs by running actions/setup-python with Python 3.13 instead of 3.9 in manual-publish.yml and release-please.yml.

setup-python pulls in pip 26, which needs Python ≥ 3.10, so installing Poetry under 3.9 fails (dataclass(slots=...)). Release steps only use Poetry to build and publish; wheel/sdist metadata still targets python >= 3.9 from pyproject.toml, and ci.yml matrix testing is unchanged.

Reviewed by Cursor Bugbot for commit a384b75. Bugbot is set up for automated code reviews on this repo. Configure here.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment, CI, and merge conflict monitoring

@devin-ai-integration
devin-ai-integration Bot requested a review from a team as a code owner September 10, 2026 16:18
@kinyoklion kinyoklion closed this Sep 10, 2026
kinyoklion pushed a commit that referenced this pull request Sep 10, 2026
Installs poetry before `actions/setup-python` in both release workflows,
matching `ci.yml`, so the release build keeps Python 3.9.

- Fixes the `Install poetry` failure in `release-please.yml` and
`manual-publish.yml` (latest occurrence:
https://github.com/launchdarkly/python-server-sdk-otel/actions/runs/34501023236/job/102951560951)
- No version changes: `poetry-version: "1.8.5"` and `python-version:
3.9` stay as they are
- 1.2.1 was never published (PyPI is still at 1.2.0), so `Publish
Package` needs a re-run once this merges

**Requirements**

- [ ] I have added test coverage for new or changed functionality
- [x] I have followed the repository's [pull request submission
guidelines](../blob/main/CONTRIBUTING.md#submitting-pull-requests)
- [x] I have validated my changes against all supported platform
versions

<details>
<summary>Implementation details</summary>

Root cause: with `setup-python` first, the poetry action's pipx install
runs under the 3.9 interpreter that `setup-python` just provisioned —
and `setup-python` upgrades pip in that interpreter (`Successfully
installed pip-26.0.1` in the job log). pip 26 no longer supports 3.9, so
pipx fails with `TypeError: dataclass() got an unexpected keyword
argument 'slots'` (that kwarg is 3.10+). This is version-independent for
poetry, which is why pinning `poetry-version: "1.8.5"` in #56 did not
fix it.

Why `ci.yml` stayed green: it installs poetry first, so pipx uses the
runner image's interpreter — the 3.9 matrix job logs `installed package
poetry 1.8.5, installed using Python 3.12.3` — and `setup-python` then
provisions 3.9 for the steps that follow. This PR gives the release
workflows the same ordering, so poetry itself runs on the image python
while `poetry build` / `make docs` still execute against 3.9.

Alternative rejected: bumping the release interpreter to 3.13 (#57,
closed) — it works, but drops 3.9 from the release path unnecessarily.
</details>


Link to Devin session:
https://app.devin.ai/sessions/27c11423375c4470807e81afc8567bb1
Open in Devin Desktop:
https://app.devin.ai/desktop/session/27c11423375c4470807e81afc8567bb1?variant=devin

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Overview**
> Reorders steps in **`manual-publish.yml`** and
**`release-please.yml`** so **Install poetry** runs **before**
`actions/setup-python`, matching **`ci.yml`**.
> 
> This fixes release jobs that failed when poetry was installed via pipx
after `setup-python` had upgraded pip on Python 3.9 (pip 26 + 3.9
incompatibility). Poetry now installs using the runner’s default
interpreter; **Python 3.9** and **poetry 1.8.5** are unchanged for
build/publish steps.
> 
> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit
19d346d. Bugbot is set up for automated
code reviews on this repo. Configure
[here](https://www.cursor.com/dashboard/bugbot).</sup>
<!-- /CURSOR_SUMMARY -->

Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant