all lists on lists.proxmox.com
 help / color / mirror / Atom feed
From: "Max R. Carrara" <m.carrara@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH v1 master ceph 2/2] provide another fix that silences invalid escape sequence warning
Date: Thu, 17 Jul 2025 17:36:25 +0200	[thread overview]
Message-ID: <20250717153625.391842-3-m.carrara@proxmox.com> (raw)
In-Reply-To: <20250717153625.391842-1-m.carrara@proxmox.com>

See the added patch for additional details.

Signed-off-by: Max R. Carrara <m.carrara@proxmox.com>
---
 ...-zabbix-fix-invalid-escape-sequences.patch | 29 +++++++++++++++++++
 patches/series                                |  1 +
 2 files changed, 30 insertions(+)
 create mode 100644 patches/0061-mgr-zabbix-fix-invalid-escape-sequences.patch

diff --git a/patches/0061-mgr-zabbix-fix-invalid-escape-sequences.patch b/patches/0061-mgr-zabbix-fix-invalid-escape-sequences.patch
new file mode 100644
index 0000000000..9c405d28e1
--- /dev/null
+++ b/patches/0061-mgr-zabbix-fix-invalid-escape-sequences.patch
@@ -0,0 +1,29 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: "Max R. Carrara" <m.carrara@proxmox.com>
+Date: Thu, 17 Jul 2025 17:20:08 +0200
+Subject: [PATCH 61/61] mgr/zabbix: fix invalid escape sequences
+
+Even though the `zabbix` module is deprecated and will be removed
+soon [1], fix the warning regarding invalid escape sequences here
+also, as it might look scary for some users.
+
+[1]: https://github.com/ceph/ceph/pull/57299
+
+Signed-off-by: Max R. Carrara <m.carrara@proxmox.com>
+---
+ src/pybind/mgr/zabbix/module.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/pybind/mgr/zabbix/module.py b/src/pybind/mgr/zabbix/module.py
+index 638b688562f..2e348ab0391 100644
+--- a/src/pybind/mgr/zabbix/module.py
++++ b/src/pybind/mgr/zabbix/module.py
+@@ -131,7 +131,7 @@ class Module(MgrModule):
+         self._zabbix_hosts = list()
+         servers = cast(str, self.config['zabbix_host']).split(",")
+         for server in servers:
+-            uri = re.match("(?:(?:\[?)([a-z0-9-\.]+|[a-f0-9:\.]+)(?:\]?))(?:((?::))([0-9]{1,5}))?$", server)
++            uri = re.match(r"(?:(?:\[?)([a-z0-9-\.]+|[a-f0-9:\.]+)(?:\]?))(?:((?::))([0-9]{1,5}))?$", server)
+             if uri:
+                 zabbix_host, sep, opt_zabbix_port = uri.groups()
+                 if sep == ':':
diff --git a/patches/series b/patches/series
index d6c765677d..a2e222551c 100644
--- a/patches/series
+++ b/patches/series
@@ -54,3 +54,4 @@
 0058-pybind-mgr-restful-provide-workaround-for-PyO3-Impor.patch
 0059-mgr-fix-module-import-by-making-NOTIFY_TYPES-in-py-m.patch
 0060-mgr-osd_perf_query-fix-ivalid-escape-sequence.patch
+0061-mgr-zabbix-fix-invalid-escape-sequences.patch
-- 
2.39.5



_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


  parent reply	other threads:[~2025-07-17 15:36 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-17 15:36 [pve-devel] [PATCH v1 master ceph 0/2] Silence Some More Ceph Warnings Max R. Carrara
2025-07-17 15:36 ` [pve-devel] [PATCH v1 master ceph 1/2] cherry-pick fix that silences invalid escape sequence warning Max R. Carrara
2025-07-17 15:36 ` Max R. Carrara [this message]
2025-07-28 14:38 ` [pve-devel] [PATCH v1 master ceph 0/2] Silence Some More Ceph Warnings Thomas Lamprecht

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250717153625.391842-3-m.carrara@proxmox.com \
    --to=m.carrara@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal