From 661d56074c8c831d125698eb872a68f30f91e8ba Mon Sep 17 00:00:00 2001 From: Christian Manivong Date: Mon, 20 Jul 2026 09:47:39 +0200 Subject: [PATCH] refactor(warnings): report raw signal only, no severity/presentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit get_device_warnings() now returns only {code, meta} — severity, title, message, and action are resolved centrally by netork's WARNING_CATALOG (netork/core/device_warnings.py), not by the driver. Keeps this driver independent of netork and avoids per-vendor drift in how the same warning code is presented. --- napalm_linux/linux.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/napalm_linux/linux.py b/napalm_linux/linux.py index 6f23b5f..897f1d3 100644 --- a/napalm_linux/linux.py +++ b/napalm_linux/linux.py @@ -1052,8 +1052,6 @@ class LinuxDriver(OSDriver): if updates: warnings.append({ "code": "updates_available", - "severity": "warning", - "action": None, "meta": { "count": len(updates), "packages": [u.get("name", "") for u in updates], @@ -1065,8 +1063,6 @@ class LinuxDriver(OSDriver): if self._apt_proxy_url not in current: warnings.append({ "code": "apt_proxy_missing", - "severity": "warning", - "action": "fix_apt_proxy", "meta": {"expected_url": self._apt_proxy_url}, }) except Exception as exc: