Skip to content

Commit ad3c435

Browse files
authored
tests: Move boto3 tests under toxgen (#4761)
Move boto3 under toxgen. Also, update how Python version constraints are generated. Ref #4506
1 parent 0c0a8d8 commit ad3c435

File tree

5 files changed

+30
-34
lines changed

5 files changed

+30
-34
lines changed

.github/workflows/test-integrations-cloud.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
strategy:
3030
fail-fast: false
3131
matrix:
32-
python-version: ["3.8","3.11","3.12","3.13"]
32+
python-version: ["3.8","3.12","3.13"]
3333
# python3.6 reached EOL and is no longer being supported on
3434
# new versions of hosted runners on Github Actions
3535
# ubuntu-20.04 is the last version that supported python3.6
@@ -108,7 +108,7 @@ jobs:
108108
strategy:
109109
fail-fast: false
110110
matrix:
111-
python-version: ["3.6","3.7","3.8","3.9","3.11","3.12","3.13"]
111+
python-version: ["3.6","3.7","3.8","3.9","3.10","3.11","3.12","3.13"]
112112
# python3.6 reached EOL and is no longer being supported on
113113
# new versions of hosted runners on Github Actions
114114
# ubuntu-20.04 is the last version that supported python3.6

scripts/populate_tox/config.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,12 @@
4747
"package": "apache-beam",
4848
"python": ">=3.7",
4949
},
50+
"boto3": {
51+
"package": "boto3",
52+
"deps": {
53+
"py3.7,py3.8": ["urllib3<2.0.0"],
54+
},
55+
},
5056
"bottle": {
5157
"package": "bottle",
5258
"deps": {

scripts/populate_tox/populate_tox.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,6 @@
6767
"potel",
6868
# Integrations that can be migrated -- we should eventually remove all
6969
# of these from the IGNORE list
70-
"boto3",
7170
"chalice",
7271
"gcp",
7372
"httpx",
@@ -439,7 +438,7 @@ def _render_dependencies(integration: str, releases: list[Version]) -> list[str]
439438
rendered.append(f"{integration}: {dep}")
440439
elif constraint.startswith("py3"):
441440
for dep in deps:
442-
rendered.append(f"{constraint}-{integration}: {dep}")
441+
rendered.append(f"{{{constraint}}}-{integration}: {dep}")
443442
else:
444443
restriction = SpecifierSet(constraint)
445444
for release in releases:

scripts/populate_tox/tox.jinja

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,6 @@ envlist =
4242
# AWS Lambda
4343
{py3.8,py3.9,py3.11,py3.13}-aws_lambda
4444

45-
# Boto3
46-
{py3.6,py3.7}-boto3-v{1.12}
47-
{py3.7,py3.11,py3.12}-boto3-v{1.23}
48-
{py3.11,py3.12}-boto3-v{1.34}
49-
{py3.11,py3.12,py3.13}-boto3-latest
50-
5145
# Chalice
5246
{py3.6,py3.9}-chalice-v{1.16}
5347
{py3.8,py3.12,py3.13}-chalice-latest
@@ -164,12 +158,6 @@ deps =
164158
aws_lambda: requests
165159
aws_lambda: uvicorn
166160
167-
# Boto3
168-
boto3-v1.12: boto3~=1.12.0
169-
boto3-v1.23: boto3~=1.23.0
170-
boto3-v1.34: boto3~=1.34.0
171-
boto3-latest: boto3
172-
173161
# Chalice
174162
chalice: pytest-chalice==0.0.5
175163
chalice-v1.16: chalice~=1.16.0

tox.ini

Lines changed: 21 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
# The file (and all resulting CI YAMLs) then need to be regenerated via
1111
# "scripts/generate-test-files.sh".
1212
#
13-
# Last generated: 2025-09-05T06:53:57.545461+00:00
13+
# Last generated: 2025-09-05T07:14:50.663886+00:00
1414

1515
[tox]
1616
requires =
@@ -42,12 +42,6 @@ envlist =
4242
# AWS Lambda
4343
{py3.8,py3.9,py3.11,py3.13}-aws_lambda
4444

45-
# Boto3
46-
{py3.6,py3.7}-boto3-v{1.12}
47-
{py3.7,py3.11,py3.12}-boto3-v{1.23}
48-
{py3.11,py3.12}-boto3-v{1.34}
49-
{py3.11,py3.12,py3.13}-boto3-latest
50-
5145
# Chalice
5246
{py3.6,py3.9}-chalice-v{1.16}
5347
{py3.8,py3.12,py3.13}-chalice-latest
@@ -152,6 +146,13 @@ envlist =
152146
{py3.8,py3.12,py3.13}-huggingface_hub-v0.35.0rc0
153147

154148

149+
# ~~~ Cloud ~~~
150+
{py3.6,py3.7}-boto3-v1.12.49
151+
{py3.6,py3.9,py3.10}-boto3-v1.20.54
152+
{py3.7,py3.11,py3.12}-boto3-v1.28.85
153+
{py3.9,py3.12,py3.13}-boto3-v1.40.24
154+
155+
155156
# ~~~ DBs ~~~
156157
{py3.7,py3.8,py3.9}-asyncpg-v0.23.0
157158
{py3.7,py3.9,py3.10}-asyncpg-v0.25.0
@@ -371,12 +372,6 @@ deps =
371372
aws_lambda: requests
372373
aws_lambda: uvicorn
373374

374-
# Boto3
375-
boto3-v1.12: boto3~=1.12.0
376-
boto3-v1.23: boto3~=1.23.0
377-
boto3-v1.34: boto3~=1.34.0
378-
boto3-latest: boto3
379-
380375
# Chalice
381376
chalice: pytest-chalice==0.0.5
382377
chalice-v1.16: chalice~=1.16.0
@@ -539,6 +534,14 @@ deps =
539534
huggingface_hub-v0.35.0rc0: huggingface_hub==0.35.0rc0
540535

541536

537+
# ~~~ Cloud ~~~
538+
boto3-v1.12.49: boto3==1.12.49
539+
boto3-v1.20.54: boto3==1.20.54
540+
boto3-v1.28.85: boto3==1.28.85
541+
boto3-v1.40.24: boto3==1.40.24
542+
{py3.7,py3.8}-boto3: urllib3<2.0.0
543+
544+
542545
# ~~~ DBs ~~~
543546
asyncpg-v0.23.0: asyncpg==0.23.0
544547
asyncpg-v0.25.0: asyncpg==0.25.0
@@ -604,7 +607,7 @@ deps =
604607
graphene: fastapi
605608
graphene: flask
606609
graphene: httpx
607-
py3.6-graphene: aiocontextvars
610+
{py3.6}-graphene: aiocontextvars
608611

609612
strawberry-v0.209.8: strawberry-graphql[fastapi,flask]==0.209.8
610613
strawberry-v0.233.3: strawberry-graphql[fastapi,flask]==0.233.3
@@ -648,7 +651,7 @@ deps =
648651
celery-v5.5.3: celery==5.5.3
649652
celery: newrelic<10.17.0
650653
celery: redis
651-
py3.7-celery: importlib-metadata<5.0
654+
{py3.7}-celery: importlib-metadata<5.0
652655

653656
dramatiq-v1.9.0: dramatiq==1.9.0
654657
dramatiq-v1.12.3: dramatiq==1.12.3
@@ -717,7 +720,7 @@ deps =
717720
starlette-v0.16.0: httpx<0.28.0
718721
starlette-v0.26.1: httpx<0.28.0
719722
starlette-v0.36.3: httpx<0.28.0
720-
py3.6-starlette: aiocontextvars
723+
{py3.6}-starlette: aiocontextvars
721724

722725
fastapi-v0.79.1: fastapi==0.79.1
723726
fastapi-v0.91.0: fastapi==0.91.0
@@ -731,7 +734,7 @@ deps =
731734
fastapi-v0.79.1: httpx<0.28.0
732735
fastapi-v0.91.0: httpx<0.28.0
733736
fastapi-v0.103.2: httpx<0.28.0
734-
py3.6-fastapi: aiocontextvars
737+
{py3.6}-fastapi: aiocontextvars
735738

736739

737740
# ~~~ Web 2 ~~~
@@ -787,7 +790,7 @@ deps =
787790
tornado: pytest
788791
tornado-v6.0.4: pytest<8.2
789792
tornado-v6.2: pytest<8.2
790-
py3.6-tornado: aiocontextvars
793+
{py3.6}-tornado: aiocontextvars
791794

792795

793796
# ~~~ Misc ~~~

0 commit comments

Comments
 (0)