public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
* [pve-devel] [PATCH v1 master ceph 0/2] Silence Some More Ceph Warnings
@ 2025-07-17 15:36 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
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Max R. Carrara @ 2025-07-17 15:36 UTC (permalink / raw)
  To: pve-devel

Silence Some More Ceph Warnings - v1
====================================

These two simple patches silence some warnings regarding invalid escape
sequences. Simply using raw strings and therefore avoiding any
(unintentional) escaping fixes this.

Summary of Changes
------------------

Max R. Carrara (2):
  cherry-pick fix that silences invalid escape sequence warning
  provide another fix that silences invalid escape sequence warning

 ...erf_query-fix-ivalid-escape-sequence.patch | 31 +++++++++++++++++++
 ...-zabbix-fix-invalid-escape-sequences.patch | 29 +++++++++++++++++
 patches/series                                |  2 ++
 3 files changed, 62 insertions(+)
 create mode 100644 patches/0060-mgr-osd_perf_query-fix-ivalid-escape-sequence.patch
 create mode 100644 patches/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


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [pve-devel] [PATCH v1 master ceph 1/2] cherry-pick fix that silences invalid escape sequence warning
  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 ` Max R. Carrara
  2025-07-17 15:36 ` [pve-devel] [PATCH v1 master ceph 2/2] provide another " Max R. Carrara
  2025-07-28 14:38 ` [pve-devel] [PATCH v1 master ceph 0/2] Silence Some More Ceph Warnings Thomas Lamprecht
  2 siblings, 0 replies; 4+ messages in thread
From: Max R. Carrara @ 2025-07-17 15:36 UTC (permalink / raw)
  To: pve-devel

Cherry-pick 1458405b, which fixes a warning regarding an invalid
escape sequence that might worry / annoy some users.

See the added patch for all details.

Thanks to Shannon Sterz for finding the commit upstream!

Signed-off-by: Max R. Carrara <m.carrara@proxmox.com>
---
 ...erf_query-fix-ivalid-escape-sequence.patch | 31 +++++++++++++++++++
 patches/series                                |  1 +
 2 files changed, 32 insertions(+)
 create mode 100644 patches/0060-mgr-osd_perf_query-fix-ivalid-escape-sequence.patch

diff --git a/patches/0060-mgr-osd_perf_query-fix-ivalid-escape-sequence.patch b/patches/0060-mgr-osd_perf_query-fix-ivalid-escape-sequence.patch
new file mode 100644
index 0000000000..8cca6f947b
--- /dev/null
+++ b/patches/0060-mgr-osd_perf_query-fix-ivalid-escape-sequence.patch
@@ -0,0 +1,31 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Kyr Shatskyy <kyrylo.shatskyy@clyso.com>
+Date: Tue, 23 Jul 2024 19:40:23 +0200
+Subject: [PATCH] mgr/osd_perf_query: fix ivalid escape sequence
+
+Get rid of warning which, according [1], is going to become an error:
+
+osd_perf_query/module.py:61
+  /home/jenkins-build/build/workspace/ceph-pull-requests/src/pybind/mgr/osd_perf_query/module.py:61: DeprecationWarning: invalid escape sequence '\.'
+    'regex': '^(?:rbd|journal)_data\.(?:([0-9]+)\.)?([^.]+)\.'},
+
+1. https://docs.python.org/3/library/re.html
+
+Signed-off-by: Kyr Shatskyy <kyrylo.shatskyy@clyso.com>
+---
+ src/pybind/mgr/osd_perf_query/module.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/pybind/mgr/osd_perf_query/module.py b/src/pybind/mgr/osd_perf_query/module.py
+index 6f87c1d907a..ac32f804282 100644
+--- a/src/pybind/mgr/osd_perf_query/module.py
++++ b/src/pybind/mgr/osd_perf_query/module.py
+@@ -58,7 +58,7 @@ class OSDPerfQuery(MgrModule):
+         'key_descriptor': [
+             {'type': 'pool_id', 'regex': '^(.+)$'},
+             {'type': 'object_name',
+-             'regex': '^(?:rbd|journal)_data\.(?:([0-9]+)\.)?([^.]+)\.'},
++             'regex': r'^(?:rbd|journal)_data\.(?:([0-9]+)\.)?([^.]+)\.'},
+         ],
+         'performance_counter_descriptors': [
+             'bytes', 'write_ops', 'read_ops', 'write_bytes', 'read_bytes',
diff --git a/patches/series b/patches/series
index b820614566..d6c765677d 100644
--- a/patches/series
+++ b/patches/series
@@ -53,3 +53,4 @@
 0057-mgr-dashboard-add-an-option-to-control-the-dashboard.patch
 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
-- 
2.39.5



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


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [pve-devel] [PATCH v1 master ceph 2/2] provide another fix that silences invalid escape sequence warning
  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
  2025-07-28 14:38 ` [pve-devel] [PATCH v1 master ceph 0/2] Silence Some More Ceph Warnings Thomas Lamprecht
  2 siblings, 0 replies; 4+ messages in thread
From: Max R. Carrara @ 2025-07-17 15:36 UTC (permalink / raw)
  To: pve-devel

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


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [pve-devel] [PATCH v1 master ceph 0/2] Silence Some More Ceph Warnings
  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 ` [pve-devel] [PATCH v1 master ceph 2/2] provide another " Max R. Carrara
@ 2025-07-28 14:38 ` Thomas Lamprecht
  2 siblings, 0 replies; 4+ messages in thread
From: Thomas Lamprecht @ 2025-07-28 14:38 UTC (permalink / raw)
  To: pve-devel, Max R. Carrara

On Thu, 17 Jul 2025 17:36:23 +0200, Max R. Carrara wrote:
> Silence Some More Ceph Warnings - v1
> ====================================
> 
> These two simple patches silence some warnings regarding invalid escape
> sequences. Simply using raw strings and therefore avoiding any
> (unintentional) escaping fixes this.
> 
> [...]

Applied, thanks!

[1/2] cherry-pick fix that silences invalid escape sequence warning
      commit: f7761df6df3e06bf370444e6b933e473835d8db6
[2/2] provide another fix that silences invalid escape sequence warning
      commit: 263b54db826549290c612a08dd5ff2b17204e5d0


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


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2025-07-28 14:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
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 ` [pve-devel] [PATCH v1 master ceph 2/2] provide another " Max R. Carrara
2025-07-28 14:38 ` [pve-devel] [PATCH v1 master ceph 0/2] Silence Some More Ceph Warnings Thomas Lamprecht

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal