From 7c40411315556e3d3ce1d02e32e68592dff7e2d4 Mon Sep 17 00:00:00 2001 From: Alan Ip Date: Sat, 11 Feb 2023 19:44:24 +0000 Subject: [PATCH] Fix tests by adding pip constraint for importlib-metadata. See https://stackoverflow.com/a/73932581. It seems like importlib-metadata is only required for tests, not production code. --- .github/workflows/test.yml | 2 +- constraints.txt | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 constraints.txt diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index cbfc01c6..92cf9744 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -23,6 +23,6 @@ jobs: with: python-version: ${{ matrix.python-version }} - name: Install requirements - run: pip install -r requirements_frozen.txt + run: pip install -c constraints.txt -r requirements_frozen.txt - name: Run tests run: pytest diff --git a/constraints.txt b/constraints.txt new file mode 100644 index 00000000..9428e642 --- /dev/null +++ b/constraints.txt @@ -0,0 +1 @@ +importlib-metadata<5.0