get_config: the REST-to-SSH fallback never reads the startup config and ignores retrieve #25

Closed
opened 2026-11-02 08:12:45 +00:00 by christianmanivong · 0 comments
Owner

What happens

get_config on the REST transport (napalm_procurve/procurve.py ~633-645) falls back to SSH when the REST endpoint has no running config, and then returns

running = self._get_config_via_ssh()
return {"running": running, "startup": "", "candidate": ""}

The startup config is never read on that path, so it reads as an empty startup config; retrieve is ignored as well (a retrieve="startup" call gets the running config read and an empty startup). The SSH transport further down reads both (show startup-config / show config).

Expected

The SSH fallback honours retrieve like the SSH transport: running and/or startup are read as asked; a part that was not asked for is "", a part that was asked for and could not be read raises. Test-first: REST without a running config + retrieve="all" returns the SSH startup config.

Priority: P4 — an empty startup config for 2530/YA-series switches on the REST transport.

Found during the bug sweep of 2026-11-02 (#22).

## What happens `get_config` on the REST transport (`napalm_procurve/procurve.py` ~633-645) falls back to SSH when the REST endpoint has no running config, and then returns ```python running = self._get_config_via_ssh() return {"running": running, "startup": "", "candidate": ""} ``` The startup config is never read on that path, so it reads as an empty startup config; `retrieve` is ignored as well (a `retrieve="startup"` call gets the running config read and an empty startup). The SSH transport further down reads both (`show startup-config` / `show config`). ## Expected The SSH fallback honours `retrieve` like the SSH transport: running and/or startup are read as asked; a part that was not asked for is `""`, a part that was asked for and could not be read raises. Test-first: REST without a running config + `retrieve="all"` returns the SSH startup config. Priority: P4 — an empty startup config for 2530/YA-series switches on the REST transport. Found during the bug sweep of 2026-11-02 (#22).
christianmanivong added the
prio
P4
bug
labels 2026-11-02 08:12:45 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: NAPALM/napalm-hpe-aruba-procurve#25