From 7dd591320419073eba4d556f2f0c3b75062e4b73 Mon Sep 17 00:00:00 2001 From: Tom White Date: Mon, 26 Jan 2026 16:40:45 +0000 Subject: [PATCH] Ignore Beam deprecation warning in tests --- cubed/tests/utils.py | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/cubed/tests/utils.py b/cubed/tests/utils.py index b4cc4ad9d..974bc27e8 100644 --- a/cubed/tests/utils.py +++ b/cubed/tests/utils.py @@ -1,4 +1,5 @@ import platform +import warnings from collections import Counter from typing import Iterable @@ -36,12 +37,15 @@ MAIN_EXECUTORS.append(create_executor("processes")) try: - ALL_EXECUTORS.append( - create_executor("beam", executor_options=dict(runner="FnApiRunner")) - ) - MAIN_EXECUTORS.append( - create_executor("beam", executor_options=dict(runner="FnApiRunner")) - ) + with warnings.catch_warnings(): + # workaround for problem reported in https://github.com/apache/beam/pull/37034 + warnings.filterwarnings("ignore", category=DeprecationWarning) + ALL_EXECUTORS.append( + create_executor("beam", executor_options=dict(runner="FnApiRunner")) + ) + MAIN_EXECUTORS.append( + create_executor("beam", executor_options=dict(runner="FnApiRunner")) + ) except ImportError: pass