This is an automated email from the ASF dual-hosted git repository.

lhotari pushed a commit to branch branch-3.0
in repository https://gitbox.apache.org/repos/asf/pulsar.git

commit 2669c99f94965fc9dd6db0687688083a472a6aaa
Author: Lari Hotari <[email protected]>
AuthorDate: Tue May 13 19:33:29 2025 +0300

    [fix][io] Fix SyntaxWarning in Pulsar Python functions (#24297)
    
    (cherry picked from commit 272acfb483f3554155a121cafdbb6c4321539f9a)
---
 pulsar-functions/instance/src/main/python/contextimpl.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pulsar-functions/instance/src/main/python/contextimpl.py 
b/pulsar-functions/instance/src/main/python/contextimpl.py
index bfe7b23927b..826ad65b2e0 100755
--- a/pulsar-functions/instance/src/main/python/contextimpl.py
+++ b/pulsar-functions/instance/src/main/python/contextimpl.py
@@ -210,7 +210,7 @@ class ContextImpl(pulsar.Context):
       topic_consumer = self.consumers[topic]
     else:
       # if this topic is a partitioned topic
-      m = re.search('(.+)-partition-(\d+)', topic)
+      m = re.search(r'(.+)-partition-(\d+)', topic)
       if not m:
         raise ValueError('Invalid topicname %s' % topic)
       elif m.group(1) in self.consumers:

Reply via email to