Skip to content

Commit 6252476

Browse files
feat: Add support for Python 3.13 (#13201)
- [ ] Regenerate this pull request now. PiperOrigin-RevId: 689017451 Source-Link: googleapis/googleapis@2c7ba7e Source-Link: googleapis/googleapis-gen@55b4331 Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJpZ3F1ZXJ5LW1pZ3JhdGlvbi8uT3dsQm90LnlhbWwiLCJoIjoiNTViNDMzMTliM2M4YzVmZGU2M2M5MTJiYTU1ZmVjZjQzMTBmMTBiYiJ9 Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJpZ3F1ZXJ5LXJlc2VydmF0aW9uLy5Pd2xCb3QueWFtbCIsImgiOiI1NWI0MzMxOWIzYzhjNWZkZTYzYzkxMmJhNTVmZWNmNDMxMGYxMGJiIn0= Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJpbGxpbmctYnVkZ2V0cy8uT3dsQm90LnlhbWwiLCJoIjoiNTViNDMzMTliM2M4YzVmZGU2M2M5MTJiYTU1ZmVjZjQzMTBmMTBiYiJ9 Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJpbGxpbmcvLk93bEJvdC55YW1sIiwiaCI6IjU1YjQzMzE5YjNjOGM1ZmRlNjNjOTEyYmE1NWZlY2Y0MzEwZjEwYmIifQ== Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWJpbmFyeS1hdXRob3JpemF0aW9uLy5Pd2xCb3QueWFtbCIsImgiOiI1NWI0MzMxOWIzYzhjNWZkZTYzYzkxMmJhNTVmZWNmNDMxMGYxMGJiIn0= Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWNlcnRpZmljYXRlLW1hbmFnZXIvLk93bEJvdC55YW1sIiwiaCI6IjU1YjQzMzE5YjNjOGM1ZmRlNjNjOTEyYmE1NWZlY2Y0MzEwZjEwYmIifQ== Copy-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-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com> Co-authored-by: Anthonios Partheniou <[email protected]>
1 parent f712162 commit 6252476

File tree

291 files changed

+779
-411
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

291 files changed

+779
-411
lines changed

packages/google-cloud-bigquery-migration/.flake8

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -*- coding: utf-8 -*-
22
#
3-
# Copyright 2023 Google LLC
3+
# Copyright 2024 Google LLC
44
#
55
# Licensed under the Apache License, Version 2.0 (the "License");
66
# you may not use this file except in compliance with the License.

packages/google-cloud-bigquery-migration/CONTRIBUTING.rst

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ In order to add a feature:
2222
documentation.
2323

2424
- The feature must work fully on the following CPython versions:
25-
3.7, 3.8, 3.9, 3.10, 3.11 and 3.12 on both UNIX and Windows.
25+
3.7, 3.8, 3.9, 3.10, 3.11, 3.12 and 3.13 on both UNIX and Windows.
2626

2727
- The feature must not add unnecessary dependencies (where
2828
"unnecessary" is of course subjective, but new dependencies should
@@ -72,7 +72,7 @@ We use `nox <https://nox.readthedocs.io/en/latest/>`__ to instrument our tests.
7272

7373
- To run a single unit test::
7474

75-
$ nox -s unit-3.12 -- -k <name of test>
75+
$ nox -s unit-3.13 -- -k <name of test>
7676

7777

7878
.. note::
@@ -143,12 +143,12 @@ Running System Tests
143143
$ nox -s system
144144

145145
# Run a single system test
146-
$ nox -s system-3.12 -- -k <name of test>
146+
$ nox -s system-3.13 -- -k <name of test>
147147

148148

149149
.. note::
150150

151-
System tests are only configured to run under Python 3.8, 3.9, 3.10, 3.11 and 3.12.
151+
System tests are only configured to run under Python 3.8, 3.9, 3.10, 3.11, 3.12 and 3.13.
152152
For expediency, we do not run them in older versions of Python 3.
153153

154154
This alone will not run the tests. You'll need to change some local
@@ -227,13 +227,15 @@ We support:
227227
- `Python 3.10`_
228228
- `Python 3.11`_
229229
- `Python 3.12`_
230+
- `Python 3.13`_
230231

231232
.. _Python 3.7: https://docs.python.org/3.7/
232233
.. _Python 3.8: https://docs.python.org/3.8/
233234
.. _Python 3.9: https://docs.python.org/3.9/
234235
.. _Python 3.10: https://docs.python.org/3.10/
235236
.. _Python 3.11: https://docs.python.org/3.11/
236237
.. _Python 3.12: https://docs.python.org/3.12/
238+
.. _Python 3.13: https://docs.python.org/3.13/
237239

238240

239241
Supported versions can be found in our ``noxfile.py`` `config`_.

packages/google-cloud-bigquery-migration/MANIFEST.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -*- coding: utf-8 -*-
22
#
3-
# Copyright 2023 Google LLC
3+
# Copyright 2024 Google LLC
44
#
55
# Licensed under the Apache License, Version 2.0 (the "License");
66
# you may not use this file except in compliance with the License.

packages/google-cloud-bigquery-migration/docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# -*- coding: utf-8 -*-
2-
# Copyright 2023 Google LLC
2+
# Copyright 2024 Google LLC
33
#
44
# Licensed under the Apache License, Version 2.0 (the "License");
55
# you may not use this file except in compliance with the License.

packages/google-cloud-bigquery-migration/noxfile.py

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -*- coding: utf-8 -*-
22
#
3-
# Copyright 2023 Google LLC
3+
# Copyright 2024 Google LLC
44
#
55
# Licensed under the Apache License, Version 2.0 (the "License");
66
# you may not use this file except in compliance with the License.
@@ -35,7 +35,15 @@
3535

3636
DEFAULT_PYTHON_VERSION = "3.10"
3737

38-
UNIT_TEST_PYTHON_VERSIONS: List[str] = ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]
38+
UNIT_TEST_PYTHON_VERSIONS: List[str] = [
39+
"3.7",
40+
"3.8",
41+
"3.9",
42+
"3.10",
43+
"3.11",
44+
"3.12",
45+
"3.13",
46+
]
3947
UNIT_TEST_STANDARD_DEPENDENCIES = [
4048
"mock",
4149
"asyncmock",
@@ -49,7 +57,7 @@
4957
UNIT_TEST_EXTRAS: List[str] = []
5058
UNIT_TEST_EXTRAS_BY_PYTHON: Dict[str, List[str]] = {}
5159

52-
SYSTEM_TEST_PYTHON_VERSIONS: List[str] = ["3.8", "3.9", "3.10", "3.11", "3.12"]
60+
SYSTEM_TEST_PYTHON_VERSIONS: List[str] = ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
5361
SYSTEM_TEST_STANDARD_DEPENDENCIES = [
5462
"mock",
5563
"pytest",
@@ -168,7 +176,7 @@ def install_unittest_dependencies(session, *constraints):
168176
def unit(session, protobuf_implementation):
169177
# Install all test dependencies, then install this package in-place.
170178

171-
if protobuf_implementation == "cpp" and session.python in ("3.11", "3.12"):
179+
if protobuf_implementation == "cpp" and session.python in ("3.11", "3.12", "3.13"):
172180
session.skip("cpp implementation is not supported in python 3.11+")
173181

174182
constraints_path = str(
@@ -368,15 +376,15 @@ def docfx(session):
368376
)
369377

370378

371-
@nox.session(python="3.12")
379+
@nox.session(python="3.13")
372380
@nox.parametrize(
373381
"protobuf_implementation",
374382
["python", "upb", "cpp"],
375383
)
376384
def prerelease_deps(session, protobuf_implementation):
377385
"""Run all tests with prerelease versions of dependencies installed."""
378386

379-
if protobuf_implementation == "cpp" and session.python in ("3.11", "3.12"):
387+
if protobuf_implementation == "cpp" and session.python in ("3.11", "3.12", "3.13"):
380388
session.skip("cpp implementation is not supported in python 3.11+")
381389

382390
# Install all dependencies

packages/google-cloud-bigquery-migration/scripts/decrypt-secrets.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
# Copyright 2023 Google LLC All rights reserved.
3+
# Copyright 2024 Google LLC All rights reserved.
44
#
55
# Licensed under the Apache License, Version 2.0 (the "License");
66
# you may not use this file except in compliance with the License.

packages/google-cloud-bigquery-migration/setup.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
# See https://github.com/googleapis/google-cloud-python/issues/12364
4747
"google-auth >= 2.14.1, <3.0.0dev,!=2.24.0,!=2.25.0",
4848
"proto-plus >= 1.22.3, <2.0.0dev",
49+
"proto-plus >= 1.25.0, <2.0.0dev; python_version >= '3.13'",
4950
"protobuf>=3.20.2,<6.0.0dev,!=4.21.0,!=4.21.1,!=4.21.2,!=4.21.3,!=4.21.4,!=4.21.5",
5051
]
5152
extras = {}
@@ -84,6 +85,7 @@
8485
"Programming Language :: Python :: 3.10",
8586
"Programming Language :: Python :: 3.11",
8687
"Programming Language :: Python :: 3.12",
88+
"Programming Language :: Python :: 3.13",
8789
"Operating System :: OS Independent",
8890
"Topic :: Internet",
8991
],
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# -*- coding: utf-8 -*-
2+
# This constraints file is required for unit tests.
3+
# List all library dependencies and extras in this file.
4+
google-api-core
5+
proto-plus
6+
protobuf

packages/google-cloud-bigquery-reservation/.flake8

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -*- coding: utf-8 -*-
22
#
3-
# Copyright 2023 Google LLC
3+
# Copyright 2024 Google LLC
44
#
55
# Licensed under the Apache License, Version 2.0 (the "License");
66
# you may not use this file except in compliance with the License.

packages/google-cloud-bigquery-reservation/CONTRIBUTING.rst

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ In order to add a feature:
2222
documentation.
2323

2424
- The feature must work fully on the following CPython versions:
25-
3.7, 3.8, 3.9, 3.10, 3.11 and 3.12 on both UNIX and Windows.
25+
3.7, 3.8, 3.9, 3.10, 3.11, 3.12 and 3.13 on both UNIX and Windows.
2626

2727
- The feature must not add unnecessary dependencies (where
2828
"unnecessary" is of course subjective, but new dependencies should
@@ -72,7 +72,7 @@ We use `nox <https://nox.readthedocs.io/en/latest/>`__ to instrument our tests.
7272

7373
- To run a single unit test::
7474

75-
$ nox -s unit-3.12 -- -k <name of test>
75+
$ nox -s unit-3.13 -- -k <name of test>
7676

7777

7878
.. note::
@@ -143,12 +143,12 @@ Running System Tests
143143
$ nox -s system
144144

145145
# Run a single system test
146-
$ nox -s system-3.12 -- -k <name of test>
146+
$ nox -s system-3.13 -- -k <name of test>
147147

148148

149149
.. note::
150150

151-
System tests are only configured to run under Python 3.8, 3.9, 3.10, 3.11 and 3.12.
151+
System tests are only configured to run under Python 3.8, 3.9, 3.10, 3.11, 3.12 and 3.13.
152152
For expediency, we do not run them in older versions of Python 3.
153153

154154
This alone will not run the tests. You'll need to change some local
@@ -227,13 +227,15 @@ We support:
227227
- `Python 3.10`_
228228
- `Python 3.11`_
229229
- `Python 3.12`_
230+
- `Python 3.13`_
230231

231232
.. _Python 3.7: https://docs.python.org/3.7/
232233
.. _Python 3.8: https://docs.python.org/3.8/
233234
.. _Python 3.9: https://docs.python.org/3.9/
234235
.. _Python 3.10: https://docs.python.org/3.10/
235236
.. _Python 3.11: https://docs.python.org/3.11/
236237
.. _Python 3.12: https://docs.python.org/3.12/
238+
.. _Python 3.13: https://docs.python.org/3.13/
237239

238240

239241
Supported versions can be found in our ``noxfile.py`` `config`_.

0 commit comments

Comments
 (0)