Skip to content

Commit

Permalink
Merge pull request #40 from goodmami/fix-35-cython-3
Browse files Browse the repository at this point in the history
Upgrade Cython to 3.0
  • Loading branch information
goodmami authored Nov 25, 2023
2 parents 8f4adad + 22c41a8 commit 4167657
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Install dependencies
run: python -m pip install --upgrade setuptools Cython~=0.29 pytest
run: python -m pip install --upgrade setuptools "Cython~=3.0" pytest
- name: Build source distribution
run: python setup.py sdist --cythonize
- name: Install source distribution
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pythonpackage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
python-version: ${{ matrix.python-version }}
- name: Build and install
run: |
python -m pip install --upgrade pip cython
python -m pip install --upgrade pip "Cython~=3.0"
cythonize -3i pe/*.pyx
pip install .
- name: Lint with flake8
Expand Down
5 changes: 1 addition & 4 deletions pe/_cy_machine.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ from enum import IntEnum

from cpython.mem cimport PyMem_Malloc, PyMem_Free

from pe._constants import Operator, Flag
from pe._constants import Operator, Flag, FAIL as FAILURE
from pe._errors import Error
from pe._match import Match
from pe._types import Memo
Expand All @@ -26,9 +26,6 @@ from pe.operators import Rule
from pe.patterns import DEFAULT_IGNORE


DEF FAILURE = -1


# Parser ###############################################################

cdef enum OpCode:
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[build-system]
requires = ["setuptools>=67.8", "wheel", "Cython~=0.29"]
requires = ["setuptools>=67.8", "wheel", "Cython~=3.0"]
build-backend = "setuptools.build_meta"
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ packages = pe
test_suite = test
setup_requires =
setuptools >= 67.8
Cython ~= 0.29
Cython ~= 3.0
tests_require =
pytest

Expand Down

0 comments on commit 4167657

Please sign in to comment.