Skip to content

Commit

Permalink
[FIX] Make Python version explicit in pre-commit workflow
Browse files Browse the repository at this point in the history
Recently (or recently enough that I've just begun noticing it), the
nodeenv dependency had troubles installing. Sometimes. It wasn't very
reliably failing.

This is related to <ekalinin/nodeenv#328>.

By explicitly setting the Python version to something <=3.10, we can
safely pretend the problem doesn't exist.

Ideally the Python versions match up to the ones used in test.yml, but
they don't, and I fear it might be too intrusive to fix that in this
commit.

Signed-off-by: Carmen Bianca BAKKER <[email protected]>
  • Loading branch information
carmenbianca committed May 10, 2023
1 parent fe5b6f5 commit 24906ec
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/.github/workflows/pre-commit.yml.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,12 @@ jobs:
{%- elif odoo_version < 13 %}
with:
python-version: "3.6"
{%- elif odoo_version < 14 %}
{%- elif odoo_version < 15 %}
with:
python-version: "3.8"
{%- elif odoo_version <= 16 %}
with:
python-version: "3.10"
{%- endif %}
- name: Get python version
run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> $GITHUB_ENV
Expand Down

0 comments on commit 24906ec

Please sign in to comment.