React
Python server (backend) :
poetry installReact app (frontend) :
cd frontend
yarn installPython server (backend) :
poetry run python manage.py run server 0.0.0.0:8000 --nostaticReact app (frontend) :
cd frontend
yarn startThen open browser on http://localhost:3000/
on staging server
poetry run fab -H alwaysdata -f staging.yml deployon production server
poetry run fab -H alwaysdata -f prod.yml deployIn order to get the latest versions of the dependencies and to update the poetry.lock file, you should use the update command.
poetry update`` This will resolve all dependencies of the project and write the exact versions into poetry.lock.
If you just want to update a few packages and not all, you can list them as such:
poetry update requests tomlNote that this will not update versions for dependencies outside their version constraints specified in the pyproject.toml file.
To add a new package :
poetry add requests pendulumTo add a package with constraints (or update constraints) :
# Allow >=2.0.5, <3.0.0 versions
poetry add pendulum@^2.0.5
# Allow >=2.0.5, <2.1.0 versions
poetry add pendulum@~2.0.5
# Allow >=2.0.5 versions, without upper bound
poetry add "pendulum>=2.0.5"
# Allow only 2.0.5 version
poetry add pendulum==2.0.5If you want to get the latest version of an already present dependency, you can use the special latest constraint:
poetry add pendulum@latestYou can also add git dependencies:
poetry add git+https://github.com/sdispater/pendulum.git