Skip to content

Commit

Permalink
v0.13.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Paebbels authored Apr 10, 2024
2 parents 8456bbb + 2dc6a42 commit af0c017
Show file tree
Hide file tree
Showing 8 changed files with 35 additions and 36 deletions.
18 changes: 9 additions & 9 deletions doc/Dependency.rst
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ PyPI (see :ref:`INSTALL`).
+---------------------------------------------------------------------------+-------------+-------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+
| **Package** | **Version** | **License** | **Dependencies** |
+===========================================================================+=============+===========================================================================================+========================================================================================================================================================+
| `pyTooling[terminal] <https://GitHub.com/pyTooling/pyTooling>`__ | ≥6.0.0 | `Apache License, 2.0 <https://GitHub.com/pyTooling/pyTooling/blob/main/LICENSE.md>`__ | * colorama |
| `pyTooling[terminal] <https://GitHub.com/pyTooling/pyTooling>`__ | ≥6.1.0 | `Apache License, 2.0 <https://GitHub.com/pyTooling/pyTooling/blob/main/LICENSE.md>`__ | * colorama |
+---------------------------------------------------------------------------+--------------+------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+
| `ruamel.yaml <https://sourceforge.net/projects/ruamel-yaml/>`__ | ≥0.18 | `MIT <https://sourceforge.net/p/ruamel-yaml/code/ci/default/tree/LICENSE>`__ | *Not yet evaluated.* |
+---------------------------------------------------------------------------+--------------+------------------------------------------------------------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------+
Expand Down Expand Up @@ -94,17 +94,17 @@ the mandatory dependencies too.
+---------------------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
| **Package** | **Version** | **License** | **Dependencies** |
+=====================================================================+=============+========================================================================================+======================+
| `pytest <https://GitHub.com/pytest-dev/pytest>`__ |7.4.0 | `MIT <https://GitHub.com/pytest-dev/pytest/blob/master/LICENSE>`__ | *Not yet evaluated.* |
| `pytest <https://GitHub.com/pytest-dev/pytest>`__ |8.1 | `MIT <https://GitHub.com/pytest-dev/pytest/blob/master/LICENSE>`__ | *Not yet evaluated.* |
+---------------------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
| `pytest-cov <https://GitHub.com/pytest-dev/pytest-cov>`__ |4.1.0 | `MIT <https://GitHub.com/pytest-dev/pytest-cov/blob/master/LICENSE>`__ | *Not yet evaluated.* |
| `pytest-cov <https://GitHub.com/pytest-dev/pytest-cov>`__ |5.0 | `MIT <https://GitHub.com/pytest-dev/pytest-cov/blob/master/LICENSE>`__ | *Not yet evaluated.* |
+---------------------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
| `Coverage <https://GitHub.com/nedbat/coveragepy>`__ | ≥7.4 | `Apache License, 2.0 <https://GitHub.com/nedbat/coveragepy/blob/master/LICENSE.txt>`__ | *Not yet evaluated.* |
+---------------------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
| `mypy <https://GitHub.com/python/mypy>`__ | ≥1.8.0 | `MIT <https://GitHub.com/python/mypy/blob/master/LICENSE>`__ | *Not yet evaluated.* |
| `mypy <https://GitHub.com/python/mypy>`__ | ≥1.9 | `MIT <https://GitHub.com/python/mypy/blob/master/LICENSE>`__ | *Not yet evaluated.* |
+---------------------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
| `typing-extensions <https://GitHub.com/python/typing_extensions>`__ | ≥4.9.0 | `PSF-2.0 <https://github.com/python/typing_extensions/blob/main/LICENSE>`__ | *Not yet evaluated.* |
| `typing-extensions <https://GitHub.com/python/typing_extensions>`__ | ≥4.11 | `PSF-2.0 <https://github.com/python/typing_extensions/blob/main/LICENSE>`__ | *Not yet evaluated.* |
+---------------------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
| `lxml <https://GitHub.com/lxml/lxml>`__ | ≥5.0 | `BSD 3-Clause <https://GitHub.com/lxml/lxml/blob/master/LICENSE.txt>`__ | *Not yet evaluated.* |
| `lxml <https://GitHub.com/lxml/lxml>`__ | ≥5.1 | `BSD 3-Clause <https://GitHub.com/lxml/lxml/blob/master/LICENSE.txt>`__ | *Not yet evaluated.* |
+---------------------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+


Expand Down Expand Up @@ -144,9 +144,9 @@ the mandatory dependencies too.
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
| **Package** | **Version** | **License** | **Dependencies** |
+=================================================================================================+==============+==========================================================================================================+======================================================================================================================================================+
| `pyTooling <https://GitHub.com/pyTooling/pyTooling>`__ | ≥6.0.0 | `Apache License, 2.0 <https://GitHub.com/pyTooling/pyTooling/blob/main/LICENSE.md>`__ | *None* |
| `pyTooling <https://GitHub.com/pyTooling/pyTooling>`__ | ≥6.1.0 | `Apache License, 2.0 <https://GitHub.com/pyTooling/pyTooling/blob/main/LICENSE.md>`__ | *None* |
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
| `Sphinx <https://GitHub.com/sphinx-doc/sphinx>`__ |5.3.0 | `BSD 3-Clause <https://GitHub.com/sphinx-doc/sphinx/blob/master/LICENSE>`__ | *Not yet evaluated.* |
| `Sphinx <https://GitHub.com/sphinx-doc/sphinx>`__ |7.2.0 | `BSD 3-Clause <https://GitHub.com/sphinx-doc/sphinx/blob/master/LICENSE>`__ | *Not yet evaluated.* |
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
| `sphinxcontrib-mermaid <https://GitHub.com/mgaitan/sphinxcontrib-mermaid>`__ | ≥0.9.2 | `BSD <https://GitHub.com/mgaitan/sphinxcontrib-mermaid/blob/master/LICENSE.rst>`__ | *Not yet evaluated.* |
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
Expand Down Expand Up @@ -201,7 +201,7 @@ install the mandatory dependencies too.
+----------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
| **Package** | **Version** | **License** | **Dependencies** |
+============================================================================+==============+==========================================================================================================+======================================================================================================================================================+
| `pyTooling <https://GitHub.com/pyTooling/pyTooling>`__ | ≥6.0.0 | `Apache License, 2.0 <https://GitHub.com/pyTooling/pyTooling/blob/main/LICENSE.md>`__ | *None* |
| `pyTooling <https://GitHub.com/pyTooling/pyTooling>`__ | ≥6.1.0 | `Apache License, 2.0 <https://GitHub.com/pyTooling/pyTooling/blob/main/LICENSE.md>`__ | *None* |
+----------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
| `wheel <https://GitHub.com/pypa/wheel>`__ | ≥0.40.0 | `MIT <https://github.com/pypa/wheel/blob/main/LICENSE.txt>`__ | *Not yet evaluated.* |
+----------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------+
Expand Down
8 changes: 4 additions & 4 deletions doc/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
-r ../requirements.txt

pyTooling ~= 6.0
pyTooling ~= 6.1
colorama >= 0.4.6

# Enforce latest version on ReadTheDocs
sphinx >= 7.2, < 8.0
docutils >= 0.18.0, < 0.19.0
sphinx ~= 7.2
docutils ~= 0.18.0

# ReadTheDocs Theme
sphinx_rtd_theme ~= 2.0.0
Expand All @@ -20,7 +20,7 @@ autoapi >= 2.0.1
sphinx_design >= 0.5.0
sphinx-copybutton >= 0.5.2
sphinx_autodoc_typehints >= 1.25.2
sphinx_reports ~= 0.5
sphinx_reports ~= 0.6
# changelog>=0.3.5

# BuildTheDocs Extensions (mostly patched Sphinx extensions)
2 changes: 1 addition & 1 deletion pyVersioning/Configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def __init__(self, root: 'Base', parent: 'Base', settings: Dict) -> None:

self.name = settings["name"]
self.variant = settings["variant"] if "variant" in settings else None
self.version = SemanticVersion(settings["version"]) if "version" in settings else None
self.version = SemanticVersion.Parse(settings["version"]) if "version" in settings else None

class Build(Base):
class Compiler(Base):
Expand Down
16 changes: 8 additions & 8 deletions pyVersioning/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
__email__ = "[email protected]"
__copyright__ = "2020-2024, Patrick Lehmann"
__license__ = "Apache License, Version 2.0"
__version__ = "0.13.1"
__version__ = "0.13.2"
__keywords__ = ["Python3", "Template", "Versioning", "Git"]

from dataclasses import make_dataclass
Expand Down Expand Up @@ -241,9 +241,9 @@ def __init__(self, name: str, version: Union[str, SemanticVersion, None] = None,
if isinstance(version, SemanticVersion):
self._version = version
elif isinstance(version, str):
self._version = SemanticVersion(version)
self._version = SemanticVersion.Parse(version)
elif version is None:
self._version = SemanticVersion("v0.0.0")
self._version = SemanticVersion.Parse("v0.0.0")

@readonly
def name(self) -> str:
Expand Down Expand Up @@ -280,9 +280,9 @@ def __init__(self, name: str, version: Union[str, SemanticVersion] = "", configu
if isinstance(version, SemanticVersion):
self._version = version
elif isinstance(version, str):
self._version = SemanticVersion(version)
self._version = SemanticVersion.Parse(version)
elif version is None:
self._version = SemanticVersion("v0.0.0")
self._version = SemanticVersion.Parse("v0.0.0")

@readonly
def name(self) -> str:
Expand Down Expand Up @@ -421,7 +421,7 @@ def CollectData(self) -> None:
else:
self._service = WorkStation()

self._variables["tool"] = Tool("pyVersioning", SemanticVersion(__version__))
self._variables["tool"] = Tool("pyVersioning", SemanticVersion.Parse(__version__))
self._variables["git"] = self.GetGitInformation()
self._variables["env"] = self.GetEnvironment()
self._variables["platform"] = self._service.GetPlatform()
Expand All @@ -436,7 +436,7 @@ def GetVersion(self, config: Configuration.Project) -> SemanticVersion:
if config.version is not None:
return config.version
else:
return SemanticVersion("0.0.0")
return SemanticVersion.Parse("0.0.0")

def GetGitInformation(self) -> Git:
return Git(
Expand Down Expand Up @@ -616,7 +616,7 @@ def GetBuild(self, config: Configuration.Build) -> Build:
def GetCompiler(self, config: Configuration.Build.Compiler) -> Compiler:
return Compiler(
name=config.name,
version=SemanticVersion(config.version),
version=SemanticVersion.Parse(config.version),
configuration=config.configuration,
options=config.options
)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
requires = [
"setuptools >= 69.0.0",
"wheel >= 0.40.0",
"pyTooling ~= 6.0"
"pyTooling ~= 6.1"
]
build-backend = "setuptools.build_meta"

Expand Down
5 changes: 2 additions & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
ruamel.yaml >= 0.18.5

pyTooling[terminal] ~= 6.0
ruamel.yaml ~= 0.18.6
pyTooling[terminal] ~= 6.1
12 changes: 6 additions & 6 deletions tests/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
-r ../requirements.txt

# Coverage collection
Coverage >= 7.4
Coverage ~= 7.4

# Test Runner
pytest >= 7.4.0
pytest-cov >= 4.1.0
pytest ~= 8.1
pytest-cov ~= 5.0

# Static Type Checking
mypy >= 1.8.0
typing_extensions >= 4.9.0
lxml >= 5.0
mypy ~= 1.9
typing_extensions ~= 4.11
lxml ~= 5.1
8 changes: 4 additions & 4 deletions tests/unit/Database.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def test_ProjectName(self) -> None:

self.assertEqual(project.name, name)
self.assertEqual(project.variant, variant)
self.assertEqual(project.version, SemanticVersion("0.0.0"))
self.assertEqual(project.version, SemanticVersion.Parse("0.0.0"))

def test_ProjectName_VariantName(self) -> None:
name = "Project 1"
Expand All @@ -61,7 +61,7 @@ def test_ProjectName_VariantName(self) -> None:

self.assertEqual(project.name, name)
self.assertEqual(project.variant, variant)
self.assertEqual(project.version, SemanticVersion("0.0.0"))
self.assertEqual(project.version, SemanticVersion.Parse("0.0.0"))

def test_ProjectName_VersionAsString(self) -> None:
name = "Project 1"
Expand All @@ -72,12 +72,12 @@ def test_ProjectName_VersionAsString(self) -> None:

self.assertEqual(project.name, name)
self.assertEqual(project.variant, variant)
self.assertEqual(project.version, SemanticVersion(version))
self.assertEqual(project.version, SemanticVersion.Parse(version))

def test_ProjectName_VersionAsVersion(self) -> None:
name = "Project 1"
variant = ""
version = SemanticVersion("1.3.2")
version = SemanticVersion.Parse("1.3.2")

project = pyV_Project(name, version)

Expand Down

0 comments on commit af0c017

Please sign in to comment.