Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .kokoro/samples/python3.14/common.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Format: //devtools/kokoro/config/proto/build.proto

# Build logs will be here
action {
define_artifacts {
regex: "**/*sponge_log.xml"
}
}

# Specify which tests to run
env_vars: {
key: "RUN_TESTS_SESSION"
value: "unit-3.14"
}

# Download trampoline resources.
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline"

# Download resources for system tests (service account key, etc.)
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/google-auth-library-python"

# Use the trampoline script to run in docker.
build_file: "google-auth-library-python/.kokoro/trampoline.sh"

# Configure the docker image for kokoro-trampoline.
env_vars: {
key: "TRAMPOLINE_IMAGE"
value: "gcr.io/cloud-devrel-kokoro-resources/python-multi"
}
env_vars: {
key: "TRAMPOLINE_BUILD_FILE"
value: "github/google-auth-library-python/.kokoro/build.sh"
}
env_vars: {
key: "TRAMPOLINE_BUILD_FILE"
value: "github/google-auth-library-python/.kokoro/samples-test-setup.sh"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.14/continuous.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}
11 changes: 11 additions & 0 deletions .kokoro/samples/python3.14/periodic-head.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}

env_vars: {
key: "TRAMPOLINE_BUILD_FILE"
value: "github/google-auth-library-python/.kokoro/test-samples-against-head.sh"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.14/periodic.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "False"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.14/presubmit.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}
3 changes: 2 additions & 1 deletion noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
DEFAULT_PYTHON_VERSION = "3.10"
# TODO(https://github.com/googleapis/google-auth-library-python/issues/1787):
# Remove or restore testing for Python 3.7/3.8
UNIT_TEST_PYTHON_VERSIONS = ["3.9", "3.10", "3.11", "3.12", "3.13"]
UNIT_TEST_PYTHON_VERSIONS = ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]

# Error if a python version is missing
nox.options.error_on_missing_interpreters = True
Expand All @@ -53,6 +53,7 @@
"unit-3.11",
"unit-3.12",
"unit-3.13",
"unit-3.14",
# cover must be last to avoid error `No data to report`
"cover",
"docs",
Expand Down
2 changes: 1 addition & 1 deletion samples/cloud-client/snippets/noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
]


@nox.session(python=["3.7", "3.8", "3.9", "3.10", "3.11", "3.12", "3.13"])
@nox.session(python=["3.7", "3.8", "3.9", "3.10", "3.11", "3.12", "3.13", "3.14"])
def unit(session):
# constraints_path = str(
# CURRENT_DIRECTORY / "testing" / f"constraints-{session.python}.txt"
Expand Down
3 changes: 2 additions & 1 deletion samples/cloud-client/snippets/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
google-cloud-compute==1.5.1
google-cloud-storage==3.1.0
google-auth==2.38.0
pytest==7.1.2
pytest===7.1.2; python_version <= '3.13'
pytest==8.4.2; python_version == '3.14'
Copy link
Collaborator

Choose a reason for hiding this comment

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

is this needed? Can we use 8.4.2 for all?

1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"License :: OSI Approved :: Apache Software License",
Expand Down
Empty file added testing/constraints-3.14.txt
Empty file.
11 changes: 7 additions & 4 deletions tests_async/transport/test_aiohttp_requests.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,11 @@ def make_with_parameter_request(self):
http = aiohttp.ClientSession(auto_decompress=False)
return aiohttp_requests.Request(http)

def test_unsupported_session(self):
@pytest.mark.asyncio
async def test_unsupported_session(self):
http = aiohttp.ClientSession(auto_decompress=True)
with pytest.raises(ValueError):
aiohttp_requests.Request(http)
await aiohttp_requests.Request(http)
Copy link
Collaborator

Choose a reason for hiding this comment

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

why were these tests changed to async?


def test_timeout(self):
http = mock.create_autospec(
Expand All @@ -144,11 +145,13 @@ class TestAuthorizedSession(object):
TEST_URL = "http://example.com/"
method = "GET"

def test_constructor(self):
@pytest.mark.asyncio
async def test_constructor(self):
authed_session = aiohttp_requests.AuthorizedSession(mock.sentinel.credentials)
assert authed_session.credentials == mock.sentinel.credentials

def test_constructor_with_auth_request(self):
@pytest.mark.asyncio
async def test_constructor_with_auth_request(self):
http = mock.create_autospec(
aiohttp.ClientSession, instance=True, _auto_decompress=False
)
Expand Down