diff --git a/.github/requirements.txt b/.github/requirements.txt index 85eb68f..3579196 100644 --- a/.github/requirements.txt +++ b/.github/requirements.txt @@ -1 +1,2 @@ qgis-plugin-ci>=2.1.1,<3.0.0 +build diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 947e3e1..147c551 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -44,7 +44,7 @@ jobs: - name: Build package run: | - python setup.py sdist + python -m build --no-isolation --sdist - name: Create release on GitHub uses: ncipollo/release-action@v1.9.0 @@ -67,4 +67,4 @@ jobs: consumer_secret: ${{ secrets.TWITTER_CONSUMER_SECRET }} access_token_key: ${{ secrets.TWITTER_ACCESS_TOKEN_KEY }} access_token_secret: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }} - tweet_body: "New version of Py-QGIS-WPS ${{ env.CI_COMMIT_TAG }} ⚙ for #QGIS https://github.com/3liz/py-qgis-wps/releases" \ No newline at end of file + tweet_body: "New version of Py-QGIS-WPS ${{ env.CI_COMMIT_TAG }} ⚙ for #QGIS https://github.com/3liz/py-qgis-wps/releases" diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2cfb2a7..3f6c342 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -17,7 +17,7 @@ stages: stage: test script: - source ~/.bashrc - - make install install-tests + - make install install-dev - pip list -l - make test FLAVOR=$QGIS_FLAVOR tags: diff --git a/MANIFEST.in b/MANIFEST.in index fead42d..b3742be 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,5 +1,4 @@ -include setup.py MANIFEST.in README.md VERSION -include requirements.txt +include MANIFEST.in README.md VERSION include pyqgiswps/build.manifest recursive-include pyqgiswps/schemas * recursive-include pyqgiswps/html * diff --git a/Makefile b/Makefile index 6344fe5..dc21b88 100644 --- a/Makefile +++ b/Makefile @@ -6,8 +6,7 @@ DEPTH=. include $(DEPTH)/config.mk -BUILDDIR:=build -DIST:=${BUILDDIR}/dist +DIST:=dist MANIFEST=pyqgiswps/build.manifest @@ -31,8 +30,8 @@ deliver: twine upload -r storage $(DIST)/* dist: dirs manifest - rm -rf *.egg-info - $(PYTHON) setup.py sdist --dist-dir=$(DIST) + rm -rf *.egg-info + $(PYTHON) -m build --no-isolation --sdist --outdir=$(DIST) clean: rm -rf $(DIST) *.egg-info @@ -44,14 +43,12 @@ test: lint install: pip install -U --upgrade-strategy=eager -e . -install-tests: - pip install -U --upgrade-strategy=eager -r tests/requirements.txt +install-dev: + pip install -U --upgrade-strategy=eager -r requirements.dev install-doc: pip install -U --upgrade-strategy=eager -r doc/requirements.txt -install-dev: install-tests install-doc - lint: @ruff check --output-format=concise $(PYTHON_PKG) $(TESTDIR) @@ -61,6 +58,8 @@ lint-preview: lint-fix: @ruff check --preview --fix $(PYTHON_PKG) $(TESTDIR) +autopep8: lint-fix + typing: mypy --config=$(topsrcdir)/mypy.ini -p pyqgiswps diff --git a/docker/Dockerfile b/docker/Dockerfile index 050a7e9..b6aa330 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -33,7 +33,7 @@ RUN mkdir -p /opt/local/ \ COPY pyqgiswps py-qgis-wps/pyqgiswps COPY pyqgisservercontrib py-qgis-wps/pyqgisservercontrib -COPY setup.py pyproject.toml VERSION py-qgis-wps/ +COPY pyproject.toml VERSION py-qgis-wps/ # Create virtualenv for installing server RUN mkdir -p /opt/local/ \ diff --git a/pyproject.toml b/pyproject.toml index b1861dc..af02123 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,11 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "py-qgis-wps" -description = """ -Py-Qgis-WPS is an implementation of the Web Processing Service -standard from the Open Geospatial Consortium. qgis-wps is -written in Python and is a fork of PyWPS 4.0. -""" +description = "Py-Qgis-WPS is an implementation of the Web Processing Service standard from the Open Geospatial Consortium" readme = "README.md" requires-python = ">= 3.10" classifiers=[ diff --git a/tests/requirements.txt b/requirements.dev similarity index 95% rename from tests/requirements.txt rename to requirements.dev index 02ac13a..7a424f8 100644 --- a/tests/requirements.txt +++ b/requirements.dev @@ -9,3 +9,4 @@ types-psycopg2 pipdeptree lxml lxml-stubs +build diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index fb06ab3..0000000 --- a/requirements.txt +++ /dev/null @@ -1,10 +0,0 @@ -tornado >= 6 -jsonschema >= 4.15 -lxml -python-dateutil -redis -psutil -pyzmq >= 17, < 24 -PyYAML -OWSLib - diff --git a/setup.py b/setup.py deleted file mode 100644 index 6068493..0000000 --- a/setup.py +++ /dev/null @@ -1,3 +0,0 @@ -from setuptools import setup - -setup()