Skip to content

Commit

Permalink
Fix nix linting of submodules
Browse files Browse the repository at this point in the history
Linting was breaking on including `sonata-system` as a submodule, due to
one of the vendored files from coremark in `sonata-system` containing a
non-UTF-8 copyright symbol in one of its markdown files. This broke
lychee linting.

In general, it doesn't make sense to lint submodules included under the
`third_party` directory. The exclude path contained `vendor`, which does
not exist, but not `third_party` - this is likely an error from copying
or a typo. This commit excludes that path from the lychee lint to avoid
these lints, fixing errors.

mypy was also running into python module naming conflicts with a
`test_runner` in both `sonata-software` and `sonata-system`, so a flag
has similarly been added to the `mypy` linting call to exclude the
`third_party` directory.
  • Loading branch information
AlexJones0 committed Sep 12, 2024
1 parent 2dbbd01 commit a6a715f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@
text = ''
ruff format --check .
ruff check .
mypy .
mypy --exclude third_party .
'';
};

Expand Down
2 changes: 1 addition & 1 deletion lychee.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
include_fragments = true
exclude_path = [
"./cheriot-rtos",
"./vendor",
"./third_party",
"./build",
]

0 comments on commit a6a715f

Please sign in to comment.