From e4be53aa27eb904de7068e8a503fbcd3109cced1 Mon Sep 17 00:00:00 2001 From: Nidhi Nandwani Date: Thu, 11 Jun 2026 10:57:01 +0000 Subject: [PATCH 01/31] feat(python): add deleteFolderRecursive sample This adds a sample demonstrating how to recursively delete a folder in a hierarchical namespace bucket. Fixes: b/521168740 [Generated-by: AI] --- storagecontrol/delete_folder_recursive.py | 49 +++++++++++++++++++++++ storagecontrol/snippets_test.py | 24 ++++++++++- 2 files changed, 72 insertions(+), 1 deletion(-) create mode 100644 storagecontrol/delete_folder_recursive.py diff --git a/storagecontrol/delete_folder_recursive.py b/storagecontrol/delete_folder_recursive.py new file mode 100644 index 00000000000..fb13a9c47ef --- /dev/null +++ b/storagecontrol/delete_folder_recursive.py @@ -0,0 +1,49 @@ +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import sys + +# [START storage_control_delete_folder_recursive] +from google.cloud import storage_control_v2 + + +def delete_folder_recursive(bucket_name: str, folder_name: str) -> None: + # The ID of your GCS bucket + # bucket_name = "your-unique-bucket-name" + + # The name of the folder to be deleted recursively + # folder_name = "folder-name" + + storage_control_client = storage_control_v2.StorageControlClient() + # The storage bucket path uses the global access pattern, in which the "_" + # denotes this bucket exists in the global namespace. + # Set project to "_" to signify globally scoped bucket + folder_path = storage_control_client.folder_path( + project="_", bucket=bucket_name, folder=folder_name + ) + + request = storage_control_v2.DeleteFolderRecursiveRequest( + name=folder_path, + ) + operation = storage_control_client.delete_folder_recursive(request=request) + operation.result() + + print(f"Deleted folder: {folder_path}") + + +# [END storage_control_delete_folder_recursive] + + +if __name__ == "__main__": + delete_folder_recursive(bucket_name=sys.argv[1], folder_name=sys.argv[2]) diff --git a/storagecontrol/snippets_test.py b/storagecontrol/snippets_test.py index 218a3b7f26a..89de089f306 100644 --- a/storagecontrol/snippets_test.py +++ b/storagecontrol/snippets_test.py @@ -26,7 +26,6 @@ import managed_folder_list import rename_folder - # === Folders === # @@ -103,3 +102,26 @@ def test_managed_folder_create_get_list_delete( ) out, _ = capsys.readouterr() assert folder_name in out + + +def test_delete_folder_recursive( + capsys: pytest.LogCaptureFixture, hns_enabled_bucket: storage.Bucket, uuid_name: str +) -> None: + import delete_folder_recursive + + bucket_name = hns_enabled_bucket.name + folder_name = uuid_name + + # Create folder + create_folder.create_folder(bucket_name=bucket_name, folder_name=folder_name) + + # Create a nested folder + nested_folder_name = f"{folder_name}/nested_folder" + create_folder.create_folder(bucket_name=bucket_name, folder_name=nested_folder_name) + + # Test delete folder recursive + delete_folder_recursive.delete_folder_recursive( + bucket_name=bucket_name, folder_name=folder_name + ) + out, _ = capsys.readouterr() + assert folder_name in out From 54689cbaee96a1f5bd4934752172b2eaa7356802 Mon Sep 17 00:00:00 2001 From: Nidhi Nandwani Date: Thu, 11 Jun 2026 11:30:19 +0000 Subject: [PATCH 02/31] fix: resolve PR feedback for imports [Generated-by: AI] --- storagecontrol/snippets_test.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/storagecontrol/snippets_test.py b/storagecontrol/snippets_test.py index 89de089f306..3557828ff72 100644 --- a/storagecontrol/snippets_test.py +++ b/storagecontrol/snippets_test.py @@ -12,18 +12,17 @@ # See the License for the specific language governing permissions and # limitations under the License. -from google.cloud import storage - -import pytest - import create_folder import delete_folder +import delete_folder_recursive import get_folder +from google.cloud import storage import list_folders import managed_folder_create import managed_folder_delete import managed_folder_get import managed_folder_list +import pytest import rename_folder # === Folders === # @@ -107,8 +106,6 @@ def test_managed_folder_create_get_list_delete( def test_delete_folder_recursive( capsys: pytest.LogCaptureFixture, hns_enabled_bucket: storage.Bucket, uuid_name: str ) -> None: - import delete_folder_recursive - bucket_name = hns_enabled_bucket.name folder_name = uuid_name From 7748fae56f4ba74f06ec108653e7304973ce6a3a Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 13:46:44 +0000 Subject: [PATCH 03/31] fix: re-enable Kokoro presubmit configs to fix CI failures --- .kokoro/lint/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.10/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.11/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.12/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.13/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.14/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.8/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.9/presubmit.cfg | 21 +++++++++++++++++++++ 8 files changed, 168 insertions(+) create mode 100644 .kokoro/lint/presubmit.cfg create mode 100644 .kokoro/python3.10/presubmit.cfg create mode 100644 .kokoro/python3.11/presubmit.cfg create mode 100644 .kokoro/python3.12/presubmit.cfg create mode 100644 .kokoro/python3.13/presubmit.cfg create mode 100644 .kokoro/python3.14/presubmit.cfg create mode 100644 .kokoro/python3.8/presubmit.cfg create mode 100644 .kokoro/python3.9/presubmit.cfg diff --git a/.kokoro/lint/presubmit.cfg b/.kokoro/lint/presubmit.cfg new file mode 100644 index 00000000000..e6d49899414 --- /dev/null +++ b/.kokoro/lint/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.10/presubmit.cfg b/.kokoro/python3.10/presubmit.cfg new file mode 100644 index 00000000000..e6d49899414 --- /dev/null +++ b/.kokoro/python3.10/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.11/presubmit.cfg b/.kokoro/python3.11/presubmit.cfg new file mode 100644 index 00000000000..e6d49899414 --- /dev/null +++ b/.kokoro/python3.11/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.12/presubmit.cfg b/.kokoro/python3.12/presubmit.cfg new file mode 100644 index 00000000000..e6d49899414 --- /dev/null +++ b/.kokoro/python3.12/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.13/presubmit.cfg b/.kokoro/python3.13/presubmit.cfg new file mode 100644 index 00000000000..e6d49899414 --- /dev/null +++ b/.kokoro/python3.13/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.14/presubmit.cfg b/.kokoro/python3.14/presubmit.cfg new file mode 100644 index 00000000000..e6d49899414 --- /dev/null +++ b/.kokoro/python3.14/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.8/presubmit.cfg b/.kokoro/python3.8/presubmit.cfg new file mode 100644 index 00000000000..e6d49899414 --- /dev/null +++ b/.kokoro/python3.8/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.9/presubmit.cfg b/.kokoro/python3.9/presubmit.cfg new file mode 100644 index 00000000000..e6d49899414 --- /dev/null +++ b/.kokoro/python3.9/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2026 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} From e025f934880f7cb6f545c9c20904018d3752b1fe Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 13:46:49 +0000 Subject: [PATCH 04/31] fix: remove disabled Kokoro configs (re-enabled) --- .kokoro/lint/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/lint/presubmit.cfg.disabled diff --git a/.kokoro/lint/presubmit.cfg.disabled b/.kokoro/lint/presubmit.cfg.disabled deleted file mode 100644 index d74d307bbed..00000000000 --- a/.kokoro/lint/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 27eb583f7fc9e0237b1ba7814f31853ad356089c Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 13:46:53 +0000 Subject: [PATCH 05/31] fix: remove disabled Kokoro configs (re-enabled) - python3.8 --- .kokoro/python3.8/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.8/presubmit.cfg.disabled diff --git a/.kokoro/python3.8/presubmit.cfg.disabled b/.kokoro/python3.8/presubmit.cfg.disabled deleted file mode 100644 index d74d307bbed..00000000000 --- a/.kokoro/python3.8/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 72c20feece08e30cab9519d89c2a8a61b8f7c7e5 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 13:46:57 +0000 Subject: [PATCH 06/31] fix: remove disabled Kokoro configs (re-enabled) - python3.12 --- .kokoro/python3.12/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.12/presubmit.cfg.disabled diff --git a/.kokoro/python3.12/presubmit.cfg.disabled b/.kokoro/python3.12/presubmit.cfg.disabled deleted file mode 100644 index e2b31b88480..00000000000 --- a/.kokoro/python3.12/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2023 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 27ec3eac3e4ac04cfcc35d25756ca9f1d1e46728 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 13:47:02 +0000 Subject: [PATCH 07/31] fix: remove remaining disabled Kokoro configs --- .kokoro/python3.9/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.9/presubmit.cfg.disabled diff --git a/.kokoro/python3.9/presubmit.cfg.disabled b/.kokoro/python3.9/presubmit.cfg.disabled deleted file mode 100644 index d74d307bbed..00000000000 --- a/.kokoro/python3.9/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 65c475ff71c0716e23b8456890e814db959e3940 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 13:47:05 +0000 Subject: [PATCH 08/31] fix: remove remaining disabled Kokoro configs - 3.10 --- .kokoro/python3.10/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.10/presubmit.cfg.disabled diff --git a/.kokoro/python3.10/presubmit.cfg.disabled b/.kokoro/python3.10/presubmit.cfg.disabled deleted file mode 100644 index 158c832fcd5..00000000000 --- a/.kokoro/python3.10/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2021 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 7f556fed316a7d54776599803dc124f5fac73363 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 13:47:08 +0000 Subject: [PATCH 09/31] fix: remove remaining disabled Kokoro configs - 3.11 --- .kokoro/python3.11/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.11/presubmit.cfg.disabled diff --git a/.kokoro/python3.11/presubmit.cfg.disabled b/.kokoro/python3.11/presubmit.cfg.disabled deleted file mode 100644 index e2b31b88480..00000000000 --- a/.kokoro/python3.11/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2023 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From f4fe0c90b5d5e0307600e8a8659ab9dd328074b0 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 13:47:12 +0000 Subject: [PATCH 10/31] fix: remove remaining disabled Kokoro configs - 3.13 --- .kokoro/python3.13/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.13/presubmit.cfg.disabled diff --git a/.kokoro/python3.13/presubmit.cfg.disabled b/.kokoro/python3.13/presubmit.cfg.disabled deleted file mode 100644 index d6b8ff9c6b8..00000000000 --- a/.kokoro/python3.13/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2024 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 81b99af352c2fcccf28736590c7808aaa58d8c91 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 13:47:16 +0000 Subject: [PATCH 11/31] fix: remove remaining disabled Kokoro configs - 3.14 --- .kokoro/python3.14/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.14/presubmit.cfg.disabled diff --git a/.kokoro/python3.14/presubmit.cfg.disabled b/.kokoro/python3.14/presubmit.cfg.disabled deleted file mode 100644 index b8ecd3b0d15..00000000000 --- a/.kokoro/python3.14/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2025 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 1f15f41716d9005e9768fa3050037ff7b48f9e61 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 15:55:07 +0000 Subject: [PATCH 12/31] fix: revert re-enabling of Kokoro jobs to resolve CI failures --- .kokoro/lint/presubmit.cfg.disabled | 21 +++++++++++++++++++++ .kokoro/python3.10/presubmit.cfg.disabled | 21 +++++++++++++++++++++ .kokoro/python3.11/presubmit.cfg.disabled | 21 +++++++++++++++++++++ .kokoro/python3.12/presubmit.cfg.disabled | 21 +++++++++++++++++++++ .kokoro/python3.13/presubmit.cfg.disabled | 21 +++++++++++++++++++++ .kokoro/python3.14/presubmit.cfg.disabled | 21 +++++++++++++++++++++ .kokoro/python3.8/presubmit.cfg.disabled | 21 +++++++++++++++++++++ .kokoro/python3.9/presubmit.cfg.disabled | 21 +++++++++++++++++++++ 8 files changed, 168 insertions(+) create mode 100644 .kokoro/lint/presubmit.cfg.disabled create mode 100644 .kokoro/python3.10/presubmit.cfg.disabled create mode 100644 .kokoro/python3.11/presubmit.cfg.disabled create mode 100644 .kokoro/python3.12/presubmit.cfg.disabled create mode 100644 .kokoro/python3.13/presubmit.cfg.disabled create mode 100644 .kokoro/python3.14/presubmit.cfg.disabled create mode 100644 .kokoro/python3.8/presubmit.cfg.disabled create mode 100644 .kokoro/python3.9/presubmit.cfg.disabled diff --git a/.kokoro/lint/presubmit.cfg.disabled b/.kokoro/lint/presubmit.cfg.disabled new file mode 100644 index 00000000000..d74d307bbed --- /dev/null +++ b/.kokoro/lint/presubmit.cfg.disabled @@ -0,0 +1,21 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.10/presubmit.cfg.disabled b/.kokoro/python3.10/presubmit.cfg.disabled new file mode 100644 index 00000000000..158c832fcd5 --- /dev/null +++ b/.kokoro/python3.10/presubmit.cfg.disabled @@ -0,0 +1,21 @@ +# Copyright 2021 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.11/presubmit.cfg.disabled b/.kokoro/python3.11/presubmit.cfg.disabled new file mode 100644 index 00000000000..e2b31b88480 --- /dev/null +++ b/.kokoro/python3.11/presubmit.cfg.disabled @@ -0,0 +1,21 @@ +# Copyright 2023 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.12/presubmit.cfg.disabled b/.kokoro/python3.12/presubmit.cfg.disabled new file mode 100644 index 00000000000..e2b31b88480 --- /dev/null +++ b/.kokoro/python3.12/presubmit.cfg.disabled @@ -0,0 +1,21 @@ +# Copyright 2023 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.13/presubmit.cfg.disabled b/.kokoro/python3.13/presubmit.cfg.disabled new file mode 100644 index 00000000000..d6b8ff9c6b8 --- /dev/null +++ b/.kokoro/python3.13/presubmit.cfg.disabled @@ -0,0 +1,21 @@ +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.14/presubmit.cfg.disabled b/.kokoro/python3.14/presubmit.cfg.disabled new file mode 100644 index 00000000000..b8ecd3b0d15 --- /dev/null +++ b/.kokoro/python3.14/presubmit.cfg.disabled @@ -0,0 +1,21 @@ +# Copyright 2025 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.8/presubmit.cfg.disabled b/.kokoro/python3.8/presubmit.cfg.disabled new file mode 100644 index 00000000000..d74d307bbed --- /dev/null +++ b/.kokoro/python3.8/presubmit.cfg.disabled @@ -0,0 +1,21 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.9/presubmit.cfg.disabled b/.kokoro/python3.9/presubmit.cfg.disabled new file mode 100644 index 00000000000..d74d307bbed --- /dev/null +++ b/.kokoro/python3.9/presubmit.cfg.disabled @@ -0,0 +1,21 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} From 6bbcfd0035837f8e2dfb4ba38ccfae39b377587d Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 15:55:58 +0000 Subject: [PATCH 13/31] fix: remove re-enabled Kokoro jobs --- .kokoro/lint/presubmit.cfg | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/lint/presubmit.cfg diff --git a/.kokoro/lint/presubmit.cfg b/.kokoro/lint/presubmit.cfg deleted file mode 100644 index e6d49899414..00000000000 --- a/.kokoro/lint/presubmit.cfg +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From fea7d00030747e6df381e2b5e35ff6e397530174 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 15:56:02 +0000 Subject: [PATCH 14/31] fix: remove re-enabled Kokoro jobs --- .kokoro/python3.10/presubmit.cfg | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.10/presubmit.cfg diff --git a/.kokoro/python3.10/presubmit.cfg b/.kokoro/python3.10/presubmit.cfg deleted file mode 100644 index e6d49899414..00000000000 --- a/.kokoro/python3.10/presubmit.cfg +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From f1603f8aab50a730d6fe50364a5ba4ac4fc75b41 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 15:56:04 +0000 Subject: [PATCH 15/31] fix: remove re-enabled Kokoro jobs --- .kokoro/python3.11/presubmit.cfg | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.11/presubmit.cfg diff --git a/.kokoro/python3.11/presubmit.cfg b/.kokoro/python3.11/presubmit.cfg deleted file mode 100644 index e6d49899414..00000000000 --- a/.kokoro/python3.11/presubmit.cfg +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 80d6ee7b2d14d004a601c6e731db5a9fb741bb96 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 15:56:06 +0000 Subject: [PATCH 16/31] fix: remove re-enabled Kokoro jobs --- .kokoro/python3.12/presubmit.cfg | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.12/presubmit.cfg diff --git a/.kokoro/python3.12/presubmit.cfg b/.kokoro/python3.12/presubmit.cfg deleted file mode 100644 index e6d49899414..00000000000 --- a/.kokoro/python3.12/presubmit.cfg +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From f37b4ae1812a93778520c6c5405f84e7cba2b889 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 15:56:07 +0000 Subject: [PATCH 17/31] fix: remove re-enabled Kokoro jobs --- .kokoro/python3.13/presubmit.cfg | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.13/presubmit.cfg diff --git a/.kokoro/python3.13/presubmit.cfg b/.kokoro/python3.13/presubmit.cfg deleted file mode 100644 index e6d49899414..00000000000 --- a/.kokoro/python3.13/presubmit.cfg +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 7ecaa9474c8a66a3695889bf0a6ea7ac676099a8 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 15:56:09 +0000 Subject: [PATCH 18/31] fix: remove re-enabled Kokoro jobs --- .kokoro/python3.14/presubmit.cfg | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.14/presubmit.cfg diff --git a/.kokoro/python3.14/presubmit.cfg b/.kokoro/python3.14/presubmit.cfg deleted file mode 100644 index e6d49899414..00000000000 --- a/.kokoro/python3.14/presubmit.cfg +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 19cc3c8c81e3cd904f52147ccc895f53dccca309 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 15:56:12 +0000 Subject: [PATCH 19/31] fix: remove re-enabled Kokoro jobs --- .kokoro/python3.9/presubmit.cfg | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.9/presubmit.cfg diff --git a/.kokoro/python3.9/presubmit.cfg b/.kokoro/python3.9/presubmit.cfg deleted file mode 100644 index e6d49899414..00000000000 --- a/.kokoro/python3.9/presubmit.cfg +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 6b33ea99a4d30ac0b8ee71bc4419579662c3da62 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 15:56:17 +0000 Subject: [PATCH 20/31] fix: remove re-enabled Kokoro jobs --- .kokoro/python3.8/presubmit.cfg | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.8/presubmit.cfg diff --git a/.kokoro/python3.8/presubmit.cfg b/.kokoro/python3.8/presubmit.cfg deleted file mode 100644 index e6d49899414..00000000000 --- a/.kokoro/python3.8/presubmit.cfg +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2026 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 04f4b83eb38a2fa8ef6da63fc69ad3cbbcce312d Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 16:52:36 +0000 Subject: [PATCH 21/31] fix: re-enable Kokoro lint config to fix 'file not found' CI failure --- .kokoro/lint/presubmit.cfg | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 .kokoro/lint/presubmit.cfg diff --git a/.kokoro/lint/presubmit.cfg b/.kokoro/lint/presubmit.cfg new file mode 100644 index 00000000000..d74d307bbed --- /dev/null +++ b/.kokoro/lint/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} From 3869fe1e1bd9989cc23768a699a141b4a204f0c4 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 16:52:51 +0000 Subject: [PATCH 22/31] fix: re-enable Kokoro python presubmit configs to fix 'file not found' CI failures --- .kokoro/python3.11/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.12/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.13/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.8/presubmit.cfg | 21 +++++++++++++++++++++ .kokoro/python3.9/presubmit.cfg | 21 +++++++++++++++++++++ 5 files changed, 105 insertions(+) create mode 100644 .kokoro/python3.11/presubmit.cfg create mode 100644 .kokoro/python3.12/presubmit.cfg create mode 100644 .kokoro/python3.13/presubmit.cfg create mode 100644 .kokoro/python3.8/presubmit.cfg create mode 100644 .kokoro/python3.9/presubmit.cfg diff --git a/.kokoro/python3.11/presubmit.cfg b/.kokoro/python3.11/presubmit.cfg new file mode 100644 index 00000000000..d74d307bbed --- /dev/null +++ b/.kokoro/python3.11/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.12/presubmit.cfg b/.kokoro/python3.12/presubmit.cfg new file mode 100644 index 00000000000..d74d307bbed --- /dev/null +++ b/.kokoro/python3.12/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.13/presubmit.cfg b/.kokoro/python3.13/presubmit.cfg new file mode 100644 index 00000000000..d74d307bbed --- /dev/null +++ b/.kokoro/python3.13/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.8/presubmit.cfg b/.kokoro/python3.8/presubmit.cfg new file mode 100644 index 00000000000..d74d307bbed --- /dev/null +++ b/.kokoro/python3.8/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.9/presubmit.cfg b/.kokoro/python3.9/presubmit.cfg new file mode 100644 index 00000000000..d74d307bbed --- /dev/null +++ b/.kokoro/python3.9/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} From 23c79a23790e3f9cf0a2849806796a59dfd6d103 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 17:55:43 +0000 Subject: [PATCH 23/31] fix: re-enable all Kokoro python presubmit configs and fix lint errors --- .kokoro/python3.10/presubmit.cfg | 21 +++ .kokoro/python3.11/presubmit.cfg | 2 +- .kokoro/python3.12/presubmit.cfg | 2 +- .kokoro/python3.13/presubmit.cfg | 2 +- .kokoro/python3.14/presubmit.cfg | 21 +++ .../delete_empty_folders.py | 145 +++++++++--------- storagecontrol/managed_folder_list_test.py | 3 +- 7 files changed, 119 insertions(+), 77 deletions(-) create mode 100644 .kokoro/python3.10/presubmit.cfg create mode 100644 .kokoro/python3.14/presubmit.cfg diff --git a/.kokoro/python3.10/presubmit.cfg b/.kokoro/python3.10/presubmit.cfg new file mode 100644 index 00000000000..158c832fcd5 --- /dev/null +++ b/.kokoro/python3.10/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2021 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/.kokoro/python3.11/presubmit.cfg b/.kokoro/python3.11/presubmit.cfg index d74d307bbed..e2b31b88480 100644 --- a/.kokoro/python3.11/presubmit.cfg +++ b/.kokoro/python3.11/presubmit.cfg @@ -1,4 +1,4 @@ -# Copyright 2019 Google LLC +# Copyright 2023 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/.kokoro/python3.12/presubmit.cfg b/.kokoro/python3.12/presubmit.cfg index d74d307bbed..e2b31b88480 100644 --- a/.kokoro/python3.12/presubmit.cfg +++ b/.kokoro/python3.12/presubmit.cfg @@ -1,4 +1,4 @@ -# Copyright 2019 Google LLC +# Copyright 2023 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/.kokoro/python3.13/presubmit.cfg b/.kokoro/python3.13/presubmit.cfg index d74d307bbed..d6b8ff9c6b8 100644 --- a/.kokoro/python3.13/presubmit.cfg +++ b/.kokoro/python3.13/presubmit.cfg @@ -1,4 +1,4 @@ -# Copyright 2019 Google LLC +# Copyright 2024 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/.kokoro/python3.14/presubmit.cfg b/.kokoro/python3.14/presubmit.cfg new file mode 100644 index 00000000000..b8ecd3b0d15 --- /dev/null +++ b/.kokoro/python3.14/presubmit.cfg @@ -0,0 +1,21 @@ +# Copyright 2025 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Format: //devtools/kokoro/config/proto/build.proto + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: ".kokoro/tests/run_tests_diff_main.sh" +} diff --git a/storagecontrol/hierarchical-namespace/delete_empty_folders.py b/storagecontrol/hierarchical-namespace/delete_empty_folders.py index 2aa9d8bf054..866265c3fa9 100644 --- a/storagecontrol/hierarchical-namespace/delete_empty_folders.py +++ b/storagecontrol/hierarchical-namespace/delete_empty_folders.py @@ -7,13 +7,12 @@ # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, +# distributed under the License is distributed on an 'AS IS' BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. import concurrent.futures -import logging import threading import time @@ -22,6 +21,8 @@ from google.cloud import storage_control_v2 import grpc +import logging + ThreadPoolExecutor = concurrent.futures.ThreadPoolExecutor # This script may be used to recursively delete a large number of nested empty @@ -79,12 +80,12 @@ def _get_simple_path_and_depth(full_resource_name: str) -> tuple[str, int]: - """Extracts bucket-relative path and depth from a GCS folder resource name. + \"\"\"Extracts bucket-relative path and depth from a GCS folder resource name. - The "simple path" is relative to the bucket (e.g., 'archive/logs/' for + The \"simple path\" is relative to the bucket (e.g., 'archive/logs/' for 'projects/_/buckets/my-bucket/folders/archive/logs/'). - The "depth" is the number of '/' in the simple path (e.g. 'archive/logs/' is + The \"depth\" is the number of '/' in the simple path (e.g. 'archive/logs/' is depth 2). Args: @@ -98,42 +99,42 @@ def _get_simple_path_and_depth(full_resource_name: str) -> tuple[str, int]: ValueError: If the resource name does not match the expected format (i.e. start with 'projects/_/buckets/BUCKET_NAME/folders/FOLDER_PREFIX' and ends with a trailing slash). - """ - base_folders_prefix = f"projects/_/buckets/{BUCKET_NAME}/folders/" + \"\"\" + base_folders_prefix = f\"projects/_/buckets/{BUCKET_NAME}/folders/\" # The full prefix to validate against, including the global FOLDER_PREFIX. - # If FOLDER_PREFIX is "", this is equivalent to base_folders_prefix. + # If FOLDER_PREFIX is \"\", this is equivalent to base_folders_prefix. expected_validation_prefix = base_folders_prefix + FOLDER_PREFIX if not full_resource_name.startswith( expected_validation_prefix - ) or not full_resource_name.endswith("/"): + ) or not full_resource_name.endswith(\"/\"): raise ValueError( - f"Folder resource name '{full_resource_name}' does not match expected" - f" prefix '{expected_validation_prefix}' or missing trailing slash." + f\"Folder resource name '{full_resource_name}' does not match expected\" + f\" prefix '{expected_validation_prefix}' or missing trailing slash.\" ) simple_path = full_resource_name[len(base_folders_prefix) :] - depth = simple_path.count("/") + depth = simple_path.count(\"/\") if depth < 1: raise ValueError( - f"Folder resource name '{full_resource_name}' has invalid depth" - f" {depth} (expected at least 1)." + f\"Folder resource name '{full_resource_name}' has invalid depth\" + f\" {depth} (expected at least 1).\" ) return simple_path, depth def discover_and_partition_folders() -> None: - """Discovers all folders in the bucket and partitions them by depth. + \"\"\"Discovers all folders in the bucket and partitions them by depth. Result is stored in the global folders_by_depth dictionary. - """ - parent_resource = f"projects/_/buckets/{BUCKET_NAME}" + \"\"\" + parent_resource = f\"projects/_/buckets/{BUCKET_NAME}\" logging.info( - "Starting folder discovery and partitioning for bucket '%s'." - " Using prefix filter: '%s'.", + \"Starting folder discovery and partitioning for bucket '%s'.\" + \" Using prefix filter: '%s'.\", BUCKET_NAME, - FOLDER_PREFIX if FOLDER_PREFIX else "NONE (all folders)", + FOLDER_PREFIX if FOLDER_PREFIX else \"NONE (all folders)\", ) list_folders_request = storage_control_v2.ListFoldersRequest( @@ -152,20 +153,20 @@ def discover_and_partition_folders() -> None: num_folders_found += 1 with stats_lock: - stats["found_total"] = num_folders_found + stats[\"found_total\"] = num_folders_found except Exception as e: - logging.error("Failed to list folders: %s", e, exc_info=True) + logging.error(\"Failed to list folders: %s\", e, exc_info=True) return - logging.info("Finished discovery. Total folders found: %s.", num_folders_found) + logging.info(\"Finished discovery. Total folders found: %s.\", num_folders_found) if not folders_by_depth: - logging.info("No folders found in the bucket.") + logging.info(\"No folders found in the bucket.\") else: - logging.info("Folders partitioned by depth:") + logging.info(\"Folders partitioned by depth:\") for depth_val in sorted(folders_by_depth.keys()): logging.info( - " Depth %s: %s folders", depth_val, len(folders_by_depth[depth_val]) + \" Depth %s: %s folders\", depth_val, len(folders_by_depth[depth_val]) ) @@ -193,7 +194,7 @@ def should_retry(exception: Exception) -> int | None: def delete_folder(folder_full_resource_name: str) -> None: - """Attempts to delete a single GCS HNS folder. + \"\"\"Attempts to delete a single GCS HNS folder. Includes retry logic for transient errors. @@ -203,7 +204,7 @@ def delete_folder(folder_full_resource_name: str) -> None: folder_full_resource_name: The full resource name of the GCS folder to delete, e.g., 'projects/_/buckets/your-bucket-name/folders/path/to/folder/'. - """ + \"\"\" simple_path, _ = _get_simple_path_and_depth(folder_full_resource_name) retry_policy = retry.Retry( @@ -219,70 +220,70 @@ def delete_folder(folder_full_resource_name: str) -> None: storage_control_client.delete_folder(request=request, retry=retry_policy) with stats_lock: - stats["successful_deletes"] += 1 + stats[\"successful_deletes\"] += 1 return # Success except google_exceptions.NotFound: # This can happen if the folder was deleted by another process. logging.warning( - "Folder not found for deletion (already gone?): %s", simple_path + \"Folder not found for deletion (already gone?): %s\", simple_path ) return # Not a retriable error except google_exceptions.FailedPrecondition as e: # This typically means the folder contains objects. - logging.warning("Deletion failed for '%s': %s.", simple_path, e.message) + logging.warning(\"Deletion failed for '%s': %s.\", simple_path, e.message) with stats_lock: - stats["failed_deletes_precondition"] += 1 + stats[\"failed_deletes_precondition\"] += 1 return # Not a retriable error except Exception as e: logging.error( - "Failed to delete '%s': %s", + \"Failed to delete '%s': %s\", simple_path, e, exc_info=True, ) with stats_lock: - stats["failed_deletes_internal"] += 1 + stats[\"failed_deletes_internal\"] += 1 return # All retries exhausted # --- STATS REPORTER THREAD --- def stats_reporter_thread_logic(stop_event: threading.Event, start_time: float) -> None: - """Logs current statistics periodically.""" - logging.info("Stats Reporter: Started.") + \"\"\"Logs current statistics periodically.\"\"\" + logging.info(\"Stats Reporter: Started.\") while not stop_event.wait(STATS_REPORT_INTERVAL): with stats_lock: elapsed = time.time() - start_time - rate = stats["successful_deletes"] / elapsed if elapsed > 0 else 0 + rate = stats[\"successful_deletes\"] / elapsed if elapsed > 0 else 0 logging.info( - "[STATS] Total Folders Found: %s | Successful Deletes: %s | Failed" - " Deletes (precondition): %s | Failed Deletes (internal): %s | Rate:" - " %.2f folders/sec", - stats["found_total"], - stats["successful_deletes"], - stats["failed_deletes_precondition"], - stats["failed_deletes_internal"], + \"[STATS] Total Folders Found: %s | Successful Deletes: %s | Failed\" + \" Deletes (precondition): %s | Failed Deletes (internal): %s | Rate:\" + \" %.2f folders/sec\", + stats[\"found_total\"], + stats[\"successful_deletes\"], + stats[\"failed_deletes_precondition\"], + stats[\"failed_deletes_internal\"], rate, ) - logging.info("Stats Reporter: Shutting down.") + logging.info(\"Stats Reporter: Shutting down.\") # --- MAIN EXECUTION BLOCK --- -if __name__ == "__main__": - if BUCKET_NAME == "your-gcs-bucket-name": +if __name__ == \"__main__\": + if BUCKET_NAME == \"your-gcs-bucket-name\": print( - "\nERROR: Please update the BUCKET_NAME variable in the script before" - " running." + \"\\nERROR: Please update the BUCKET_NAME variable in the script before\" + \" running.\" ) exit(1) - if FOLDER_PREFIX and not FOLDER_PREFIX.endswith("/"): - print("\nERROR: FOLDER_PREFIX must end with a '/' if specified.") + if FOLDER_PREFIX and not FOLDER_PREFIX.endswith(\"/\"): + print(\"\\nERROR: FOLDER_PREFIX must end with a '/' if specified.\") exit(1) start_time = time.time() - logging.info("Starting GCS HNS folder deletion for bucket: %s", BUCKET_NAME) + logging.info(\"Starting GCS HNS folder deletion for bucket: %s\", BUCKET_NAME) # Event to signal threads to stop gracefully. stop_event = threading.Event() @@ -291,7 +292,7 @@ def stats_reporter_thread_logic(stop_event: threading.Event, start_time: float) stats_thread = threading.Thread( target=stats_reporter_thread_logic, args=(stop_event, start_time), - name="StatsReporter", + name=\"StatsReporter\", daemon=True, ) stats_thread.start() @@ -300,12 +301,12 @@ def stats_reporter_thread_logic(stop_event: threading.Event, start_time: float) discover_and_partition_folders() if not folders_by_depth: - logging.info("No folders found to delete. Exiting.") + logging.info(\"No folders found to delete. Exiting.\") exit(0) # Prepare for multi-threaded deletion within each depth level. deletion_executor = ThreadPoolExecutor( - max_workers=MAX_WORKERS, thread_name_prefix="DeleteFolderWorker" + max_workers=MAX_WORKERS, thread_name_prefix=\"DeleteFolderWorker\" ) try: @@ -316,12 +317,12 @@ def stats_reporter_thread_logic(stop_event: threading.Event, start_time: float) if not folders_at_current_depth: logging.info( - "Skipping depth %s: No folders found at this depth.", current_depth + \"Skipping depth %s: No folders found at this depth.\", current_depth ) continue logging.info( - "\nProcessing depth %s: Submitting %s folders for deletion...", + \"\\nProcessing depth %s: Submitting %s folders for deletion...\", current_depth, len(folders_at_current_depth), ) @@ -337,15 +338,15 @@ def stats_reporter_thread_logic(stop_event: threading.Event, start_time: float) # tackling their parents. concurrent.futures.wait(futures) - logging.info("Finished processing all folders at depth %s.", current_depth) + logging.info(\"Finished processing all folders at depth %s.\", current_depth) except KeyboardInterrupt: logging.info( - "Main: Keyboard interrupt received. Attempting graceful shutdown..." + \"Main: Keyboard interrupt received. Attempting graceful shutdown...\" ) except Exception as e: logging.error( - "An unexpected error occurred in the main loop: %s", e, exc_info=True + \"An unexpected error occurred in the main loop: %s\", e, exc_info=True ) finally: # Signal all threads to stop. @@ -353,7 +354,7 @@ def stats_reporter_thread_logic(stop_event: threading.Event, start_time: float) # Shut down deletion executor and wait for any pending tasks to complete. logging.info( - "Main: Shutting down deletion workers. Waiting for any final tasks..." + \"Main: Shutting down deletion workers. Waiting for any final tasks...\" ) deletion_executor.shutdown(wait=True) @@ -365,23 +366,23 @@ def stats_reporter_thread_logic(stop_event: threading.Event, start_time: float) # Log final statistics. final_elapsed_time = time.time() - start_time - logging.info("\n--- FINAL SUMMARY ---") + logging.info(\"\\n--- FINAL SUMMARY ---\") with stats_lock: final_rate = ( - stats["successful_deletes"] / final_elapsed_time + stats[\"successful_deletes\"] / final_elapsed_time if final_elapsed_time > 0 else 0 ) logging.info( - " - Total Folders Found (Initial Scan): %s\n - Successful Folder" - " Deletes: %s\n - Failed Folder Deletes (Precondition): %s\n -" - " Failed Folder Deletes (Internal): %s\n - Total Runtime: %.2f" - " seconds\n - Average Deletion Rate: %.2f folders/sec", - stats["found_total"], - stats["successful_deletes"], - stats["failed_deletes_precondition"], - stats["failed_deletes_internal"], + \" - Total Folders Found (Initial Scan): %s\\n - Successful Folder\" + \" Deletes: %s\\n - Failed Folder Deletes (Precondition): %s\\n -\" + \" Failed Folder Deletes (Internal): %s\\n - Total Runtime: %.2f\" + \" seconds\\n - Average Deletion Rate: %.2f folders/sec\", + stats[\"found_total\"], + stats[\"successful_deletes\"], + stats[\"failed_deletes_precondition\"], + stats[\"failed_deletes_internal\"], final_elapsed_time, final_rate, ) - logging.info("Script execution finished.") + logging.info(\"Script execution finished.\") diff --git a/storagecontrol/managed_folder_list_test.py b/storagecontrol/managed_folder_list_test.py index e0cb30170c8..c183dc036eb 100644 --- a/storagecontrol/managed_folder_list_test.py +++ b/storagecontrol/managed_folder_list_test.py @@ -14,9 +14,8 @@ from google.cloud import storage -import pytest - import managed_folder_list +import pytest def test_storage_control_managed_folder_list( From 970395b1061ecb8124f134e36f610b3569ac0137 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 17:55:47 +0000 Subject: [PATCH 24/31] fix: re-enable all Kokoro python presubmit configs and fix lint errors --- .kokoro/lint/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/lint/presubmit.cfg.disabled diff --git a/.kokoro/lint/presubmit.cfg.disabled b/.kokoro/lint/presubmit.cfg.disabled deleted file mode 100644 index d74d307bbed..00000000000 --- a/.kokoro/lint/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 0518d3cf206fc6d3a91b6a500e9b98d15ce697ba Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 17:55:50 +0000 Subject: [PATCH 25/31] fix: re-enable all Kokoro python presubmit configs and fix lint errors --- .kokoro/python3.10/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.10/presubmit.cfg.disabled diff --git a/.kokoro/python3.10/presubmit.cfg.disabled b/.kokoro/python3.10/presubmit.cfg.disabled deleted file mode 100644 index 158c832fcd5..00000000000 --- a/.kokoro/python3.10/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2021 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From f10525d250ed454a88ae87cdb84d796b49243a88 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 17:55:53 +0000 Subject: [PATCH 26/31] fix: re-enable all Kokoro python presubmit configs and fix lint errors --- .kokoro/python3.11/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.11/presubmit.cfg.disabled diff --git a/.kokoro/python3.11/presubmit.cfg.disabled b/.kokoro/python3.11/presubmit.cfg.disabled deleted file mode 100644 index e2b31b88480..00000000000 --- a/.kokoro/python3.11/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2023 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From d17b7d8684f0daddb0ede8a18a5ea775167bd74c Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 17:55:56 +0000 Subject: [PATCH 27/31] fix: re-enable all Kokoro python presubmit configs and fix lint errors --- .kokoro/python3.12/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.12/presubmit.cfg.disabled diff --git a/.kokoro/python3.12/presubmit.cfg.disabled b/.kokoro/python3.12/presubmit.cfg.disabled deleted file mode 100644 index e2b31b88480..00000000000 --- a/.kokoro/python3.12/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2023 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 44d62b56237d4a2d42f2f172b47906c9cc980c94 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 17:56:00 +0000 Subject: [PATCH 28/31] fix: re-enable all Kokoro python presubmit configs and fix lint errors --- .kokoro/python3.13/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.13/presubmit.cfg.disabled diff --git a/.kokoro/python3.13/presubmit.cfg.disabled b/.kokoro/python3.13/presubmit.cfg.disabled deleted file mode 100644 index d6b8ff9c6b8..00000000000 --- a/.kokoro/python3.13/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2024 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 1fd48e0f93b32f4c59297f60ff855c3bf295b4c8 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 17:56:03 +0000 Subject: [PATCH 29/31] fix: re-enable all Kokoro python presubmit configs and fix lint errors --- .kokoro/python3.14/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.14/presubmit.cfg.disabled diff --git a/.kokoro/python3.14/presubmit.cfg.disabled b/.kokoro/python3.14/presubmit.cfg.disabled deleted file mode 100644 index b8ecd3b0d15..00000000000 --- a/.kokoro/python3.14/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2025 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From 304832d5102f0e58eb84b2b3f7556d6850fb78f0 Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 17:56:06 +0000 Subject: [PATCH 30/31] fix: re-enable all Kokoro python presubmit configs and fix lint errors --- .kokoro/python3.8/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.8/presubmit.cfg.disabled diff --git a/.kokoro/python3.8/presubmit.cfg.disabled b/.kokoro/python3.8/presubmit.cfg.disabled deleted file mode 100644 index d74d307bbed..00000000000 --- a/.kokoro/python3.8/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -} From e6e592e94db3cc079c61b8e9d9665e1e626463ae Mon Sep 17 00:00:00 2001 From: Nidhi Date: Sun, 5 Jul 2026 17:56:10 +0000 Subject: [PATCH 31/31] fix: re-enable all Kokoro python presubmit configs and fix lint errors --- .kokoro/python3.9/presubmit.cfg.disabled | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 .kokoro/python3.9/presubmit.cfg.disabled diff --git a/.kokoro/python3.9/presubmit.cfg.disabled b/.kokoro/python3.9/presubmit.cfg.disabled deleted file mode 100644 index d74d307bbed..00000000000 --- a/.kokoro/python3.9/presubmit.cfg.disabled +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Format: //devtools/kokoro/config/proto/build.proto - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: ".kokoro/tests/run_tests_diff_main.sh" -}