From 55a12145496a326f5ff552ac8232fb1ca02a259a Mon Sep 17 00:00:00 2001 From: Davide Setti Date: Wed, 19 Nov 2025 12:22:23 +0100 Subject: [PATCH 1/2] Remove duplicate dependencies from workflow - Test job now installs only pytest/pytest-cov, other deps from pyproject.toml - Build sdist job now installs only 'build' tool, deps from [build-system] - Removes CYTHONIZE=1 and --no-build-isolation (not needed) - Simplifies maintenance: dependencies defined once in pyproject.toml --- .github/workflows/test.yml | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index a5a49ce..ad9bb9b 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -26,15 +26,14 @@ jobs: python-version: ${{ matrix.python-version }} allow-prereleases: true - - name: Install dependencies + - name: Install test dependencies run: | python -m pip install --upgrade pip - pip install setuptools wheel cython numpy "w3lib<2.0" pip install pytest pytest-cov - name: Build and install package run: | - CYTHONIZE=1 pip install -e . --no-build-isolation + pip install -e . - name: Run tests run: | @@ -78,10 +77,9 @@ jobs: with: python-version: '3.12' - - name: Install dependencies + - name: Install build tool run: | - python -m pip install --upgrade pip - pip install build setuptools wheel cython numpy + python -m pip install --upgrade pip build - name: Build sdist run: python -m build --sdist From 301c584ee2b8571477e69ca998338064d1719c70 Mon Sep 17 00:00:00 2001 From: Davide Setti Date: Wed, 19 Nov 2025 12:32:49 +0100 Subject: [PATCH 2/2] Pin w3lib < 2.0 for compatibility w3lib 2.0 removed str_to_unicode which is used in scrapely/__init__.py. Pin to w3lib<2.0 in both pyproject.toml and requirements.txt until code is migrated to w3lib 2.0 API. --- pyproject.toml | 2 +- requirements.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 41c37ef..2bef9c7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -27,7 +27,7 @@ classifiers = [ ] dependencies = [ "numpy", - "w3lib", + "w3lib<2.0", ] [project.urls] diff --git a/requirements.txt b/requirements.txt index 19b3a6c..9f9dff2 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,2 +1,2 @@ numpy -w3lib +w3lib<2.0