-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Poetry as package manager | added github actions for publishing upon release creation #6
Conversation
with: | ||
python-version: 3.10.14 | ||
|
||
- name: Cache Poetry installation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice idea with cache!
I didn't use that in Github before, but from their repo, it seems like there needs to be something as
if: steps.cache-primes.outputs.cache-hit != 'true'
in the follow-up step. Or did you test that Poetry will quickly skip the installation by itself?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please see latest changes and the corresponding CI run -> https://github.com/gnosis/python-web3-wallet-streamlit/actions/runs/12692379504?pr=6
I believe the cache
is working now 🙏
- name: Cache Poetry dependencies | ||
uses: actions/cache@v3 | ||
with: | ||
path: .venv |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you test that this cache stuff works/makes it faster? From CI it looks like virtualenv is installed elsewhere:
Run poetry install
Creating virtualenv python-web3-wallet-96aaq9Ev-py3.10 in /home/runner/.cache/pypoetry/virtualenvs
so I wonder what is this caching.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See CI run above, Python packages + node packages are installed only once, although the action inside python_prepare
is called by both.
key: venv-${{ runner.os }}-${{ hashFiles('**/poetry.lock') }} | ||
|
||
- name: Install Python dependencies | ||
if: steps.cache_poetry_dependencies.outputs.cache-hit != 'true' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kongzii Here the check for installing packages again - thanks for the observation
No description provided.