Skip to content

Commit 4744692

Browse files
vdusekclaude
andcommitted
feat: drop Python 3.10 support
Raise minimum Python version to 3.11. This enables: - Uncommenting crewai and arxiv-mcp-server dependencies (require 3.11+) - Using StrEnum instead of (str, Enum) pattern in mcp-proxy template - Updated CI matrices to test 3.11-3.13 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent d77c780 commit 4744692

7 files changed

Lines changed: 1626 additions & 854 deletions

File tree

.github/workflows/lint_and_test.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@ jobs:
2121
name: Python lint check
2222
uses: apify/workflows/.github/workflows/python_lint_check.yaml@main
2323
with:
24-
python_versions: '["3.10", "3.11", "3.12", "3.13"]'
24+
python_versions: '["3.11", "3.12", "3.13"]'
2525

2626
python_type_check:
2727
name: Python type check
2828
uses: apify/workflows/.github/workflows/python_type_check.yaml@main
2929
with:
30-
python_versions: '["3.10", "3.11", "3.12", "3.13"]'
30+
python_versions: '["3.11", "3.12", "3.13"]'
3131

3232
lint_and_test:
3333
name: Lint and test (without templates)

.github/workflows/test_llm_ai_python_templates.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
strategy:
1010
matrix:
1111
os: [ubuntu-22.04, windows-latest]
12-
python-version: ['3.10', '3.11', '3.12', '3.13']
12+
python-version: ['3.11', '3.12', '3.13']
1313
fail-fast: false
1414
runs-on: ${{ matrix.os }}
1515
timeout-minutes: 60

.github/workflows/test_python_templates.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
strategy:
1010
matrix:
1111
os: [ubuntu-22.04, windows-latest]
12-
python-version: ['3.10', '3.11', '3.12', '3.13']
12+
python-version: ['3.11', '3.12', '3.13']
1313
runs-on: ${{ matrix.os }}
1414
timeout-minutes: 120
1515

pyproject.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
[project]
22
name = "actor-templates"
33
version = "0.0.1"
4-
requires-python = ">= 3.10"
4+
requires-python = ">= 3.11"
55
dependencies = [
66
"apify[scrapy] >= 3.0.0, < 4.0.0",
77
"apify-client",
8-
# "arxiv-mcp-server >= 0.3.1, < 1.0.0", # Requires Python >= 3.11, incompatible with requires-python >= 3.10
8+
"arxiv-mcp-server >= 0.3.1, < 1.0.0",
99
"beautifulsoup4[lxml] >= 4.0.0, < 5.0.0",
1010
"camoufox[geoip] >= 0.4.5, < 1.0.0",
1111
"crawlee[all]",
12-
# "crewai[tools] >= 0.11.0, < 1.0.0", # Pulls onnxruntime via chromadb, which requires Python >= 3.11
12+
"crewai[tools] >= 0.11.0, < 1.0.0",
1313
"fastapi >= 0.135.0, < 1.0.0",
1414
"fastmcp >= 3.0.0, < 4.0.0",
1515
"httpx >= 0.28.0, < 1.0.0",
@@ -94,7 +94,7 @@ asyncio_mode = "auto"
9494
timeout = 1200
9595

9696
[tool.ty.environment]
97-
python-version = "3.10"
97+
python-version = "3.11"
9898

9999
[tool.ty.src]
100100
include = ["templates"]

templates/python-mcp-proxy/my_actor/const.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
from enum import Enum
1+
from enum import StrEnum
22

33
SESSION_TIMEOUT_SECS = 300 # 5 minutes
44

55

6-
class ChargeEvents(str, Enum):
6+
class ChargeEvents(StrEnum):
77
"""Event types for charging MCP operations.
88
99
These events are used to charge users for different types of MCP operations

templates/python-mcp-proxy/my_actor/models.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
from enum import Enum
1+
from enum import StrEnum
22
from typing import Any, TypeAlias
33

44
import httpx
55
from mcp.client.stdio import StdioServerParameters
66
from pydantic import BaseModel, ConfigDict
77

88

9-
class ServerType(str, Enum):
9+
class ServerType(StrEnum):
1010
"""Type of server to connect."""
1111

1212
STDIO = 'stdio' # Connect to a stdio server

uv.lock

Lines changed: 1614 additions & 842 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)