style: ruff format + ruff check --fix with the standard's rules. No behaviour change.
fix: long shell lines split; a dead loop in get_os_users removed (output
unchanged); the five except Exception: pass log at debug level (bandit B110);
nosec for two bandit false positives; test lint.
chore: CI in .gitea/ calling the shared workflow (device-types from git until
it is on PyPI); requires-python >=3.10; LICENSE; py.typed; SPDX license; links to
git.netork.io; strict mypy with napalm_linux.linux exempt for now (21 errors) and
recorded in the quality baseline; coverage floor 58 %.
The default branch stays master in this PR; renaming it to main is a separate step.
## Summary
napalm-linux adopts the NAPALM driver standard
(https://git.netork.io/NAPALM/driver-standard, STANDARDS.md); second repo of the pilot,
after napalm-device-types (NAPALM/napalm-device-types#52).
## Changes
- **style**: ruff format + ruff check --fix with the standard's rules. No behaviour change.
- **fix**: long shell lines split; a dead loop in `get_os_users` removed (output
unchanged); the five `except Exception: pass` log at debug level (bandit B110);
nosec for two bandit false positives; test lint.
- **chore**: CI in `.gitea/` calling the shared workflow (device-types from git until
it is on PyPI); `requires-python >=3.10`; LICENSE; `py.typed`; SPDX license; links to
git.netork.io; strict mypy with `napalm_linux.linux` exempt for now (21 errors) and
recorded in the quality baseline; coverage floor 58 %.
The default branch stays `master` in this PR; renaming it to `main` is a separate step.
## Related Issue
NetOrk/netork#734
## Testing
Locally: 212 tests, coverage 58.23 %, ruff, mypy, bandit clean; `napalm-standard check`
and `ratchet` clean; build + `twine check --strict` pass.
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.
- Long shell command lines are split into adjacent string literals.
- get_os_users: a first loop over /etc/group filled a map nobody read;
it is gone, the output is unchanged.
- The five except Exception: pass now log at debug level (B110), so a
swallowed failure leaves a trace.
- nosec for the staging path on the device (B108) and the sudo hint
message (B105); both are false positives.
- tests: raise ... from exc, unused loop variable.
- CI moves to .gitea/workflows/ci.yml and calls the shared driver workflow
of NAPALM/driver-standard; napalm-device-types comes from git until it is
on PyPI.
- requires-python >=3.10 (napalm-device-types needs it), LICENSE file,
py.typed, SPDX license string, links to git.netork.io.
- mypy strict for the package; napalm_linux.linux is exempt for now (21
errors), recorded in the quality baseline with its long functions and
the 2200-line module. Coverage floor 58 % (measured 58.23 %).
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
napalm-linux adopts the NAPALM driver standard
(https://git.netork.io/NAPALM/driver-standard, STANDARDS.md); second repo of the pilot,
after napalm-device-types (NAPALM/napalm-device-types#52).
Changes
get_os_usersremoved (outputunchanged); the five
except Exception: passlog at debug level (bandit B110);nosec for two bandit false positives; test lint.
.gitea/calling the shared workflow (device-types from git untilit is on PyPI);
requires-python >=3.10; LICENSE;py.typed; SPDX license; links togit.netork.io; strict mypy with
napalm_linux.linuxexempt for now (21 errors) andrecorded in the quality baseline; coverage floor 58 %.
The default branch stays
masterin this PR; renaming it tomainis a separate step.Related Issue
NetOrk/netork#734
Testing
Locally: 212 tests, coverage 58.23 %, ruff, mypy, bandit clean;
napalm-standard checkand
ratchetclean; build +twine check --strictpass.