For more information structure look at this example
Expect rapid updates over the next few weeks.
There is a root pyproject.toml
file that contains the dev dependencies for the entire project.
Each project has its own pyproject.toml
file that contains the dependencies for that project.
So for example, the dash
dependency is only in the dashboard project's pyproject.toml
file.
Each project has their own distinct configuration files, like .gitignore
, to keep things separate while also letting them share common things between them.
conda create -n "sn-mono" python=3.10
conda activate "sn-mono"
pip install poetry
From root:
poetry install
This will install all the dependencies for all the projects
This scaffolds the project in the correct way.
Run from root:
poetry new ./packages/<project-name>
Then in the the root pyproject.toml
file, add the new project to the packages
section like so:
project-name = { path = "./packages/<project-name>", develop = true, extras = ["dev"] }}`
extras = ["dev"] is optional, but it will install the dev dependencies for that project, so for airflow we do this because we need the dev dependencies for the airflow
package for IDE support.