Skip to content

chore!: drop Python 3.10 support - #2295

Merged
vdusek merged 5 commits into
v2from
drop-python-3.10
Oct 13, 2026
Merged

vdusek merged 5 commits into
v2from
drop-python-3.10

Conversation

@vdusek

@vdusek vdusek commented Oct 13, 2026

Copy link
Copy Markdown
Collaborator

First cleanup PR for v2. Python 3.10 reached end of life on 2026-10-04, so Crawlee v2 requires Python 3.11 or newer.

  • Bumps requires-python to >=3.11 in the package and in the project template, updates the classifiers, the ty target and the CI matrix, and regenerates uv.lock.
  • Applies the ruff fixes the new target enables: datetime.UTC, builtin TimeoutError, and typing imports of Self / NotRequired. Event becomes a StrEnum, so str(Event.X) returns the value.
  • Removes the 3.11 skips and the _restore_crawlers_binding fixture, which only existed for 3.10.
  • Adds an "Upgrading to v2" page and updates the Python version in the README and docs.

The apify_client<3.0.0 dev pin and the async-timeout dependency (#2052) will go in separate PRs.

Closes: #1721

✍️ Drafted by Claude Code

BREAKING CHANGE: The minimum supported Python version is 3.11. `Event` is now a `StrEnum`, so `str()` on a member returns its value.
@vdusek vdusek added the t-tooling Issues with this label are in the ownership of the tooling team. label Oct 13, 2026
@vdusek vdusek self-assigned this Oct 13, 2026
@vdusek
vdusek marked this pull request as ready for review October 13, 2026 11:14
@vdusek
vdusek requested a review from apify-factory October 13, 2026 11:15

@apify-factory apify-factory left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, nothing blocking.

@codecov

codecov Bot commented Oct 13, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 94.11765% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 94.09%. Comparing base (ca71cd2) to head (8811cab).
⚠️ Report is 1 commits behind head on v2.

Files with missing lines Patch % Lines
src/crawlee/http_clients/_curl_impersonate.py 25.00% 3 Missing ⚠️
src/crawlee/http_clients/_impit.py 50.00% 2 Missing ⚠️
src/crawlee/_utils/sitemap.py 75.00% 1 Missing ⚠️
src/crawlee/browsers/_browser_pool.py 50.00% 1 Missing ⚠️
src/crawlee/crawlers/_basic/_basic_crawler.py 75.00% 1 Missing ⚠️
...rawlee/crawlers/_playwright/_playwright_crawler.py 66.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##               v2    #2295      +/-   ##
==========================================
- Coverage   94.11%   94.09%   -0.03%     
==========================================
  Files         183      183              
  Lines       13570    13565       -5     
==========================================
- Hits        12772    12764       -8     
- Misses        798      801       +3     
Flag Coverage Δ
unit 94.09% <94.11%> (-0.03%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@vdusek
vdusek merged commit fbf199c into v2 Oct 13, 2026
28 checks passed
@vdusek
vdusek deleted the drop-python-3.10 branch October 13, 2026 11:25
@vdusek vdusek linked an issue Oct 13, 2026 that may be closed by this pull request
vdusek pushed a commit that referenced this pull request Oct 13, 2026
… Python 3.11 (#2316)

### Description

- Use `typing` instead of `typing_extensions` for types added in Python
3.11.

### Issues

- Follow-up: #2295
vdusek added a commit that referenced this pull request Oct 16, 2026
First cleanup PR for v2. Python 3.10 reached end of life on 2026-10-04,
so Crawlee v2 requires Python 3.11 or newer.

- Bumps `requires-python` to `>=3.11` in the package and in the project
template, updates the classifiers, the ty target and the CI matrix, and
regenerates `uv.lock`.
- Applies the ruff fixes the new target enables: `datetime.UTC`, builtin
`TimeoutError`, and `typing` imports of `Self` / `NotRequired`. `Event`
becomes a `StrEnum`, so `str(Event.X)` returns the value.
- Removes the 3.11 skips and the `_restore_crawlers_binding` fixture,
which only existed for 3.10.
- Adds an "Upgrading to v2" page and updates the Python version in the
README and docs.

The `apify_client<3.0.0` dev pin and the `async-timeout` dependency
(#2052) will go in separate PRs.

Closes: #1721

*✍️ Drafted by Claude Code*
vdusek pushed a commit that referenced this pull request Oct 16, 2026
… Python 3.11 (#2316)

### Description

- Use `typing` instead of `typing_extensions` for types added in Python
3.11.

### Issues

- Follow-up: #2295
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

t-tooling Issues with this label are in the ownership of the tooling team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Drop support for Python 3.10

3 participants