From 2b2936b181e945fcbba5c279c765bd4ce73c13d6 Mon Sep 17 00:00:00 2001 From: jrmccluskey Date: Tue, 21 Jul 2026 19:38:58 +0000 Subject: [PATCH] Fix pyrefly check bad-context-manager --- .../python/apache_beam/runners/interactive/recording_manager.py | 2 +- sdks/python/pyproject.toml | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/sdks/python/apache_beam/runners/interactive/recording_manager.py b/sdks/python/apache_beam/runners/interactive/recording_manager.py index c19b60b64fd2..cabcca558dca 100644 --- a/sdks/python/apache_beam/runners/interactive/recording_manager.py +++ b/sdks/python/apache_beam/runners/interactive/recording_manager.py @@ -105,7 +105,7 @@ def _cancel_clicked(self, b): self.cancel() def update_display(self, msg: str, progress: Optional[float] = None): - if not IS_IPYTHON: + if not IS_IPYTHON or self._output_widget is None: print(f'AsyncCompute: {msg}') return diff --git a/sdks/python/pyproject.toml b/sdks/python/pyproject.toml index 52f713466246..5d78db863366 100644 --- a/sdks/python/pyproject.toml +++ b/sdks/python/pyproject.toml @@ -213,7 +213,6 @@ invalid-inheritance = "ignore" not-iterable = "ignore" unexpected-keyword = "ignore" bad-specialization = "ignore" -bad-context-manager = "ignore" invalid-yield = "ignore" bad-argument-count = "ignore" bad-typed-dict-key = "ignore"