add pixi, linting, pytest and run it on CI #17
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There are no docs set up yet, but these developer docs largely apply since most things in this PR are based on the Ribasim repository, a large part of which was set up by @Hofer-Julian.
I added a first test for the hydamo package such that this works:
pixi run test-hydamo
If you wonder where
pixi run
commands are defined, have a look atpixi.toml
.pixi run pre-commit
pixi run lint
pixi run test-hydamo
pixi.toml
.pixi.lock
is a huge file that is also checked in that decides the version of every direct and indirect dependency. This save us from having a broken system if one of our dependencies releases a breaking change. And all developers get exactly the same packages.This seems like a lot, but it's mostly set up in a way that you usually don't have to worry about it too much. For VS Code users, it also helps to follow the recommendations here: https://deltares.github.io/Ribasim/contribute/python.html#sec-vscode.
Most of the changes to the hydamo package are done to make ruff and mypy happy, such that CI passes.
This also already sets up some things we don't use yet but will soon, like Quarto documentation and it installs
ribasim-python
.