Skip to content

Commit

Permalink
Update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
honnibal committed Sep 2, 2024
1 parent 69540ce commit eab50c3
Showing 1 changed file with 18 additions and 17 deletions.
35 changes: 18 additions & 17 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ jobs:
run: |
python -m pytest --pyargs thinc -Werror --cov=thinc --cov-report=term
# TODO: Update for numpy v2
# Notes on numpy requirements hacks:
# 1. torch does not have a direct numpy requirement but is compiled
# against a newer version than the oldest supported numpy for windows and
Expand All @@ -124,20 +125,20 @@ jobs:
# Note: some of these pip install commands are known to fail for some platforms.
# To continue despite errors as in azure pipelines, remove -e from the default
# bash flags.
- name: Install extras for testing
run: |
pip install "protobuf~=3.20.0" "tensorflow~=2.5.0"
#pip install "mxnet; sys_platform != 'win32' and python_version < '3.12'"
pip install "torch!=1.13.0; sys_platform!='darwin'" --extra-index-url https://download.pytorch.org/whl/cpu
# there is a bug related to MPS devices in github macos runners that
# will be fixed in torch v2.1.1
# https:/pytorch/pytorch/pull/111576
pip install "torch>=2.1.1; sys_platform=='darwin'" --extra-index-url https://download.pytorch.org/whl/cpu
pip install "numpy~=1.23.0; python_version=='3.10' and sys_platform=='win32'"
pip install "numpy<1.24.0"
pip install -r requirements.txt
pip uninstall -y mypy
shell: bash --noprofile --norc -o pipefail {0}

- name: Run tests with extras
run: python -m pytest --pyargs thinc --cov=thinc --cov-report=term -p thinc.tests.enable_tensorflow
#- name: Install extras for testing
# run: |
# #pip install "protobuf~=3.20.0" "tensorflow~=2.5.0"
# #pip install "mxnet; sys_platform != 'win32' and python_version < '3.12'"
# pip install "torch!=1.13.0; sys_platform!='darwin'" --extra-index-url https://download.pytorch.org/whl/cpu
# # there is a bug related to MPS devices in github macos runners that
# # will be fixed in torch v2.1.1
# # https:/pytorch/pytorch/pull/111576
# pip install "torch>=2.1.1; sys_platform=='darwin'" --extra-index-url https://download.pytorch.org/whl/cpu
# #pip install "numpy~=1.23.0; python_version=='3.10' and sys_platform=='win32'"
# #pip install "numpy<1.24.0"
# pip install -r requirements.txt
# pip uninstall -y mypy
# shell: bash --noprofile --norc -o pipefail {0}

##- name: Run tests with extras
# run: python -m pytest --pyargs thinc --cov=thinc --cov-report=term -p thinc.tests.enable_tensorflow

0 comments on commit eab50c3

Please sign in to comment.