TODO A description of the project
Currently, we are experimenting with/recreating the TOFU codebase (Maini, Feng, Schwarzschild et al., 2024).
TODO
-
Install dependencies with Poetry
poetry install
-
Install pre-commit hooks:
poetry run pre-commit install --install-hooks
-
To add dependencies to the poetry environment:
poetry add <PACKAGE_NAME>
See the poetry documentation for more details on specifying dependencies.
-
To run commands in the poetry virtual environment (in a terminal), either:
- Prefix the command you want to run with
poetry run
- e.g.
poetry run python myscript.py
- e.g.
- Enter the virtual environment with
poetry shell
and then run commands as normal- then exit the virtual environment with
exit
- then exit the virtual environment with
- Prefix the command you want to run with
-
To run tests:
poetry run pytest
-
To run linters:
-
If you have setup pre-commit
flake8
,black
, andisort
will run automatically before making commits -
Or you can run them manually:
poetry run black . poetry run isort . poetry run flake8
-
-
Your source code files should go in the
src/arcsf
directory. These will be available as a python package, i.e. you can dofrom arcsf.myfile import myfunction
etc. -
Add tests (in files with names like
test_*.py
and with functions with names startingtest_*
) thetests/
directory.