|
| 1 | +name: PyDev.Debugger TESTS |
| 2 | + |
| 3 | +on: |
| 4 | + - push |
| 5 | + - pull_request |
| 6 | + |
| 7 | +env: |
| 8 | + DISPLAY: ":99" |
| 9 | + |
| 10 | +jobs: |
| 11 | + build: |
| 12 | + runs-on: ${{ matrix.os }} |
| 13 | + |
| 14 | + strategy: |
| 15 | + fail-fast: false |
| 16 | + matrix: |
| 17 | + name: [ |
| 18 | + "ubuntu-pypy3", |
| 19 | +# "macos-py37-cython", -- misbehaving on github actions |
| 20 | + "ubuntu-py38-cython-checkbin", |
| 21 | + "windows-py39-cython", |
| 22 | + "windows-py310-cython-checkbin", |
| 23 | + "windows-py311-cython", |
| 24 | + "ubuntu-py311-cython", |
| 25 | + "ubuntu-py312-cython-checkbin", |
| 26 | + "windows-py312-cython-checkbin", |
| 27 | + "ubuntu-py313-cython", |
| 28 | + "windows-py313-cython", |
| 29 | + ] |
| 30 | + |
| 31 | + include: |
| 32 | + - name: "ubuntu-pypy3" |
| 33 | + python: "pypy3.10" |
| 34 | + os: ubuntu-20.04 |
| 35 | + PYDEVD_USE_CYTHON: NO |
| 36 | +# - name: "macos-py37-cython" |
| 37 | +# python: "3.7" |
| 38 | +# os: macos-latest |
| 39 | +# PYDEVD_USE_CYTHON: YES |
| 40 | + - name: "ubuntu-py38-cython-checkbin" |
| 41 | + python: "3.8" |
| 42 | + os: ubuntu-20.04 |
| 43 | + PYDEVD_USE_CYTHON: YES |
| 44 | + - name: "windows-py39-cython" |
| 45 | + python: "3.9" |
| 46 | + os: windows-latest |
| 47 | + PYDEVD_USE_CYTHON: YES |
| 48 | + - name: "windows-py310-cython-checkbin" |
| 49 | + python: "3.10" |
| 50 | + os: windows-latest |
| 51 | + PYDEVD_USE_CYTHON: YES |
| 52 | + # See: https://github.com/actions/python-versions/releases |
| 53 | + - name: "windows-py311-cython" |
| 54 | + python: "3.11.0" |
| 55 | + os: windows-latest |
| 56 | + PYDEVD_USE_CYTHON: YES |
| 57 | + - name: "ubuntu-py311-cython" |
| 58 | + python: "3.11.0" |
| 59 | + os: ubuntu-20.04 |
| 60 | + PYDEVD_USE_CYTHON: YES |
| 61 | + - name: "ubuntu-py312-cython-checkbin" |
| 62 | + python: "3.12.0" |
| 63 | + os: ubuntu-20.04 |
| 64 | + PYDEVD_USE_CYTHON: YES |
| 65 | + - name: "windows-py312-cython-checkbin" |
| 66 | + python: "3.12" |
| 67 | + os: windows-latest |
| 68 | + PYDEVD_USE_CYTHON: YES |
| 69 | + - name: "ubuntu-py313-cython" |
| 70 | + python: "3.13" |
| 71 | + os: ubuntu-20.04 |
| 72 | + PYDEVD_USE_CYTHON: YES |
| 73 | + - name: "windows-py313-cython" |
| 74 | + python: "3.13" |
| 75 | + os: windows-latest |
| 76 | + PYDEVD_USE_CYTHON: YES |
| 77 | + |
| 78 | + steps: |
| 79 | + - uses: actions/checkout@v1 |
| 80 | + - name: Set up Python ${{ matrix.python }} |
| 81 | + uses: actions/setup-python@v4 |
| 82 | + with: |
| 83 | + python-version: ${{ matrix.python }} |
| 84 | + - name: Install gdb/xvfb/ptrace_scope |
| 85 | + run: | |
| 86 | + sudo apt-get update |
| 87 | + sudo apt-get install gdb |
| 88 | + sudo sysctl kernel.yama.ptrace_scope=0 |
| 89 | + sudo apt-get install xvfb |
| 90 | + sudo apt-get install libqt5x11extras5 |
| 91 | + Xvfb -ac :99 -screen 0 1280x1024x16 > /dev/null 2>&1 & |
| 92 | + if: contains(matrix.name, 'ubuntu') |
| 93 | + - name: Install common Python deps |
| 94 | + run: | |
| 95 | + pip install --upgrade pip |
| 96 | + pip install setuptools --no-warn-script-location |
| 97 | + pip install wheel --no-warn-script-location |
| 98 | + pip install "cython>3" --no-warn-script-location |
| 99 | + pip install psutil --no-warn-script-location |
| 100 | + pip install numpy --no-warn-script-location |
| 101 | + pip install pytest --no-warn-script-location |
| 102 | + pip install pytest-xdist --no-warn-script-location |
| 103 | + pip install psutil --no-warn-script-location |
| 104 | + pip install ipython --no-warn-script-location |
| 105 | + pip install untangle --no-warn-script-location |
| 106 | + pip install importlib-metadata --no-warn-script-location |
| 107 | + - name: Install Python 3.x deps |
| 108 | + if: contains(matrix.name, 'py3') && !contains(matrix.name, 'pypy') && !contains(matrix.name, 'py312') && !contains(matrix.name, 'py311') && !contains(matrix.name, 'py313') |
| 109 | + run: | |
| 110 | + pip install PySide2 --no-warn-script-location |
| 111 | + pip install "numpy<2" --force --no-warn-script-location |
| 112 | + pip install cherrypy --no-warn-script-location |
| 113 | + pip install gevent==23.9.1 greenlet |
| 114 | + |
| 115 | + - name: Install django |
| 116 | + if: "!contains(matrix.name, 'py38')" |
| 117 | + run: pip install "django<=4.2" --no-warn-script-location |
| 118 | + |
| 119 | + - name: Install Pandas |
| 120 | + if: contains(matrix.name, 'py310') && !contains(matrix.name, 'pypy') |
| 121 | + # The pandas Styler also requires jinja2. |
| 122 | + run: pip install pandas pyarrow jinja2 --no-warn-script-location |
| 123 | + - name: Install Pypy 3 deps |
| 124 | + if: contains(matrix.name, 'py3') |
| 125 | + run: | |
| 126 | + pip install trio |
| 127 | + |
| 128 | + - name: Check that wheels can be built |
| 129 | + if: contains(matrix.name, 'checkbin') && contains(matrix.name, 'ubuntu') |
| 130 | + run: | |
| 131 | + python -m pip install setuptools --no-warn-script-location |
| 132 | + python -m pip install cibuildwheel==2.21.3 |
| 133 | + # Remove these .so files (will be rebuilt) |
| 134 | + rm pydevd_attach_to_process/*.so |
| 135 | + python -m cibuildwheel --output-dir wheelhouse |
| 136 | + env: |
| 137 | + CIBW_BUILD: cp310-*manylinux*x86_64 cp311-*manylinux*x86_64 cp312-*manylinux*x86_64 cp313-*manylinux*x86_64 |
| 138 | + CIBW_BUILD_VERBOSITY: 3 |
| 139 | + |
| 140 | + - name: Rebuild .so |
| 141 | + if: contains(matrix.name, 'checkbin') && contains(matrix.name, 'ubuntu') |
| 142 | + run: | |
| 143 | + pydevd_attach_to_process/linux_and_mac/compile_linux.sh |
| 144 | + |
| 145 | + - name: Check cython unchanged |
| 146 | + if: contains(matrix.name, 'checkbin') |
| 147 | + env: |
| 148 | + PYTHONPATH: . |
| 149 | + run: | |
| 150 | + python build_tools/build.py |
| 151 | + python build_tools/check_no_git_modifications.py |
| 152 | +
|
| 153 | + - name: Create cython binaries |
| 154 | + if: contains(matrix.name, 'cython') |
| 155 | + run: | |
| 156 | + python setup_pydevd_cython.py build_ext --inplace |
| 157 | + - name: Check debug |
| 158 | + if: contains(matrix.name, 'checkdebug') |
| 159 | + run: | |
| 160 | + ./.github/install_and_run_debug_py.sh |
| 161 | + - name: Run Python 3.x tests |
| 162 | + env: |
| 163 | + # QT_DEBUG_PLUGINS: 1 |
| 164 | + PYTHONPATH: . |
| 165 | + PYDEVD_USE_CYTHON: ${{matrix.PYDEVD_USE_CYTHON }} |
| 166 | + run: | |
| 167 | + python -m pytest -n auto -rfE |
| 168 | +
|
0 commit comments