From 6a76fdfa824d78f0598c5417e7ad98db6f95dbaf Mon Sep 17 00:00:00 2001 From: Minh Vu Date: Thu, 25 Jun 2026 19:28:11 +0200 Subject: [PATCH] Avoid throttler access when RequestResponseIO has no throttler --- sdks/python/apache_beam/io/requestresponse.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sdks/python/apache_beam/io/requestresponse.py b/sdks/python/apache_beam/io/requestresponse.py index 9fdf33e2299d..0677efbac000 100644 --- a/sdks/python/apache_beam/io/requestresponse.py +++ b/sdks/python/apache_beam/io/requestresponse.py @@ -375,7 +375,8 @@ def process(self, request: RequestT, *args, **kwargs): response = self._repeater.repeat( self._caller, request, self._timeout, self._metrics_collector) self._metrics_collector.responses.inc(1) - self._throttler.throttler.successful_request(req_time * MSEC_TO_SEC) + if self._throttler: + self._throttler.throttler.successful_request(req_time * MSEC_TO_SEC) yield response except Exception as e: raise e