diff --git a/doc/conf.py b/doc/conf.py index 327b3ca..e386788 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -1,20 +1,29 @@ # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -from importlib.util import find_spec from sys import path as sys_path from os.path import abspath from pathlib import Path -from json import loads from pyTooling.Packaging import extractVersionInformation +# ============================================================================== +# Project configuration +# ============================================================================== +githubNamespace = "pyTooling" +githubProject = "Actions" +pythonProject = "pyDummy" +directoryName = pythonProject.replace('.', '/') + + +# ============================================================================== +# Project paths +# ============================================================================== ROOT = Path(__file__).resolve().parent sys_path.insert(0, abspath(".")) sys_path.insert(0, abspath("..")) -sys_path.insert(0, abspath("../pyDummy")) -# sys_path.insert(0, abspath("_extensions")) +sys_path.insert(0, abspath(f"../{directoryName}")) # ============================================================================== @@ -23,11 +32,7 @@ sys_path.insert(0, abspath("../pyDummy")) # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the # built documents. -githubNamespace = "pyTooling" -githubProject = "Actions" -project = "pyDummy" - -packageInformationFile = Path(f"../{project}/__init__.py") +packageInformationFile = Path(f"../{directoryName}/__init__.py") versionInformation = extractVersionInformation(packageInformationFile) author = versionInformation.Author @@ -105,7 +110,7 @@ html_last_updated_fmt = "%d.%m.%Y" # Python settings # ============================================================================== modindex_common_prefix = [ - f"{project}." + f"{pythonProject}." ] # ============================================================================== @@ -257,13 +262,13 @@ todo_link_only = True # ============================================================================== # report_unittest_testsuites = { # "src": { -# "name": f"{project}", +# "name": f"{pythonProject}", # "xml_report": "../report/unit/unittest.xml", # } # } # report_codecov_packages = { # "src": { -# "name": f"{project}", +# "name": f"{pythonProject}", # "json_report": "../report/coverage/coverage.json", # "fail_below": 80, # "levels": "default" @@ -271,8 +276,8 @@ todo_link_only = True # } # report_doccov_packages = { # "src": { -# "name": f"{project}", -# "directory": f"../{project}", +# "name": f"{pythonProject}", +# "directory": f"../{directoryName}", # "fail_below": 80, # "levels": "default" # } @@ -289,17 +294,17 @@ todo_link_only = True # AutoAPI.Sphinx # ============================================================================== autoapi_modules = { - f"{project}": { + f"{pythonProject}": { "template": "package", - "output": project, + "output": pythonProject, "override": True } } -for directory in [mod for mod in Path(f"../{project}").iterdir() if mod.is_dir() and mod.name != "__pycache__"]: - print(f"Adding module rule for '{project}.{directory.name}'") - autoapi_modules[f"{project}.{directory.name}"] = { +for directory in [mod for mod in Path(f"../{directoryName}").iterdir() if mod.is_dir() and mod.name != "__pycache__"]: + print(f"Adding module rule for '{pythonProject}.{directory.name}'") + autoapi_modules[f"{pythonProject}.{directory.name}"] = { "template": "module", - "output": project, + "output": pythonProject, "override": True } diff --git a/doc/requirements.txt b/doc/requirements.txt index 2027f4c..709b41b 100644 --- a/doc/requirements.txt +++ b/doc/requirements.txt @@ -1,6 +1,6 @@ -r ../requirements.txt -pyTooling ~= 8.4 +pyTooling ~= 8.5 # Enforce latest version on ReadTheDocs sphinx ~= 8.2 diff --git a/pyproject.toml b/pyproject.toml index 11fc317..eb223ab 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -2,7 +2,7 @@ requires = [ "setuptools >= 80.0", "wheel ~= 0.45", - "pyTooling ~= 8.4" + "pyTooling ~= 8.5" ] build-backend = "setuptools.build_meta" diff --git a/requirements.txt b/requirements.txt index 3d2b3a7..3781d6d 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1 +1 @@ -pyTooling ~= 8.4 +pyTooling ~= 8.5 diff --git a/run.ps1 b/run.ps1 index e18144f..f55babc 100644 --- a/run.ps1 +++ b/run.ps1 @@ -88,7 +88,7 @@ if ($build) rm -Force .\build\bdist.win-amd64 rm -Force .\build\lib Write-Host -ForegroundColor Yellow "[live][BUILD] Building $PackageName package as wheel ..." - py -3.13 -m build --wheel + py -3.13 -m build --wheel --no-isolation Write-Host -ForegroundColor Yellow "[live][BUILD] Building wheel finished" } diff --git a/setup.py b/setup.py index af9a65c..f6b637a 100644 --- a/setup.py +++ b/setup.py @@ -39,13 +39,16 @@ packageName = "pyDummy" packageDirectory = packageName packageInformationFile = Path(f"{packageDirectory}/__init__.py") -setup(**DescribePythonPackageHostedOnGitHub( - packageName=packageName, - description="pyDummy is a test package to verify GitHub actions for Python projects.", - gitHubNamespace=gitHubNamespace, - unittestRequirementsFile=Path("tests/requirements.txt"), - sourceFileWithVersion=packageInformationFile, - dataFiles={ - packageName: ["py.typed"] - } -)) +setup( + **DescribePythonPackageHostedOnGitHub( + packageName=packageName, + description="pyDummy is a test package to verify GitHub actions for Python projects.", + gitHubNamespace=gitHubNamespace, + unittestRequirementsFile=Path("tests/requirements.txt"), + sourceFileWithVersion=packageInformationFile, + dataFiles={ + packageName: ["py.typed"] + }, + debug=True + ) +) diff --git a/tests/requirements.txt b/tests/requirements.txt index dc267c1..f83dca0 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -1,13 +1,13 @@ -r ../requirements.txt # Coverage collection -Coverage ~= 7.8 +Coverage ~= 7.9 # Test Runner -pytest ~= 8.3 -pytest-cov ~= 6.1 +pytest ~= 8.4 +pytest-cov ~= 6.2 # Static Type Checking -mypy ~= 1.15 +mypy ~= 1.16 typing_extensions ~= 4.13 lxml ~= 5.4