From 620200510b11c2cc87658ab81894c99e8a64170f Mon Sep 17 00:00:00 2001 From: Sandro Mani Date: Thu, 11 Jan 2024 14:57:14 +0100 Subject: [PATCH] Improve datasource service parsing regex --- src/config_generator/qgs_reader.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/config_generator/qgs_reader.py b/src/config_generator/qgs_reader.py index 48b8c6a..25b1712 100644 --- a/src/config_generator/qgs_reader.py +++ b/src/config_generator/qgs_reader.py @@ -193,7 +193,7 @@ def __db_connection(self, datasource): if 'service=' in datasource: # PostgreSQL connection service - m = re.search(r"service='([\w ]+)'", datasource) + m = re.search(r"service='([^']+)'", datasource) if m is not None: connection_string = 'postgresql:///?service=%s' % m.group(1)