chore: adopt the NAPALM driver standard #11

Merged
christianmanivong merged 3 commits from chore/driver-standard into main 2026-10-23 14:46:42 +00:00
Owner

Summary

napalm-qnap-qts adopts the NAPALM driver standard (https://git.netork.io/NAPALM/driver-standard).
Epic: NAPALM/driver-standard#2.

Changes

  • style: ruff format and ruff check --fix with the standard's rule set (E, F, I, UP, B, line length 100, Python 3.10); only test formatting changed.
  • fix: none needed: no ruff finding was left after the autofix, and bandit is clean on the package.
  • chore: CI in .gitea/workflows/ci.yml calling the shared workflow (napalm-device-types and napalm-linux from git until napalm-linux 0.15.0 is on PyPI); .github/ removed; requires-python >=3.10, SPDX license, setuptools>=77, py.typed, LICENSE; dependencies napalm-device-types>=4.22.0, napalm-linux>=0.15.0, with napalm>=4.0, netmiko>=4.0.0, paramiko>=5.0.0 kept; Issues and Changelog URLs. mypy strict for the whole package with no exempt module: install_package and uninstall_package keep napalm-device-types' PackagesMixin signatures, which napalm-linux's LinuxDriver differs from, so those two lines carry type: ignore[override] with the reason. Coverage floor 76 % (measured 76.19 %).

CI needs napalm-linux 0.15.0 on its main branch (NAPALM/napalm-linux#38) or on PyPI: until then the git pre-install gets 0.14.0 and the install of this package cannot resolve napalm-linux>=0.15.0.

Related Issue

Closes #10

Testing

Locally: 45 tests (1 xfail), coverage 76.19 %, ruff, mypy, bandit clean; lowest versions ok on Python 3.10 (napalm-linux 0.15.0 from its PR branch; also with napalm 4.0.0, netmiko 4.0.0, paramiko 5.0.0); napalm-standard check and ratchet clean; build + twine check --strict pass.

## Summary napalm-qnap-qts adopts the NAPALM driver standard (https://git.netork.io/NAPALM/driver-standard). Epic: NAPALM/driver-standard#2. ## Changes - **style**: ruff format and `ruff check --fix` with the standard's rule set (E, F, I, UP, B, line length 100, Python 3.10); only test formatting changed. - **fix**: none needed: no ruff finding was left after the autofix, and bandit is clean on the package. - **chore**: CI in `.gitea/workflows/ci.yml` calling the shared workflow (napalm-device-types and napalm-linux from git until napalm-linux 0.15.0 is on PyPI); `.github/` removed; requires-python >=3.10, SPDX license, setuptools>=77, `py.typed`, LICENSE; dependencies napalm-device-types>=4.22.0, napalm-linux>=0.15.0, with napalm>=4.0, netmiko>=4.0.0, paramiko>=5.0.0 kept; Issues and Changelog URLs. mypy strict for the whole package with no exempt module: `install_package` and `uninstall_package` keep napalm-device-types' `PackagesMixin` signatures, which napalm-linux's `LinuxDriver` differs from, so those two lines carry `type: ignore[override]` with the reason. Coverage floor 76 % (measured 76.19 %). CI needs napalm-linux 0.15.0 on its main branch (NAPALM/napalm-linux#38) or on PyPI: until then the git pre-install gets 0.14.0 and the install of this package cannot resolve `napalm-linux>=0.15.0`. ## Related Issue Closes #10 ## Testing Locally: 45 tests (1 xfail), coverage 76.19 %, ruff, mypy, bandit clean; lowest versions ok on Python 3.10 (napalm-linux 0.15.0 from its PR branch; also with napalm 4.0.0, netmiko 4.0.0, paramiko 5.0.0); `napalm-standard check` and `ratchet` clean; build + `twine check --strict` pass.
christianmanivong added 2 commits 2026-10-23 10:10:04 +00:00
Mechanical: ruff format, and ruff check --fix with the rule set every NAPALM
driver uses (E, F, I, UP, B at line length 100, Python 3.10). What ruff
cannot fix comes in the next commit.
chore: adopt the NAPALM driver standard
driver / standard (pull_request) Successful in 15s
driver / lint (pull_request) Successful in 11s
driver / types (pull_request) Successful in 54s
driver / test (3.10) (pull_request) Successful in 59s
driver / test (3.11) (pull_request) Successful in 55s
driver / test (3.12) (pull_request) Successful in 57s
driver / lowest (pull_request) Successful in 30s
driver / test (3.13) (pull_request) Successful in 49s
driver / build (pull_request) Successful in 25s
driver / security (pull_request) Successful in 57s
CI / driver (pull_request) Successful in 3m6s
driver / publish (pull_request) Skipped
dd785da94f
- CI moves to .gitea/workflows/ci.yml and calls the shared driver workflow
  of NAPALM/driver-standard; napalm-device-types and napalm-linux come from
  git until napalm-linux 0.15.0 is on PyPI.
- requires-python >=3.10 (napalm-device-types needs it), SPDX license
  string, setuptools>=77, LICENSE file, py.typed, Issues and Changelog
  links.
- Dependencies: napalm-device-types>=4.22.0, napalm-linux>=0.15.0; the
  floors napalm>=4.0, netmiko>=4.0.0 and paramiko>=5.0.0 stay and pass
  the tests at exactly those versions. The dev extra gets floors and
  drops black (ruff formats).
- mypy strict for the whole package, no exempt module. install_package
  and uninstall_package keep napalm-device-types' PackagesMixin
  signatures, which LinuxDriver's differ from: type: ignore[override]
  on those two lines, with the reason above them.
- Coverage floor 76 % (measured 76.19 %); the quality baseline is empty
  apart from it.
christianmanivong added 1 commit 2026-10-23 14:01:57 +00:00
chore(release): 0.6.0
driver / standard (pull_request) Successful in 15s
driver / lint (pull_request) Successful in 12s
driver / types (pull_request) Successful in 53s
driver / test (3.10) (pull_request) Successful in 57s
driver / test (3.11) (pull_request) Successful in 56s
driver / lowest (pull_request) Successful in 27s
driver / test (3.12) (pull_request) Successful in 56s
driver / test (3.13) (pull_request) Successful in 49s
driver / build (pull_request) Successful in 24s
driver / security (pull_request) Successful in 58s
CI / driver (pull_request) Successful in 2m59s
driver / publish (pull_request) Skipped
0cf719e6de
christianmanivong merged commit f96afa42c7 into main 2026-10-23 14:46:42 +00:00
christianmanivong deleted branch chore/driver-standard 2026-10-23 14:46:42 +00:00
Sign in to join this conversation.