diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 7ca8747..c78e425 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [3.8] + python-version: [3.13] steps: - uses: actions/checkout@v2 @@ -30,4 +30,5 @@ jobs: flake8 . --count --exit-zero --max-complexity=10 --max-line-length=180 --statistics - name: Test with pytest run: | - python setup.py test \ No newline at end of file + pip install pytest + pytest tests \ No newline at end of file diff --git a/README.md b/README.md index e45e491..4212399 100644 --- a/README.md +++ b/README.md @@ -8,12 +8,6 @@ Provide for each resource endpoint an rest api client. ## Module workspace Provide a fluent way to create or update an Airlock Gateway configuration. -## Documentation -For full documentation and tutorials, trigger: -``` -python setup.py build_sphinx -``` - ## Requirements - Python 3.8 or higher - virutalenv @@ -22,7 +16,7 @@ python setup.py build_sphinx ``` python3 -m venv env source env/bin/activate -pip install -r requirement.txt +pip install -r requirements.txt pip install -e . ``` @@ -39,9 +33,8 @@ python setup.py sdist bdist_wheel ``` ## Contributing -Please use the [GitHub issue tracker](https://github.com/orltom/airlock-gateway-client-python/issues) to submit bugs or request features. +Contributions are welcome in any form, be it code, logic, documentation, examples, requests, bug reports, +ideas or anything else that will help this project move forward. ## Disclaimer -Copyright Orlando Tomás. - -Distributed under the terms of the MIT license, airlock-gateway-client is free and open source software. +This project is licensed under the MIT License. See the LICENSE file for more details. diff --git a/client/crud_client.py b/client/crud_client.py index d1b624a..3bc8a82 100644 --- a/client/crud_client.py +++ b/client/crud_client.py @@ -1,3 +1,5 @@ +from .airlock_session import AirlockSession + class ResourceRUClient: def __init__(self, session: type(AirlockSession), base_path: str): self.client = session diff --git a/requirements.txt b/requirements.txt index a648356..2a4f5b8 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,5 +1,3 @@ -requests==2.25.0 -sphinx -sphinx_rtd_theme -pytest -wheel \ No newline at end of file +requests==2.32.0 +wheel +setuptools>=42.0.0 diff --git a/setup.py b/setup.py index f2d46e2..3496e6d 100644 --- a/setup.py +++ b/setup.py @@ -2,19 +2,6 @@ # -*- coding: utf-8 -*- from version import __version__ from setuptools import setup -from sphinx.setup_command import BuildDoc -import subprocess - - -class BuildDocApiDoc(BuildDoc, object): - """Execute sphinx-apidoc before trigger the sphinx-build""" - - def run(self): - sphinx_apidoc = subprocess.run(["sphinx-apidoc", "-f", "-o", "doc/source/", "client/"]) - if sphinx_apidoc.returncode != 0: - raise Exception("sphinx-apidoc failed.") - super(BuildDocApiDoc, self).run() - setup( version=__version__, @@ -22,19 +9,8 @@ def run(self): 'client', 'workspace' ], - python_requires='>=3.8', - install_requires=[ - 'requests==2.24.0' - ], + python_requires='>=3.13', setup_requires=[ - 'sphinx', - 'sphinx_rtd_theme', 'pytest-runner' ], - tests_require=[ - 'pytest' - ], - cmdclass={ - 'build_sphinx': BuildDocApiDoc - } )