Readme
Run with:
Verify flask db script (dev):
Change the .env file value of FLASK_ENV to dev to verify flask db script (prod):
Environment management
This project uses tox and poetry, and if a dev machine is also using pyenv, the number of environments to manage gets pretty high.
You can use pyenv to manage the global python version, but this project works well with poetry set up to create project-specific environments.
Dependencies
- For local dev, install dev dependencies and test dependencies in the poetry environment. The test dependencies are useful for non-tox test running, like vscode runners.
- For CI, install test dependencies.
- For production, only install production dependencies
Warning
Do NOT install test and dev dependencies in production
Tox can run tests locally and also runs tests in circleci
- Use extras to install test dependencies
- Use dev for anything needed for running locally but not needed for testing (e.g. debugpy)
- Install extras in tox, and in the local dev environment
- Exclude dev from docker compose
From Poetry docs re groups: "Installing (groups) is only possible by using Poetry."
To run tox 4:
or
mkdocs
Deploy mkdocs with poetry run mike deploy --push --update-aliases 0.1 latest
Set default for mkdocs to latest
with poetry run mike set-default latest