From dca085404c5a8c4ae85936dbabd4d95f4c0b1a77 Mon Sep 17 00:00:00 2001 From: Johannes Nussbaum <39048939+jnussbaum@users.noreply.github.com> Date: Thu, 8 Sep 2022 09:32:42 +0200 Subject: [PATCH] chore: tidy up makefile (DEV-1166) (#223) --- .github/workflows/daily-test.yml | 3 +- .github/workflows/release.yml | 3 +- .github/workflows/test.yml | 3 +- Makefile | 73 +++--- Pipfile | 8 +- Pipfile.lock | 231 +++++++++++-------- README.md | 15 +- dev-requirements.txt | 27 ++- docs/dsp-tools-information-for-developers.md | 10 +- docs/requirements.txt | 1 - requirements.txt | 11 +- setup.py | 47 ++-- 12 files changed, 243 insertions(+), 189 deletions(-) diff --git a/.github/workflows/daily-test.yml b/.github/workflows/daily-test.yml index 7835d12cb..290cf8762 100644 --- a/.github/workflows/daily-test.yml +++ b/.github/workflows/daily-test.yml @@ -19,8 +19,7 @@ jobs: python-version: 3.9 - name: Install dependencies run: | - make upgrade-dist-tools make install-requirements make install - name: Run e2e tests - run: make test-end-to-end + run: make test-end-to-end-ci diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 049d6f1c9..561a53bca 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -29,10 +29,9 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip - pip install -r requirements.txt + make install-requirements # release new version to PyPI - run: | - make upgrade-dist-tools make dist make upload diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e80944e3f..7408c1994 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - target: [ 'test-end-to-end', 'test-unittests', 'docs-build' ] + target: [ 'test-end-to-end-ci', 'test-unittests', 'docs-build' ] steps: - name: Checkout source uses: actions/checkout@v2 @@ -23,7 +23,6 @@ jobs: python-version: 3.9 - name: Install dependencies run: | - make upgrade-dist-tools make install-requirements make install - name: Run tests diff --git a/Makefile b/Makefile index e77542ba1..b1da89168 100644 --- a/Makefile +++ b/Makefile @@ -3,21 +3,23 @@ THIS_FILE := $(lastword $(MAKEFILE_LIST)) CURRENT_DIR := $(shell dirname $(realpath $(firstword $(MAKEFILE_LIST)))) -################################# +############################ # Make targets for dsp-tools -################################# - -.PHONY: clone-dsp-repo -clone-dsp-repo: ## clone the dsp-api git repository - @git clone --branch main --single-branch --depth 1 https://github.com/dasch-swiss/dsp-api.git $(CURRENT_DIR)/.tmp/dsp-stack +############################ .PHONY: dsp-stack -dsp-stack: ## run the dsp-stack (deletes existing volumes first) - $(MAKE) -C $(CURRENT_DIR)/.tmp/dsp-stack env-file - $(MAKE) -C $(CURRENT_DIR)/.tmp/dsp-stack stack-down-delete-volumes - $(MAKE) -C $(CURRENT_DIR)/.tmp/dsp-stack init-db-test - $(MAKE) -C $(CURRENT_DIR)/.tmp/dsp-stack stack-up - $(MAKE) -C $(CURRENT_DIR)/.tmp/dsp-stack stack-logs-api-no-follow +dsp-stack: ## clone the dsp-api git repository and run the dsp-stack + @mkdir -p .tmp + @git clone --branch main --single-branch --depth 1 https://github.com/dasch-swiss/dsp-api.git .tmp/dsp-stack + $(MAKE) -C .tmp/dsp-stack env-file + $(MAKE) -C .tmp/dsp-stack init-db-test + $(MAKE) -C .tmp/dsp-stack stack-up + $(MAKE) -C .tmp/dsp-stack stack-logs-api-no-follow + +.PHONY: stack-down +stack-down: ## stop dsp-stack and remove the cloned dsp-api repository + $(MAKE) -C .tmp/dsp-stack stack-down-delete-volumes + @test -x .tmp && rm -rf .tmp .PHONY: dist dist: ## generate distribution package @@ -27,21 +29,13 @@ dist: ## generate distribution package upload: ## upload distribution package to PyPI python3 -m twine upload dist/* -.PHONY: upgrade-dist-tools -upgrade-dist-tools: ## upgrade packages necessary for testing, building, packaging and uploading to PyPI - python3 -m pip install --upgrade pip setuptools wheel twine pytest mkdocs - .PHONY: docs-build docs-build: ## build docs into the local 'site' folder mkdocs build .PHONY: docs-serve docs-serve: ## serve docs for local viewing - mkdocs serve - -.PHONY: docs-publish -docs-publish: ## build and publish docs to GitHub Pages - mkdocs gh-deploy + mkdocs serve --dev-addr=0.0.0.0:7979 .PHONY: install-requirements install-requirements: ## install requirements @@ -56,44 +50,47 @@ install: ## install from source (runs setup.py) pip3 install -e . .PHONY: test -test: clean local-tmp clone-dsp-repo dsp-stack ## run all tests +test: dsp-stack ## run all tests + pytest test/ + $(MAKE) stack-down + +.PHONY: test-no-stack +test-no-stack: ## run tests without starting the stack (if a dsp-stack is already running) pytest test/ .PHONY: test-end-to-end -test-end-to-end: clean local-tmp clone-dsp-repo dsp-stack ## run e2e tests +test-end-to-end: dsp-stack ## run e2e tests + pytest test/e2e/ + $(MAKE) stack-down + +.PHONY: test-end-to-end-ci +test-end-to-end-ci: dsp-stack ## run e2e tests on GitHub CI, where it isn't possible nor necessary to remove .tmp + pytest test/e2e/ + +.PHONY: test-end-to-end-no-stack +test-end-to-end-no-stack: ## run e2e tests without starting the dsp-stack (if a dsp-stack is already running) pytest test/e2e/ .PHONY: test-unittests test-unittests: ## run unit tests pytest test/unittests/ -.PHONY: local-tmp -local-tmp: ## create local .tmp folder - @mkdir -p $(CURRENT_DIR)/.tmp - .PHONY: clean clean: ## clean local project directories - @rm -rf $(CURRENT_DIR)/.tmp - @rm -rf dist/ build/ site/ knora.egg-info/ + @rm -rf dist/ build/ site/ dsp_tools.egg-info/ .PHONY: help help: ## show this help @awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z_-]+:.*?## / {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' $(MAKEFILE_LIST) | sort -.PHONY: run -run: ## create dist, install and run - $(MAKE) clean - $(MAKE) dist - $(MAKE) install - dsp-tools - .PHONY: freeze-requirements freeze-requirements: ## update (dev-)requirements.txt and setup.py based on pipenv's Pipfile.lock - pipenv requirements > requirements.txt + pipenv run pipenv requirements > requirements.txt sed -i '' 's/==/~=/g' requirements.txt - pipenv requirements --dev-only > dev-requirements.txt + pipenv run pipenv requirements --dev-only > dev-requirements.txt sed -i '' 's/==/~=/g' dev-requirements.txt pipenv run pipenv-setup sync sed -i '' 's/==/~=/g' setup.py + autopep8 --global-config pyproject.toml --aggressive --in-place setup.py .DEFAULT_GOAL := help diff --git a/Pipfile b/Pipfile index 94b2998bf..09fb9f1d4 100644 --- a/Pipfile +++ b/Pipfile @@ -6,20 +6,15 @@ name = "pypi" [packages] jsonpath-ng = "*" argparse = "*" -rdflib = "*" lxml = "*" -validators = "*" requests = "*" jsonschema = "*" -click = "*" -rfc3987 = "*" pystrict = "*" openpyxl = "*" -pyparsing = "==2.4.7" networkx = "*" pandas = "*" -xlrd = "*" regex = "*" +xlrd = "*" [dev-packages] mkdocs = "*" @@ -32,6 +27,7 @@ wheel = "*" pipenv-setup = "*" pytest = "*" types-requests = "*" +twine = "*" [requires] python_version = "3" diff --git a/Pipfile.lock b/Pipfile.lock index e6797871d..3254bf545 100644 --- a/Pipfile.lock +++ b/Pipfile.lock @@ -1,7 +1,7 @@ { "_meta": { "hash": { - "sha256": "dba16a0708756d54af2eb8e061285afcc94535f8e8d073b744759e8bfd4834f5" + "sha256": "9788d29acabe4d7fc2de563bb84a7e0b39665d8953cbcbc1e31e9ac6e3505f7e" }, "pipfile-spec": 6, "requires": { @@ -48,14 +48,6 @@ "markers": "python_version >= '3.6'", "version": "==2.1.1" }, - "click": { - "hashes": [ - "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e", - "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48" - ], - "index": "pypi", - "version": "==8.1.3" - }, "decorator": { "hashes": [ "sha256:637996211036b6385ef91435e4fae22989472f9d571faba8927ba8253acbc330", @@ -80,13 +72,6 @@ "markers": "python_version >= '3.5'", "version": "==3.3" }, - "isodate": { - "hashes": [ - "sha256:0751eece944162659049d35f4f549ed815792b38793f07cf73381c1c87cbed96", - "sha256:48c5881de7e8b0a0d648cb024c8062dc84e7b840ed81e864c7614fd3c127bde9" - ], - "version": "==0.6.1" - }, "jsonpath-ng": { "hashes": [ "sha256:292a93569d74029ba75ac2dc3d3630fc0e17b2df26119a165fa1d498ca47bf65", @@ -98,11 +83,11 @@ }, "jsonschema": { "hashes": [ - "sha256:15062f4cc6f591400cd528d2c355f2cfa6a57e44c820dc783aee5e23d36a831f", - "sha256:9892b8d630a82990521a9ca630d3446bd316b5ad54dbe981338802787f3e0d2d" + "sha256:21f4979391bdceb044e502fd8e79e738c0cdfbdc8773f9a49b5769461e82fe1e", + "sha256:2df0fab225abb3b41967bb3a46fd37dc74b1536b5296d0b1c2078cd072adf0f7" ], "index": "pypi", - "version": "==4.14.0" + "version": "==4.15.0" }, "lxml": { "hashes": [ @@ -232,30 +217,30 @@ }, "pandas": { "hashes": [ - "sha256:07238a58d7cbc8a004855ade7b75bbd22c0db4b0ffccc721556bab8a095515f6", - "sha256:0daf876dba6c622154b2e6741f29e87161f844e64f84801554f879d27ba63c0d", - "sha256:16ad23db55efcc93fa878f7837267973b61ea85d244fc5ff0ccbcfa5638706c5", - "sha256:1d9382f72a4f0e93909feece6fef5500e838ce1c355a581b3d8f259839f2ea76", - "sha256:24ea75f47bbd5574675dae21d51779a4948715416413b30614c1e8b480909f81", - "sha256:2893e923472a5e090c2d5e8db83e8f907364ec048572084c7d10ef93546be6d1", - "sha256:2ff7788468e75917574f080cd4681b27e1a7bf36461fe968b49a87b5a54d007c", - "sha256:41fc406e374590a3d492325b889a2686b31e7a7780bec83db2512988550dadbf", - "sha256:48350592665ea3cbcd07efc8c12ff12d89be09cd47231c7925e3b8afada9d50d", - "sha256:605d572126eb4ab2eadf5c59d5d69f0608df2bf7bcad5c5880a47a20a0699e3e", - "sha256:6dfbf16b1ea4f4d0ee11084d9c026340514d1d30270eaa82a9f1297b6c8ecbf0", - "sha256:6f803320c9da732cc79210d7e8cc5c8019aad512589c910c66529eb1b1818230", - "sha256:721a3dd2f06ef942f83a819c0f3f6a648b2830b191a72bbe9451bcd49c3bd42e", - "sha256:755679c49460bd0d2f837ab99f0a26948e68fa0718b7e42afbabd074d945bf84", - "sha256:78b00429161ccb0da252229bcda8010b445c4bf924e721265bec5a6e96a92e92", - "sha256:958a0588149190c22cdebbc0797e01972950c927a11a900fe6c2296f207b1d6f", - "sha256:a3924692160e3d847e18702bb048dc38e0e13411d2b503fecb1adf0fcf950ba4", - "sha256:d51674ed8e2551ef7773820ef5dab9322be0828629f2cbf8d1fc31a0c4fed640", - "sha256:d5ebc990bd34f4ac3c73a2724c2dcc9ee7bf1ce6cf08e87bb25c6ad33507e318", - "sha256:d6c0106415ff1a10c326c49bc5dd9ea8b9897a6ca0c8688eb9c30ddec49535ef", - "sha256:e48fbb64165cda451c06a0f9e4c7a16b534fcabd32546d531b3c240ce2844112" + "sha256:050aada67a5ec6699a7879e769825b510018a95fb9ac462bb1867483d0974a97", + "sha256:0959c41004e3d2d16f39c828d6da66ebee329836a7ecee49fb777ac9ad8a7501", + "sha256:4591cadd06fbbbd16fafc2de6e840c1aaefeae3d5864b688004777ef1bbdede3", + "sha256:51c424ca134fdaeac9a4acd719d1ab48046afc60943a489028f0413fdbe9ef1c", + "sha256:785e878a6e6d8ddcdb8c181e600855402750052497d7fc6d6b508894f6b8830b", + "sha256:799e6a25932df7e6b1f8dabf63de064e2205dc309abb75956126a0453fd88e97", + "sha256:7cd1d69a387f7d5e1a5a06a87574d9ef2433847c0e78113ab51c84d3a8bcaeaa", + "sha256:87b4194f344dcd14c0f885cecb22005329b38bda10f1aaf7b9596a00ec8a4768", + "sha256:8d4d2fe2863ecddb0ba1979bdda26c8bc2ea138f5a979abe3ba80c0fa4015c91", + "sha256:94f2ed1fd51e545ebf71da1e942fe1822ee01e10d3dd2a7276d01351333b7c6b", + "sha256:9d2a7a3c1fea668d56bd91edbd5f2732e0af8feb9d2bf8d9bfacb2dea5fa9536", + "sha256:9d805bce209714b1c1fa29bfb1e42ad87e4c0a825e4b390c56a3e71593b7e8d8", + "sha256:a08ceb59db499864c58a9bf85ab6219d527d91f14c0240cc25fa2c261032b2a7", + "sha256:a981cfabf51c318a562deb4ae7deec594c07aee7cf18b4594a92c23718ec8275", + "sha256:ab6c0d738617b675183e5f28db32b5148b694ad9bba0a40c3ea26d96b431db67", + "sha256:afbddad78a98ec4d2ce08b384b81730de1ccc975b99eb663e6dac43703f36d98", + "sha256:c4bb8b0ab9f94207d07e401d24baebfc63057246b1a5e0cd9ee50df85a656871", + "sha256:ce35f947202b0b99c660221d82beb91d2e6d553d55a40b30128204e3e2c63848", + "sha256:d0022fe6a313df1c4869b5edc012d734c6519a6fffa3cf70930f32e6a1078e49", + "sha256:e7cc960959be28d064faefc0cb2aef854d46b827c004ebea7e79b5497ed83e7d", + "sha256:ee6f1848148ed3204235967613b0a32be2d77f214e9623f554511047705c1e04" ], "index": "pypi", - "version": "==1.4.3" + "version": "==1.4.4" }, "ply": { "hashes": [ @@ -264,14 +249,6 @@ ], "version": "==3.11" }, - "pyparsing": { - "hashes": [ - "sha256:c203ec8783bf771a155b207279b9bccb8dea02d8f0c9e5f8ead507bc3246ecc1", - "sha256:ef9d7589ef3c200abe66653d3f1ab1033c3c419ae9b9bdb1240a85b024efc88b" - ], - "index": "pypi", - "version": "==2.4.7" - }, "pyrsistent": { "hashes": [ "sha256:0e3e1fcc45199df76053026a51cc59ab2ea3fc7c094c6627e93b7b44cdae2c8c", @@ -322,14 +299,6 @@ ], "version": "==2022.2.1" }, - "rdflib": { - "hashes": [ - "sha256:62dc3c86d1712db0f55785baf8047f63731fa59b2682be03219cb89262065942", - "sha256:85c34a86dfc517a41e5f2425a41a0aceacc23983462b32e68610b9fad1383bca" - ], - "index": "pypi", - "version": "==6.2.0" - }, "regex": { "hashes": [ "sha256:02b6dc102123f5178796dcdb5a90f6e88895607fd1a1d115d8de1af8161ca2b4", @@ -418,22 +387,6 @@ "index": "pypi", "version": "==2.28.1" }, - "rfc3987": { - "hashes": [ - "sha256:10702b1e51e5658843460b189b185c0366d2cf4cff716f13111b0ea9fd2dce53", - "sha256:d3c4d257a560d544e9826b38bc81db676890c79ab9d7ac92b39c7a253d5ca733" - ], - "index": "pypi", - "version": "==1.3.8" - }, - "setuptools": { - "hashes": [ - "sha256:2e24e0bec025f035a2e72cdd1961119f557d78ad331bb00ff82efb2ab8da8e82", - "sha256:7732871f4f7fa58fb6bdcaeadb0161b2bd046c85905dbaa066bdcbcc81953b57" - ], - "markers": "python_version >= '3.7'", - "version": "==65.3.0" - }, "six": { "hashes": [ "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926", @@ -450,13 +403,6 @@ "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' and python_version < '4'", "version": "==1.26.12" }, - "validators": { - "hashes": [ - "sha256:24148ce4e64100a2d5e267233e23e7afeb55316b47d30faae7eb6e7292bc226a" - ], - "index": "pypi", - "version": "==0.20.0" - }, "xlrd": { "hashes": [ "sha256:6a33ee89877bd9abc1158129f6e94be74e2679636b8a205b43b85206c3f0bbdd", @@ -483,6 +429,14 @@ "index": "pypi", "version": "==1.7.0" }, + "bleach": { + "hashes": [ + "sha256:085f7f33c15bd408dd9b17a4ad77c577db66d76203e5984b1bd59baeee948b2a", + "sha256:0d03255c47eb9bd2f26aa9bb7f2107732e7e8fe195ca2f64709fcf3b0a4a085c" + ], + "markers": "python_version >= '3.7'", + "version": "==5.0.1" + }, "cached-property": { "hashes": [ "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130", @@ -525,7 +479,7 @@ "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e", "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48" ], - "index": "pypi", + "markers": "python_version >= '3.7'", "version": "==8.1.3" }, "colorama": { @@ -536,6 +490,13 @@ "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4'", "version": "==0.4.5" }, + "commonmark": { + "hashes": [ + "sha256:452f9dc859be7f06631ddcb328b6919c67984aca654e5fefb3914d54691aed60", + "sha256:da2f38c92590f83de410ba1a3cbceafbc74fee9def35f9251ba9a971d6d66fd9" + ], + "version": "==0.9.1" + }, "distlib": { "hashes": [ "sha256:14bad2d9b04d3a36127ac97f30b12a19268f211063d8f8ee4f47108896e11b46", @@ -543,6 +504,14 @@ ], "version": "==0.3.6" }, + "docutils": { + "hashes": [ + "sha256:33995a6753c30b7f577febfc2c50411fec6aac7f7ffeb7c4cfe5991072dcf9e6", + "sha256:5e1de4d849fee02c63b040a4a3fd567f4ab104defd8a5511fbbc24a8a017efbc" + ], + "markers": "python_version >= '3.7'", + "version": "==0.19" + }, "ghp-import": { "hashes": [ "sha256:8337dd7b50877f163d4c0289bc1f1c7f127550241988d568c1db512c4324a619", @@ -573,6 +542,14 @@ ], "version": "==1.1.1" }, + "jaraco.classes": { + "hashes": [ + "sha256:6745f113b0b588239ceb49532aa09c3ebb947433ce311ef2f8e3ad64ebb74594", + "sha256:e6ef6fd3fcf4579a7a019d87d1e56a883f4e4c35cfe925f86731abc58804e647" + ], + "markers": "python_version >= '3.7'", + "version": "==3.2.2" + }, "jinja2": { "hashes": [ "sha256:31351a702a408a9e7595a8fc6150fc3f43bb6bf7e319770cbc0db9df9437e852", @@ -581,6 +558,14 @@ "markers": "python_version >= '3.7'", "version": "==3.1.2" }, + "keyring": { + "hashes": [ + "sha256:3565b9e4ea004c96e158d2d332a49f466733d565bb24157a60fd2e49f41a0fd1", + "sha256:39e4f6572238d2615a82fcaa485e608b84b503cf080dc924c43bbbacb11c1c18" + ], + "markers": "python_version >= '3.7'", + "version": "==23.9.1" + }, "markdown": { "hashes": [ "sha256:cbb516f16218e643d8e0a95b309f77eb118cb138d39a4f27851e6a63581db874", @@ -675,6 +660,14 @@ "markers": "python_version >= '3.6'", "version": "==1.0.3" }, + "more-itertools": { + "hashes": [ + "sha256:1bc4f91ee5b1b31ac7ceacc17c09befe6a40a503907baf9c839c229b5095cfd2", + "sha256:c09443cd3d5438b8dafccd867a6bc1cb0894389e90cb53d227456b0b0bccb750" + ], + "markers": "python_version >= '3.5'", + "version": "==8.14.0" + }, "mypy": { "hashes": [ "sha256:02ef476f6dcb86e6f502ae39a16b93285fef97e7f1ff22932b657d1ef1f28655", @@ -764,6 +757,14 @@ ], "version": "==0.0.2" }, + "pkginfo": { + "hashes": [ + "sha256:848865108ec99d4901b2f7e84058b6e7660aae8ae10164e015a6dcf5b242a594", + "sha256:a84da4318dd86f870a9447a8c98340aa06216bfc6f2b7bdc4b8766984ae1867c" + ], + "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5'", + "version": "==1.8.3" + }, "platformdirs": { "hashes": [ "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788", @@ -777,11 +778,11 @@ "validation" ], "hashes": [ - "sha256:46402c03e36d6eadddad2a5125990e322dd74f98160c8f2dcd832b2291858a26", - "sha256:d6c9b96981b347bddd333910b753b6091a2c1eb2ef85bb373b4a67c9d91dca16" + "sha256:1736c7b0ca4f6fd7efd0a49d6e446ad85945459544228c534d60fb148e7542f7", + "sha256:67d7b25cc10f80afcb874ca51fb3f99129e221d792d05e76ec724a133c05061a" ], - "markers": "python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3'", - "version": "==0.2.3" + "markers": "python_version >= '3.7'", + "version": "==0.3.0" }, "pluggy": { "hashes": [ @@ -828,16 +829,16 @@ "sha256:c203ec8783bf771a155b207279b9bccb8dea02d8f0c9e5f8ead507bc3246ecc1", "sha256:ef9d7589ef3c200abe66653d3f1ab1033c3c419ae9b9bdb1240a85b024efc88b" ], - "index": "pypi", + "markers": "python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3'", "version": "==2.4.7" }, "pytest": { "hashes": [ - "sha256:13d0e3ccfc2b6e26be000cb6568c832ba67ba32e719443bfe725814d3c42433c", - "sha256:a06a0425453864a270bc45e71f783330a7428defb4230fb5e6a731fde06ecd45" + "sha256:1377bda3466d70b55e3f5cecfa55bb7cfcf219c7964629b967c37cf0bda818b7", + "sha256:4f365fec2dff9c1162f834d9f18af1ba13062db0c708bf7b946f8a5c76180c39" ], "index": "pypi", - "version": "==7.1.2" + "version": "==7.1.3" }, "python-dateutil": { "hashes": [ @@ -894,6 +895,14 @@ "markers": "python_version >= '3.6'", "version": "==0.1" }, + "readme-renderer": { + "hashes": [ + "sha256:16c914ca7731fd062a316a2a8e5434a175ee34661a608af771a60c881f528a34", + "sha256:96768c069729f69176f514477e57f2f8cd543fbb2cd7bad372976249fa509a0c" + ], + "markers": "python_version >= '3.7'", + "version": "==37.1" + }, "requests": { "hashes": [ "sha256:7c5599b102feddaa661c826c56ab4fee28bfd17f5abca1ebbe3e7f19d7c97983", @@ -902,6 +911,13 @@ "index": "pypi", "version": "==2.28.1" }, + "requests-toolbelt": { + "hashes": [ + "sha256:380606e1d10dc85c3bd47bf5a6095f815ec007be7a8b69c878507068df059e6f", + "sha256:968089d4584ad4ad7c171454f0a5c6dac23971e9472521ea3b6d49d610aa6fc0" + ], + "version": "==0.9.1" + }, "requirementslib": { "hashes": [ "sha256:28924cf11a2fa91adb03f8431d80c2a8c3dc386f1c48fb2be9a58e4c39072354", @@ -910,12 +926,28 @@ "markers": "python_version >= '3.7'", "version": "==1.6.9" }, + "rfc3986": { + "hashes": [ + "sha256:50b1502b60e289cb37883f3dfd34532b8873c7de9f49bb546641ce9cbd256ebd", + "sha256:97aacf9dbd4bfd829baad6e6309fa6573aaf1be3f6fa735c8ab05e46cecb261c" + ], + "markers": "python_version >= '3.7'", + "version": "==2.0.0" + }, + "rich": { + "hashes": [ + "sha256:2eb4e6894cde1e017976d2975ac210ef515d7548bc595ba20e195fb9628acdeb", + "sha256:63a5c5ce3673d3d5fbbf23cd87e11ab84b6b451436f1b7f19ec54b6bc36ed7ca" + ], + "markers": "python_version < '4' and python_full_version >= '3.6.3'", + "version": "==12.5.1" + }, "setuptools": { "hashes": [ "sha256:2e24e0bec025f035a2e72cdd1961119f557d78ad331bb00ff82efb2ab8da8e82", "sha256:7732871f4f7fa58fb6bdcaeadb0161b2bd046c85905dbaa066bdcbcc81953b57" ], - "markers": "python_version >= '3.7'", + "index": "pypi", "version": "==65.3.0" }, "six": { @@ -939,7 +971,7 @@ "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc", "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f" ], - "markers": "python_version >= '3.7'", + "markers": "python_version < '3.11'", "version": "==2.0.1" }, "tomlkit": { @@ -947,9 +979,17 @@ "sha256:25d4e2e446c453be6360c67ddfb88838cfc42026322770ba13d1fbd403a93a5c", "sha256:3235a9010fae54323e727c3ac06fb720752fe6635b3426e379daec60fbd44a83" ], - "markers": "python_version >= '3.6' and python_version < '4.0'", + "markers": "python_version >= '3.6' and python_version < '4'", "version": "==0.11.4" }, + "twine": { + "hashes": [ + "sha256:42026c18e394eac3e06693ee52010baa5313e4811d5a11050e7d48436cf41b9e", + "sha256:96b1cf12f7ae611a4a40b6ae8e9570215daff0611828f5fe1f37a16255ab24a0" + ], + "index": "pypi", + "version": "==4.0.1" + }, "types-requests": { "hashes": [ "sha256:86cb66d3de2f53eac5c09adc42cf6547eefbd0c7e1210beca1ee751c35d96083", @@ -1020,6 +1060,13 @@ "markers": "python_version >= '3.6'", "version": "==2.1.9" }, + "webencodings": { + "hashes": [ + "sha256:a0af1213f3c2226497a97e2b3aa01a7e4bee4f403f95be16fc9acd2947514a78", + "sha256:b36a1c245f2d304965eb4e0a82848379241dc04b865afcc4aab16748587e1923" + ], + "version": "==0.5.1" + }, "wheel": { "hashes": [ "sha256:4bdcd7d840138086126cd09254dc6195fb4fc6f01c050a1d7236f2630db1d22a", diff --git a/README.md b/README.md index 642d7a03c..78e5a05a4 100644 --- a/README.md +++ b/README.md @@ -11,16 +11,15 @@ For a quick start, use: ``` pip install pipenv pipenv install --dev -pipenv run make run +pipenv run make install ``` This creates a pipenv-environment, installs all dependencies, and installs `dsp-tools` from source. If you prefer getting around pipenv, use instead: ```bash -make upgrade-dist-tools make install-requirements -make run +make install ``` ## Pipenv @@ -132,15 +131,11 @@ python3 setup.py develop ## Contributing to the documentation The documentation is a collection of [markdown](https://en.wikipedia.org/wiki/Markdown) files in the `docs` folder. -After updates of the files, build and check the result with the following commands: +After updates of the files, build and check the result with the following command: ```bash -make docs-build make docs-serve ``` -To update the changes to the official documentation pages run: - -```bash -make docs-publish -``` +The documentation is published on https://docs.dasch.swiss/latest/DSP-TOOLS. During the centralized release process of all +components of the DSP software stack, the docs of dsp-tools get built from the main branch to https://docs.dasch.swiss. diff --git a/dev-requirements.txt b/dev-requirements.txt index f0021afc7..9258a8af1 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -1,19 +1,24 @@ -i https://pypi.org/simple attrs~=22.1.0; python_version >= '3.5' autopep8~=1.7.0 +bleach~=5.0.1; python_version >= '3.7' cached-property~=1.5.2 cerberus~=1.3.4 certifi~=2022.6.15; python_version >= '3.6' chardet~=5.0.0; python_version >= '3.6' charset-normalizer~=2.1.1; python_version >= '3.6' -click~=8.1.3 +click~=8.1.3; python_version >= '3.7' colorama~=0.4.5; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4' +commonmark~=0.9.1 distlib~=0.3.6 +docutils~=0.19; python_version >= '3.7' ghp-import~=2.1.0 idna~=3.3; python_version >= '3.5' importlib-metadata~=4.12.0; python_version >= '3.7' iniconfig~=1.1.1 +jaraco.classes~=3.2.2; python_version >= '3.7' jinja2~=3.1.2; python_version >= '3.7' +keyring~=23.9.1; python_version >= '3.7' markdown~=3.3.7; python_version >= '3.6' markupsafe~=2.1.1; python_version >= '3.7' mergedeep~=1.3.4; python_version >= '3.6' @@ -21,6 +26,7 @@ mkdocs~=1.3.1 mkdocs-include-markdown-plugin~=3.6.1 mkdocs-material~=8.4.2 mkdocs-material-extensions~=1.0.3; python_version >= '3.6' +more-itertools~=8.14.0; python_version >= '3.5' mypy~=0.971 mypy-extensions~=0.4.3 orderedmultidict~=1.0.1 @@ -30,30 +36,37 @@ pip~=22.2.2; python_version >= '3.7' pip-shims~=0.7.3; python_version >= '3.6' pipenv-setup~=3.2.0 pipfile~=0.0.2 +pkginfo~=1.8.3; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' platformdirs~=2.5.2; python_version >= '3.7' -plette[validation]~=0.2.3; python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3' +plette[validation]~=0.3.0; python_version >= '3.7' pluggy~=1.0.0; python_version >= '3.6' py~=1.11.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4' pycodestyle~=2.9.1; python_version >= '3.6' pygments~=2.13.0; python_version >= '3.6' pymdown-extensions~=9.5; python_version >= '3.7' -pyparsing~=2.4.7 -pytest~=7.1.2 +pyparsing~=2.4.7; python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3' +pytest~=7.1.3 python-dateutil~=2.8.2; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3' pyyaml~=6.0; python_version >= '3.6' pyyaml-env-tag~=0.1; python_version >= '3.6' +readme-renderer~=37.1; python_version >= '3.7' requests~=2.28.1 +requests-toolbelt~=0.9.1 requirementslib~=1.6.9; python_version >= '3.7' -setuptools~=65.3.0; python_version >= '3.7' +rfc3986~=2.0.0; python_version >= '3.7' +rich~=12.5.1; python_version < '4' and python_full_version >= '3.6.3' +setuptools~=65.3.0 six~=1.16.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3' toml~=0.10.2; python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3' -tomli~=2.0.1; python_version >= '3.7' -tomlkit~=0.11.4; python_version >= '3.6' and python_version < '4.0' +tomli~=2.0.1; python_version < '3.11' +tomlkit~=0.11.4; python_version >= '3.6' and python_version < '4' +twine~=4.0.1 types-requests~=2.28.9 types-urllib3~=1.26.23 typing-extensions~=4.3.0; python_version >= '3.7' urllib3~=1.26.12; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' and python_version < '4' vistir~=0.6.1; python_version not in '3.0, 3.1, 3.2, 3.3' and python_version >= '3.7' watchdog~=2.1.9; python_version >= '3.6' +webencodings~=0.5.1 wheel~=0.37.1 zipp~=3.8.1; python_version >= '3.7' diff --git a/docs/dsp-tools-information-for-developers.md b/docs/dsp-tools-information-for-developers.md index 44a8d892c..e4cc785d4 100644 --- a/docs/dsp-tools-information-for-developers.md +++ b/docs/dsp-tools-information-for-developers.md @@ -110,15 +110,11 @@ python3 setup.py develop ## Contributing to the documentation The documentation is a collection of [markdown](https://en.wikipedia.org/wiki/Markdown) files in the `docs` folder. -After updates of the files, build and check the result with the following commands: +After updates of the files, build and check the result with the following command: ```bash -make docs-build make docs-serve ``` -To update the changes to the official documentation pages run: - -```bash -make docs-publish -``` +The documentation is published on https://docs.dasch.swiss/latest/DSP-TOOLS. During the centralized release process of all +components of the DSP software stack, the docs of dsp-tools get built from the main branch to https://docs.dasch.swiss. diff --git a/docs/requirements.txt b/docs/requirements.txt index c8067a89c..85deb2412 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -1,6 +1,5 @@ mkdocs -mkdocstrings mkdocs-material mkdocs-material-extensions mkdocs-include-markdown-plugin diff --git a/requirements.txt b/requirements.txt index 9e5541383..0ffd3c7fa 100644 --- a/requirements.txt +++ b/requirements.txt @@ -3,30 +3,23 @@ argparse~=1.4.0 attrs~=22.1.0; python_version >= '3.5' certifi~=2022.6.15; python_version >= '3.6' charset-normalizer~=2.1.1; python_version >= '3.6' -click~=8.1.3 decorator~=5.1.1; python_version >= '3.5' et-xmlfile~=1.1.0; python_version >= '3.6' idna~=3.3; python_version >= '3.5' -isodate~=0.6.1 jsonpath-ng~=1.5.3 -jsonschema~=4.14.0 +jsonschema~=4.15.0 lxml~=4.9.1 networkx~=2.8.6 numpy~=1.23.2; python_version < '3.10' and platform_machine != 'aarch64' and platform_machine != 'arm64' openpyxl~=3.0.10 -pandas~=1.4.3 +pandas~=1.4.4 ply~=3.11 -pyparsing~=2.4.7 pyrsistent~=0.18.1; python_version >= '3.7' pystrict~=1.3 python-dateutil~=2.8.2; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3' pytz~=2022.2.1 -rdflib~=6.2.0 regex~=2022.8.17 requests~=2.28.1 -rfc3987~=1.3.8 -setuptools~=65.3.0; python_version >= '3.7' six~=1.16.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3' urllib3~=1.26.12; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' and python_version < '4' -validators~=0.20.0 xlrd~=2.0.1 diff --git a/setup.py b/setup.py index ad461ec3e..617e2bbd4 100644 --- a/setup.py +++ b/setup.py @@ -4,28 +4,49 @@ long_description = fh.read() setup( - name='dsp-tools', - version='1.17.1', - description='A Python library and tools for the DaSCH Service Platform', + name="dsp-tools", + version="1.17.1", + description="A Python library and tools for the DaSCH Service Platform", long_description=long_description, long_description_content_type="text/markdown", - url='https://github.com/dasch-swiss/dsp-tools', - author='DaSCH - Swiss National Data and Service Center for the Humanities', - author_email='support@dasch.swiss', - license='GPLv3', + url="https://github.com/dasch-swiss/dsp-tools", + author="DaSCH - Swiss National Data and Service Center for the Humanities", + author_email="support@dasch.swiss", + license="GPLv3", packages=find_packages(), classifiers=[ "Programming Language :: Python :: 3", "License :: OSI Approved :: GNU General Public License v3 (GPLv3)", "Operating System :: OS Independent", ], - python_requires='>=3.9.0', - install_requires=['argparse~=1.4.0', "attrs~=22.1.0; python_version >= '3.5'", "certifi~=2022.6.15; python_version >= '3.6'", "charset-normalizer~=2.1.1; python_version >= '3.6'", 'click~=8.1.3', "decorator~=5.1.1; python_version >= '3.5'", "et-xmlfile~=1.1.0; python_version >= '3.6'", "idna~=3.3; python_version >= '3.5'", 'isodate~=0.6.1', 'jsonpath-ng~=1.5.3', 'jsonschema~=4.14.0', 'lxml~=4.9.1', 'networkx~=2.8.6', "numpy~=1.23.2; python_version < '3.10' and platform_machine != 'aarch64' and platform_machine != 'arm64'", 'openpyxl~=3.0.10', 'pandas~=1.4.3', 'ply~=3.11', 'pyparsing~=2.4.7', "pyrsistent~=0.18.1; python_version >= '3.7'", 'pystrict~=1.3', "python-dateutil~=2.8.2; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'", 'pytz~=2022.2.1', 'rdflib~=6.2.0', 'regex~=2022.8.17', 'requests~=2.28.1', 'rfc3987~=1.3.8', "setuptools~=65.3.0; python_version >= '3.7'", "six~=1.16.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'", "urllib3~=1.26.12; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' and python_version < '4'", 'validators~=0.20.0', 'xlrd~=2.0.1' - ], + python_requires=">=3.9.0", + install_requires=[ + 'argparse~=1.4.0', + "attrs~=22.1.0; python_version >= '3.5'", + "certifi~=2022.6.15; python_version >= '3.6'", + "charset-normalizer~=2.1.1; python_version >= '3.6'", + "decorator~=5.1.1; python_version >= '3.5'", + "et-xmlfile~=1.1.0; python_version >= '3.6'", + "idna~=3.3; python_version >= '3.5'", + 'jsonpath-ng~=1.5.3', + 'jsonschema~=4.15.0', + 'lxml~=4.9.1', + 'networkx~=2.8.6', + "numpy~=1.23.2; python_version < '3.10' and platform_machine != 'aarch64' and platform_machine != 'arm64'", + 'openpyxl~=3.0.10', + 'pandas~=1.4.4', + 'ply~=3.11', + "pyrsistent~=0.18.1; python_version >= '3.7'", + 'pystrict~=1.3', + "python-dateutil~=2.8.2; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'", + 'pytz~=2022.2.1', + 'regex~=2022.8.17', + 'requests~=2.28.1', + "six~=1.16.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'", + "urllib3~=1.26.12; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' and python_version < '4'", + 'xlrd~=2.0.1'], entry_points={ - 'console_scripts': [ - 'dsp-tools=knora.dsp_tools:main' - ], + "console_scripts": ["dsp-tools=knora.dsp_tools:main"], }, include_package_data=True, zip_safe=False,