Skip to content

Commit

Permalink
Merge branch other/next-release into main
Browse files Browse the repository at this point in the history
  • Loading branch information
anionDev committed Dec 29, 2024
2 parents bb5e9e3 + 524b14f commit c21b152
Show file tree
Hide file tree
Showing 9 changed files with 33 additions and 10 deletions.
6 changes: 6 additions & 0 deletions Other/Resources/Changelog/v3.5.42.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Release notes

## Changes

- Improved error-message in git_commit_is_ancestor.
- Update in build_specific_codeunits.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Version;SupportBegin;SupportEnd
3.5.39;2024-12-26T09:47:38;2025-12-11T09:47:38
3.5.40;2024-12-26T10:05:12;2025-12-11T10:05:12
3.5.41;2024-12-28T15:51:59;2027-01-28T15:51:59
3.5.41;2024-12-28T15:51:59;2027-01-28T15:51:59
3.5.42;2024-12-29T01:35:51;2027-01-29T01:35:51
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<coverage version="1.0" date="2024-12-29_01-51-15" tag="v3.5.42">
<assembly name="ScriptCollection">
<class name="Executables.py" coveredlines="0" coverablelines="285" totallines="389" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
<class name="GeneralUtilities.py" coveredlines="480" coverablelines="752" totallines="891" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
<class name="ProcessesRunner.py" coveredlines="0" coverablelines="31" totallines="41" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
<class name="ProgramRunnerBase.py" coveredlines="22" coverablelines="28" totallines="47" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
<class name="ProgramRunnerEpew.py" coveredlines="40" coverablelines="103" totallines="122" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
<class name="ProgramRunnerPopen.py" coveredlines="23" coverablelines="38" totallines="51" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
<class name="RPStream.py" coveredlines="0" coverablelines="32" totallines="42" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
<class name="ScriptCollectionCore.py" coveredlines="571" coverablelines="1430" totallines="1917" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
<class name="TasksForCommonProjectStructure.py" coveredlines="483" coverablelines="2313" totallines="2978" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
<class name="UpdateCertificates.py" coveredlines="0" coverablelines="105" totallines="126" coveredbranches="0" totalbranches="0" coveredcodeelements="0" totalcodeelements="0" />
</assembly>
</coverage>
2 changes: 1 addition & 1 deletion ScriptCollection/ScriptCollection.codeunit.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<cps:codeunit xmlns:cps="https://projects.aniondev.de/PublicProjects/Common/ProjectTemplates/-/tree/main/Conventions/RepositoryStructure/CommonProjectStructure" codeunitspecificationversion="2.9.4"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://projects.aniondev.de/PublicProjects/Common/ProjectTemplates/-/raw/v2.9.4/Conventions/RepositoryStructure/CommonProjectStructure/codeunit.xsd" enabled="true">
<cps:name>ScriptCollection</cps:name>
<cps:version>3.5.41</cps:version>
<cps:version>3.5.42</cps:version>
<cps:codeunitownername>Marius Göcke</cps:codeunitownername>
<cps:codeunitowneremailaddress>[email protected]</cps:codeunitowneremailaddress>
<cps:properties codeunithastestablesourcecode="true" codeunithasupdatabledependencies="true" throwexceptionifcodeunitfilecannotbevalidated="true" developmentstate="Active development" description="ScriptCollection is the place for reusable scripts.">
Expand Down
7 changes: 4 additions & 3 deletions ScriptCollection/ScriptCollection/ScriptCollectionCore.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
from .ProgramRunnerPopen import ProgramRunnerPopen
from .ProgramRunnerEpew import ProgramRunnerEpew, CustomEpewArgument

version = "3.5.41"
version = "3.5.42"
__version__ = version


Expand Down Expand Up @@ -185,13 +185,14 @@ def __datetime_to_string_for_git(self, datetime_object: datetime) -> str:

@GeneralUtilities.check_arguments
def git_commit_is_ancestor(self, repository_folder: str, ancestor: str, descendant: str = "HEAD") -> bool:
exit_code = self.run_program_argsasarray("git", ["merge-base", "--is-ancestor", ancestor, descendant], repository_folder, throw_exception_if_exitcode_is_not_zero=False)[0]
result = self.run_program_argsasarray("git", ["merge-base", "--is-ancestor", ancestor, descendant], repository_folder, throw_exception_if_exitcode_is_not_zero=False)
exit_code = result[0]
if exit_code == 0:
return True
elif exit_code == 1:
return False
else:
raise ValueError(f"Can not calculate if {ancestor} is an ancestor of {descendant} in repository {repository_folder}.")
raise ValueError(f'Can not calculate if {ancestor} is an ancestor of {descendant} in repository {repository_folder}. Outout of "{repository_folder}> git merge-base --is-ancestor {ancestor} {descendant}": Exitcode: {exit_code}; StdOut: {result[1]}; StdErr: {result[2]}.')

@GeneralUtilities.check_arguments
def __git_changes_helper(self, repository_folder: str, arguments_as_array: list[str]) -> bool:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2403,7 +2403,7 @@ def build_specific_codeunits(self, repository_folder: str, codeunits: list[str],

now = datetime.now()
if not self.__suport_information_exists(repository_folder, project_version):
support_time = timedelta(days=365*2+31) # TODO make this configurable
support_time = timedelta(days=365*2+30*3) # TODO make this configurable
until = now + support_time
self.mark_current_version_as_supported(repository_folder, project_version, now, until)

Expand Down
2 changes: 1 addition & 1 deletion ScriptCollection/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
autopep8>=2.3.1
build>=1.2.2.post1
coverage>=7.6.9
coverage>=7.6.10
cyclonedx-bom>=5.1.1
defusedxml>=0.7.1
keyboard>=0.13.5
Expand Down
4 changes: 2 additions & 2 deletions ScriptCollection/setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = ScriptCollection
version = 3.5.41
version = 3.5.42
author = Marius Göcke
author_email = [email protected]
description = The ScriptCollection is the place for reusable scripts.
Expand Down Expand Up @@ -32,7 +32,7 @@ include_package_data = False
python_requires = >=3.10
install_requires =
build>=1.2.2.post1
coverage>=7.6.9
coverage>=7.6.10
cyclonedx-bom>=5.1.1
defusedxml>=0.7.1
keyboard>=0.13.5
Expand Down
2 changes: 1 addition & 1 deletion Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ tasks:
desc: "Base: Build all codeunits"
dir: "."
cmds:
- scbuildcodeunits {{.CLI_ARGS}}
- scbuildcodeunits
aliases:
- basebuildallcodeunits
- bb

0 comments on commit c21b152

Please sign in to comment.