Skip to content

Commit

Permalink
Feature/134 gh actions pyproj (#135)
Browse files Browse the repository at this point in the history
* #134 gh actions pyproj

* #134 gh actions pyproj

---------

Co-authored-by: Tim Van Campenhout <[email protected]>
  • Loading branch information
vancamti and Tim Van Campenhout authored Sep 23, 2024
1 parent e9c77e2 commit 47ecbda
Show file tree
Hide file tree
Showing 10 changed files with 215 additions and 98 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/skosprovider_atramhasis.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: skosprovider_atramhasis backend tests
on:
push:
paths:
- skosprovider_atramhasis/**
- tests/**
- skosprovider_atramhasis.yaml
- pyproject.toml
- requirements*.txt
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [ "3.10", "3.11", "3.12" ]

steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
# You can test your matrix by printing the current Python version
- name: Display Python version
run: python -c "import sys; print(sys.version)"

- name: Install python requirements
env:
HATCH_BUILD_NO_HOOKS: true
working-directory: ./
run: |
pip --version
pip install pip-tools
pip-sync requirements-dev.txt
pip install -e .
- name: Python tests
run: pytest tests --exitfirst --capture=no -vvv --full-trace
13 changes: 0 additions & 13 deletions .travis.yml

This file was deleted.

8 changes: 4 additions & 4 deletions docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -85,17 +85,17 @@ qthelp:
@echo
@echo "Build finished; now you can run "qcollectiongenerator" with the" \
".qhcp project file in $(BUILDDIR)/qthelp, like this:"
@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/skosprovider_getty.qhcp"
@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/skosprovider_atramhasis.qhcp"
@echo "To view the help file:"
@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/skosprovider_getty.qhc"
@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/skosprovider_atramhasis.qhc"

devhelp:
$(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp
@echo
@echo "Build finished."
@echo "To view the help file:"
@echo "# mkdir -p $$HOME/.local/share/devhelp/skosprovider_getty"
@echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/skosprovider_getty"
@echo "# mkdir -p $$HOME/.local/share/devhelp/skosprovider_atramhasis"
@echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/skosprovider_atramhasis"
@echo "# devhelp"

epub:
Expand Down
4 changes: 2 additions & 2 deletions docs/make.bat
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,9 @@ if "%1" == "qthelp" (
echo.
echo.Build finished; now you can run "qcollectiongenerator" with the ^
.qhcp project file in %BUILDDIR%/qthelp, like this:
echo.^> qcollectiongenerator %BUILDDIR%\qthelp\skosprovider_getty.qhcp
echo.^> qcollectiongenerator %BUILDDIR%\qthelp\skosprovider_atramhasis.qhcp
echo.To view the help file:
echo.^> assistant -collectionFile %BUILDDIR%\qthelp\skosprovider_getty.ghc
echo.^> assistant -collectionFile %BUILDDIR%\qthelp\skosprovider_atramhasis.ghc
goto end
)

Expand Down
65 changes: 65 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
[build-system]
requires = ["hatchling", "hatch-fancy-pypi-readme"]
build-backend = "hatchling.build"

[project]
version = "1.0.0"
name = "skosprovider_atramhasis"
dynamic = ["readme"]
authors = [
{ name = "Flanders Heritage Agency", email = "[email protected]" },
]
license = "MIT"
description = "Skosprovider implementation of Atramhasis Vocabularies"
requires-python = ">=3.10,<3.13"
keywords = ["rdf", "skos", "skosprovider", "vocabularies", "thesauri"]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Programming Language :: Python",
"Framework :: Pyramid",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: WSGI :: Application",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
dependencies = [
"requests==2.32.3",
"skosprovider==1.1.0",
"dogpile.cache==1.1.4",
]

[project.urls]
History = "https://github.com/OnroerendErfgoed/skosprovider_atramhasis/blob/master/CHANGES.rst"
Tracker = "https://github.com/OnroerendErfgoed/skosprovider_atramhasis/issues"
Source = "https://github.com/OnroerendErfgoed/skosprovider_atramhasis"
Documentation = "https://skosprovider-atramhasis.readthedocs.io/en/latest/"

[project.optional-dependencies]
dev = [
"uv==0.4.1",
"pytest==8.3.3",
"responses==0.25.3",
"pytest-cov==5.0.0",
"coveralls==4.0.1",
]

##
# Build tool specific
##
[tool.hatch.build.targets.wheel]
# In the wheel we want to have skosprovider_atramhasis in the root as python module.
only-include = [
"/skosprovider_atramhasis",
]

[tool.hatch.metadata]
# This allows us to use github links as dependencies
allow-direct-references = true

[tool.hatch.metadata.hooks.fancy-pypi-readme]
content-type = "text/x-rst"
fragments = [
{ path = "README.rst" },
{ path = "CHANGES.rst" },
]
81 changes: 69 additions & 12 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -1,12 +1,69 @@
# Runtime requirements
--requirement requirements.txt

# Documentation
Sphinx==4.3.1

# Unit testing
tox==3.24.4
pytest==6.2.5
responses==0.16.0
pytest-cov==3.0.0
coveralls==3.3.1
cachetools==5.5.0
# via pyld
certifi==2024.8.30
# via requests
charset-normalizer==3.3.2
# via requests
coverage==7.6.1
# via
# coveralls
# pytest-cov
coveralls==4.0.1
# via skosprovider-atramhasis (pyproject.toml)
decorator==5.1.1
# via dogpile-cache
docopt==0.6.2
# via coveralls
dogpile-cache==1.1.4
# via skosprovider-atramhasis (pyproject.toml)
frozendict==2.4.4
# via pyld
html5lib==1.1
# via skosprovider
idna==3.10
# via requests
iniconfig==2.0.0
# via pytest
language-tags==1.2.0
# via skosprovider
lxml==5.3.0
# via pyld
packaging==24.1
# via pytest
pbr==6.1.0
# via stevedore
pluggy==1.5.0
# via pytest
pyld==2.0.4
# via skosprovider
pytest==8.3.3
# via
# skosprovider-atramhasis (pyproject.toml)
# pytest-cov
pytest-cov==5.0.0
# via skosprovider-atramhasis (pyproject.toml)
pyyaml==6.0.2
# via responses
requests==2.32.3
# via
# skosprovider-atramhasis (pyproject.toml)
# coveralls
# responses
responses==0.25.3
# via skosprovider-atramhasis (pyproject.toml)
rfc3987==1.3.8
# via skosprovider
six==1.16.0
# via html5lib
skosprovider==1.1.0
# via skosprovider-atramhasis (pyproject.toml)
stevedore==5.3.0
# via dogpile-cache
urllib3==2.2.3
# via
# requests
# responses
uv==0.4.1
# via skosprovider-atramhasis (pyproject.toml)
webencodings==0.5.1
# via html5lib
40 changes: 37 additions & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,38 @@
requests==2.26.0
cachetools==5.5.0
# via pyld
certifi==2024.8.30
# via requests
charset-normalizer==3.3.2
# via requests
decorator==5.1.1
# via dogpile-cache
dogpile-cache==1.1.4
# via skosprovider-atramhasis (pyproject.toml)
frozendict==2.4.4
# via pyld
html5lib==1.1
# via skosprovider
idna==3.10
# via requests
language-tags==1.2.0
# via skosprovider
lxml==5.3.0
# via pyld
pbr==6.1.0
# via stevedore
pyld==2.0.4
# via skosprovider
requests==2.32.3
# via skosprovider-atramhasis (pyproject.toml)
rfc3987==1.3.8
# via skosprovider
six==1.16.0
# via html5lib
skosprovider==1.1.0
# -e git+https://github.com/koenedaele/skosprovider.git@DEV_0.7.0#egg=skosprovider
dogpile.cache==1.1.4
# via skosprovider-atramhasis (pyproject.toml)
stevedore==5.3.0
# via dogpile-cache
urllib3==2.2.3
# via requests
webencodings==0.5.1
# via html5lib
2 changes: 0 additions & 2 deletions setup.cfg

This file was deleted.

41 changes: 0 additions & 41 deletions setup.py

This file was deleted.

21 changes: 0 additions & 21 deletions tox.ini

This file was deleted.

0 comments on commit 47ecbda

Please sign in to comment.