diff --git a/.github/workflows/posix.yml b/.github/workflows/posix.yml index 53c38b5d47b24..9839eacc046f9 100644 --- a/.github/workflows/posix.yml +++ b/.github/workflows/posix.yml @@ -31,13 +31,12 @@ jobs: [actions-38-slow.yaml, "slow", "", "", "", "", ""], [actions-38-locale.yaml, "not slow and not network", "language-pack-zh-hans xsel", "zh_CN.utf8", "zh_CN.utf8", "", ""], [actions-39-slow.yaml, "slow", "", "", "", "", ""], - [actions-pypy-38.yaml, "not slow and not clipboard", "", "", "", "", ""], + [actions-pypy-38.yaml, "not slow and not clipboard", "", "", "", "", "--max-worker-restart 0"], [actions-39-numpydev.yaml, "not slow and not network", "xsel", "", "", "deprecate", "-W error"], [actions-39.yaml, "not slow and not clipboard", "", "", "", "", ""] ] fail-fast: false env: - COVERAGE: true ENV_FILE: ci/deps/${{ matrix.settings[0] }} PATTERN: ${{ matrix.settings[1] }} EXTRA_APT: ${{ matrix.settings[2] }} @@ -46,6 +45,9 @@ jobs: PANDAS_TESTING_MODE: ${{ matrix.settings[5] }} TEST_ARGS: ${{ matrix.settings[6] }} PYTEST_TARGET: pandas + IS_PYPY: ${{ contains(matrix.settings[0], 'pypy') }} + # TODO: re-enable coverage on pypy, its slow + COVERAGE: ${{ !contains(matrix.settings[0], 'pypy') }} concurrency: # https://github.community/t/concurrecy-not-work-for-push/183068/7 group: ${{ github.event_name == 'push' && github.run_number || github.ref }}-${{ matrix.settings[0] }} @@ -83,12 +85,29 @@ jobs: channel-priority: flexible environment-file: ${{ env.ENV_FILE }} use-only-tar-bz2: true + if: ${{ env.IS_PYPY == 'false' }} # No pypy3.8 support + + - name: Setup PyPy + uses: actions/setup-python@v2.3.1 + with: + python-version: "pypy-3.8" + if: ${{ env.IS_PYPY == 'true' }} + + - name: Setup PyPy dependencies + shell: bash + run: | + # TODO: re-enable cov, its slowing the tests down though + # TODO: Unpin Cython, the new Cython 0.29.26 is causing compilation errors + pip install Cython==0.29.25 numpy python-dateutil pytz pytest>=6.0 pytest-xdist>=1.31.0 hypothesis>=5.5.3 + if: ${{ env.IS_PYPY == 'true' }} - name: Build Pandas uses: ./.github/actions/build_pandas - name: Test run: ci/run_tests.sh + # TODO: Don't continue on error for PyPy + continue-on-error: ${{ env.IS_PYPY == 'true' }} if: always() - name: Build Version diff --git a/ci/deps/actions-pypy-38.yaml b/ci/deps/actions-pypy-38.yaml index b44cfe5ad5a0d..ad05d2ab2dacc 100644 --- a/ci/deps/actions-pypy-38.yaml +++ b/ci/deps/actions-pypy-38.yaml @@ -5,7 +5,7 @@ dependencies: # TODO: Add the rest of the dependencies in here # once the other plentiful failures/segfaults # with base pandas has been dealt with - - python=3.8 + - python=3.8[build=*_pypy] # TODO: use this once pypy3.8 is available # tools - cython>=0.29.24 diff --git a/ci/run_tests.sh b/ci/run_tests.sh index de445bcc689fb..203f8fe293a06 100755 --- a/ci/run_tests.sh +++ b/ci/run_tests.sh @@ -12,8 +12,10 @@ if [[ "not network" == *"$PATTERN"* ]]; then export http_proxy=http://1.2.3.4 https_proxy=http://1.2.3.4; fi -if [ "$COVERAGE" ]; then +if [[ "$COVERAGE" == "true" ]]; then COVERAGE="-s --cov=pandas --cov-report=xml --cov-append" +else + COVERAGE="" # We need to reset this for COVERAGE="false" case fi # If no X server is found, we use xvfb to emulate it