diff options
author | Eli Schwartz <eschwartz93@gmail.com> | 2023-12-05 20:33:38 -0500 |
---|---|---|
committer | Eli Schwartz <eschwartz93@gmail.com> | 2023-12-10 19:02:39 -0500 |
commit | 17c6d5eb478386ad183fa7e11b688217645d8f4f (patch) | |
tree | 9665d76103b8b9405b4aeb65e174a60a368533d7 /.github | |
parent | 5883089f6c7b39726dd06a48a23d8eb8754a75f7 (diff) | |
download | meson-17c6d5eb478386ad183fa7e11b688217645d8f4f.zip meson-17c6d5eb478386ad183fa7e11b688217645d8f4f.tar.gz meson-17c6d5eb478386ad183fa7e11b688217645d8f4f.tar.bz2 |
unittests: migrate from jsonschema to fastjsonschema
The former has rust dependencies, which lead to max capping on Cygwin
since there is no rust compiler there. But it turns out there are other
disadvantages of jsonschema:
- it involves installing 5 wheels, instead of just 1
- it is much slower
To give some perspective to the latter issue, this is what it looks like
when I test with jsonschema:
```
===== 1 passed, 509 deselected in 3.07s =====
Total time: 3.341 seconds
```
And here's what it looks like when I test with fastjsonschema:
```
===== 1 passed, 509 deselected, 1 warning in 0.28s =====
Total time: 0.550 seconds
```
I cannot think of a good reason to use the former. Although in order to
work on old CI images, we'll support it as a fallback mechanism
Diffstat (limited to '.github')
-rw-r--r-- | .github/workflows/cygwin.yml | 3 | ||||
-rw-r--r-- | .github/workflows/macos.yml | 2 | ||||
-rw-r--r-- | .github/workflows/msys2.yml | 4 |
3 files changed, 4 insertions, 5 deletions
diff --git a/.github/workflows/cygwin.yml b/.github/workflows/cygwin.yml index e62c745..3b1b185 100644 --- a/.github/workflows/cygwin.yml +++ b/.github/workflows/cygwin.yml @@ -76,8 +76,7 @@ jobs: - name: Run pip run: | export PATH=/usr/bin:/usr/local/bin:$(cygpath ${SYSTEMROOT})/system32 - # jsonschema is max capped because the new version depends on rust dependencies which are... hard to get on cygwin - python3 -m pip --disable-pip-version-check install gcovr 'jsonschema<4.18' pefile pytest pytest-subtests pytest-xdist coverage + python3 -m pip --disable-pip-version-check install gcovr fastjsonschema pefile pytest pytest-subtests pytest-xdist coverage shell: C:\cygwin\bin\bash.exe --noprofile --norc -o igncr -eo pipefail '{0}' - uses: actions/cache/save@v3 diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index 6d6b43a..0e5002a 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -33,7 +33,7 @@ jobs: python-version: '3.x' - run: | python -m pip install --upgrade pip - python -m pip install pytest pytest-xdist pytest-subtests jsonschema coverage + python -m pip install pytest pytest-xdist pytest-subtests fastjsonschema coverage - run: brew install pkg-config ninja llvm qt@5 - env: CPPFLAGS: "-I/usr/local/include" diff --git a/.github/workflows/msys2.yml b/.github/workflows/msys2.yml index 2bdcdd3..043f5ce 100644 --- a/.github/workflows/msys2.yml +++ b/.github/workflows/msys2.yml @@ -80,7 +80,7 @@ jobs: mingw-w64-${{ matrix.MSYS2_ARCH }}-python-lxml mingw-w64-${{ matrix.MSYS2_ARCH }}-python-setuptools mingw-w64-${{ matrix.MSYS2_ARCH }}-python-pip - mingw-w64-${{ matrix.MSYS2_ARCH }}-python-jsonschema + mingw-w64-${{ matrix.MSYS2_ARCH }}-python-fastjsonschema mingw-w64-${{ matrix.MSYS2_ARCH }}-${{ matrix.TOOLCHAIN }} - name: Install dependencies @@ -100,7 +100,7 @@ jobs: - name: Run Tests run: | if [[ "${{ matrix.MSYS2_ARCH }}" == "x86_64" ]]; then - # There apparently is no clean way to add to the PATH in the + # There apparently is no clean way to add to the PATH in the # previous step? # See for instance https://github.com/msys2/setup-msys2/issues/171 export PATH=$PATH:$PWD/pypy3local |