Skip to content

fix: resolve lint and mypy errors in sys_utils_nixos.py#6

Open
mrosseel wants to merge 27 commits into
mainfrom
fix/sys-utils-nixos-ci
Open

fix: resolve lint and mypy errors in sys_utils_nixos.py#6
mrosseel wants to merge 27 commits into
mainfrom
fix/sys-utils-nixos-ci

Conversation

@mrosseel
Copy link
Copy Markdown
Owner

Summary

  • Fix Ruff linting errors in sys_utils_nixos.py (unused imports, line length)
  • Fix mypy type errors by adding proper type annotations and handling Optional types
  • Update pyproject.toml to include sys_utils_nixos in mypy overrides

Test plan

  • nox -s lint passes
  • nox -s type_hints passes
  • Verify sys_utils_nixos functionality on NixOS

🤖 Generated with Claude Code

mrosseel and others added 27 commits March 17, 2025 22:19
This reverts commit c872394.
The SD image module provides filesystems, but toplevel builds need
a minimal stub to evaluate successfully.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Required for NixOS module system to accept devMode setting.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Required when module has both options and config sections.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Replaces FIXME placeholders with actual SRI hashes.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Uses Pi5 runner when RUNNER_LABELS variable is set, falls back to
ubuntu with QEMU emulation otherwise.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Filter to only Pi 4B device tree (CM4 incompatible with our overlays)
- Use shorthand DTS syntax for PWM overlay

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Fix E402 lint: reorder gi imports, add noqa for gi.repository
- Fix Python 3.10 syntax: dict | None → Optional[dict]
- Fix utils.pifinder_home → utils.home_dir / "PiFinder"
- Add dbus/gi to mypy ignore list (no type stubs available)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant