Alternative to this method, you can use this configuration in your build.sh
:
#!/usr/bin/env bash
# exit on error
set -o errexit
echo "Installing the latest version of poetry..."
pip install --upgrade pip
pip install poetry==1.2.0
rm poetry.lock
poetry lock
python -m poetry install
For some reason I need to remove the poetry.lock
file because it recognize the version of poetry in render system and not in local environment installation.