From 643282b7dcfbf0ac1b4dcf6ed314dad958965685 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 5 Dec 2025 20:23:23 +0000 Subject: [PATCH 1/5] Skip spannerio tests that depend on emulator on dataflowrunner --- .../beam_PostCommit_Python_Xlang_Gcp_Dataflow.json | 2 +- .../beam_PostCommit_Python_Xlang_Gcp_Direct.json | 2 +- .../apache_beam/io/gcp/tests/xlang_spannerio_it_test.py | 3 +++ sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py | 5 +++++ 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/trigger_files/beam_PostCommit_Python_Xlang_Gcp_Dataflow.json b/.github/trigger_files/beam_PostCommit_Python_Xlang_Gcp_Dataflow.json index 99a8fc8ff6d5..bb5da04014ec 100644 --- a/.github/trigger_files/beam_PostCommit_Python_Xlang_Gcp_Dataflow.json +++ b/.github/trigger_files/beam_PostCommit_Python_Xlang_Gcp_Dataflow.json @@ -1,4 +1,4 @@ { "comment": "Modify this file in a trivial way to cause this test suite to run", - "modification": 14 + "modification": 15 } diff --git a/.github/trigger_files/beam_PostCommit_Python_Xlang_Gcp_Direct.json b/.github/trigger_files/beam_PostCommit_Python_Xlang_Gcp_Direct.json index 99a8fc8ff6d5..bb5da04014ec 100644 --- a/.github/trigger_files/beam_PostCommit_Python_Xlang_Gcp_Direct.json +++ b/.github/trigger_files/beam_PostCommit_Python_Xlang_Gcp_Direct.json @@ -1,4 +1,4 @@ { "comment": "Modify this file in a trivial way to cause this test suite to run", - "modification": 14 + "modification": 15 } diff --git a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py index b5d5304245c4..c7274b3a959d 100644 --- a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py +++ b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py @@ -103,6 +103,9 @@ def setUpClass(cls): ) pipeline = TestPipeline(is_integration_test=True) + runner_name = type(pipeline.runner).__name__ + if 'DataflowRunner' in runner_name: + cls.skipTest("Spanner emulator not compatible with dataflow runner.") argv = pipeline.get_full_options_as_args() known_args, _ = parser.parse_known_args(argv) diff --git a/sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py b/sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py index ab9a982a81f7..2908afd176a4 100644 --- a/sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py +++ b/sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py @@ -138,6 +138,11 @@ class SpannerVectorWriterTest(unittest.TestCase): @classmethod def setUpClass(cls): """Set up Spanner emulator for all tests.""" + pipeline = TestPipeline(is_integration_test=True) + runner_name = type(pipeline.runner).__name__ + if 'DataflowRunner' in runner_name: + cls.skipTest("Spanner emulator not compatible with dataflow runner.") + cls.project_id = 'test-project' cls.instance_id = 'test-instance' cls.table_name = 'embeddings' From 186e6acd6bb62f2fe0be3d579dde8e6e5c962389 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 5 Dec 2025 20:48:00 +0000 Subject: [PATCH 2/5] Fix skips. --- sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py | 2 +- sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py index c7274b3a959d..f3a89e869c04 100644 --- a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py +++ b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py @@ -105,7 +105,7 @@ def setUpClass(cls): pipeline = TestPipeline(is_integration_test=True) runner_name = type(pipeline.runner).__name__ if 'DataflowRunner' in runner_name: - cls.skipTest("Spanner emulator not compatible with dataflow runner.") + pytest.skip("Spanner emulator not compatible with dataflow runner.") argv = pipeline.get_full_options_as_args() known_args, _ = parser.parse_known_args(argv) diff --git a/sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py b/sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py index 2908afd176a4..c371d6fd96b4 100644 --- a/sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py +++ b/sdks/python/apache_beam/ml/rag/ingestion/spanner_it_test.py @@ -141,7 +141,7 @@ def setUpClass(cls): pipeline = TestPipeline(is_integration_test=True) runner_name = type(pipeline.runner).__name__ if 'DataflowRunner' in runner_name: - cls.skipTest("Spanner emulator not compatible with dataflow runner.") + pytest.skip("Spanner emulator not compatible with dataflow runner.") cls.project_id = 'test-project' cls.instance_id = 'test-instance' From 1d7283e3a038b0a8a479a198ee60db26bd851797 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 5 Dec 2025 21:17:50 +0000 Subject: [PATCH 3/5] Fix indent. --- sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py index f3a89e869c04..01e20c4b22b1 100644 --- a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py +++ b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py @@ -105,7 +105,7 @@ def setUpClass(cls): pipeline = TestPipeline(is_integration_test=True) runner_name = type(pipeline.runner).__name__ if 'DataflowRunner' in runner_name: - pytest.skip("Spanner emulator not compatible with dataflow runner.") + pytest.skip("Spanner emulator not compatible with dataflow runner.") argv = pipeline.get_full_options_as_args() known_args, _ = parser.parse_known_args(argv) From cbda69b94ea726ab8dc5a4e8a439312c441d3945 Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 7 Dec 2025 15:12:58 -0500 Subject: [PATCH 4/5] Format. --- sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py | 1 + 1 file changed, 1 insertion(+) diff --git a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py index 01e20c4b22b1..8dce65de6edc 100644 --- a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py +++ b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py @@ -103,6 +103,7 @@ def setUpClass(cls): ) pipeline = TestPipeline(is_integration_test=True) + runner_name = type(pipeline.runner).__name__ if 'DataflowRunner' in runner_name: pytest.skip("Spanner emulator not compatible with dataflow runner.") From c6fc698dce3f46faf0cbcbd200c79fe7071aa24c Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 7 Dec 2025 16:11:14 -0500 Subject: [PATCH 5/5] Format. --- sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py | 1 + 1 file changed, 1 insertion(+) diff --git a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py index 8dce65de6edc..3fe56540847e 100644 --- a/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py +++ b/sdks/python/apache_beam/io/gcp/tests/xlang_spannerio_it_test.py @@ -107,6 +107,7 @@ def setUpClass(cls): runner_name = type(pipeline.runner).__name__ if 'DataflowRunner' in runner_name: pytest.skip("Spanner emulator not compatible with dataflow runner.") + argv = pipeline.get_full_options_as_args() known_args, _ = parser.parse_known_args(argv)