Skip to content

Commit

Permalink
Merge pull request #773 from googlefonts/support-pypy
Browse files Browse the repository at this point in the history
Add testing with pypy3
  • Loading branch information
madig authored Aug 9, 2021
2 parents f9190f1 + f488316 commit 47fb3f2
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 11 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,11 @@ jobs:
if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')"
strategy:
matrix:
python-version: [3.6, 3.7, 3.8, 3.9]
python-version: [3.6, 3.7, 3.8, 3.9, "pypy-3.7"]
platform: [ubuntu-latest, windows-latest]
exclude:
- platform: windows-latest
python-version: "pypy-3.7"
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
Expand Down
4 changes: 4 additions & 0 deletions Lib/fontmake/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -521,6 +521,10 @@ def main(args=None):
logging.exception(e)
sys.exit(1)
sys.exit(f"fontmake: Error: {str(e)}")
finally:
debug_feature_file = args.get("debug_feature_file")
if debug_feature_file is not None:
debug_feature_file.close()


if __name__ == "__main__":
Expand Down
8 changes: 5 additions & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
fonttools[unicode,ufo,lxml]==4.22.0
cu2qu==1.6.7
fonttools[unicode,ufo,lxml]==4.22.0 ; platform_python_implementation == 'CPython'
fonttools[unicode,ufo]==4.22.0 ; platform_python_implementation != 'CPython'
cu2qu==1.6.7.post1
glyphsLib==5.3.2
ufo2ft[pathops]==2.21.0
MutatorMath==3.0.1
fontMath==0.6.0
defcon[lxml]==0.8.1
defcon[lxml]==0.8.1 ; platform_python_implementation == 'CPython'
defcon==0.8.1 ; platform_python_implementation != 'CPython'
booleanOperations==0.9.0
ufoLib2==0.8.0
attrs==20.3.0
Expand Down
5 changes: 2 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,11 @@
setup_requires=wheel + ["setuptools_scm"],
python_requires=">=3.6",
install_requires=[
"fonttools[ufo,lxml,unicode]>=4.21.1",
"cu2qu>=1.6.7",
"fonttools[ufo,lxml,unicode]>=4.21.1 ; platform_python_implementation == 'CPython'",
"fonttools[ufo,unicode]>=4.21.1 ; platform_python_implementation != 'CPython'",
"glyphsLib>=5.3.2",
"ufo2ft[compreffor]>=2.20.0",
"fontMath>=0.6.0",
"booleanOperations>=0.9.0",
"ufoLib2>=0.8.0",
"attrs>=19",
],
Expand Down
6 changes: 3 additions & 3 deletions test_requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
pytest>=4.5.0
coverage>=5
black
isort
flake8-bugbear
black ; platform_python_implementation == 'CPython'
isort ; platform_python_implementation == 'CPython'
flake8-bugbear ; platform_python_implementation == 'CPython'
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = lint, py3{6,7,8,9}, coverage-report
envlist = lint, py3{6,7,8,9}, pypy3, coverage-report
skip_missing_interpreters = true

[testenv]
Expand Down

0 comments on commit 47fb3f2

Please sign in to comment.