You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tooling.apache.org by ar...@apache.org on 2026/06/04 07:58:21 UTC

(tooling-trusted-releases) branch arm updated (95f78a2d -> c1cc4901)

This is an automated email from the ASF dual-hosted git repository.

alitheg pushed a change to branch arm
in repository https://gitbox.apache.org/repos/asf/tooling-trusted-releases.git


 discard 95f78a2d Fix trailing whitespace issue with default email templates
 discard e6e6e5dc Revert to NX2 checks for staging builds
     add 77e51de4 Try adding .asf.yaml now that features merged
     new 9b07c08e Revert to NX2 checks for staging builds
     new c1cc4901 Fix trailing whitespace issue with default email templates

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (95f78a2d)
            \
             N -- N -- N   refs/heads/arm (c1cc4901)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .asf.yaml | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@tooling.apache.org
For additional commands, e-mail: commits-help@tooling.apache.org


(tooling-trusted-releases) 01/02: Revert to NX2 checks for staging builds

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

alitheg pushed a commit to branch arm
in repository https://gitbox.apache.org/repos/asf/tooling-trusted-releases.git

commit 9b07c08e18bd3c92bee69ce9ccd3d84da589effc
Author: Alastair McFarlane <ar...@apache.org>
AuthorDate: Wed Jun 3 16:19:55 2026 +0100

    Revert to NX2 checks for staging builds
---
 atr/models/sql.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/atr/models/sql.py b/atr/models/sql.py
index 1f2339b2..e4db671e 100644
--- a/atr/models/sql.py
+++ b/atr/models/sql.py
@@ -130,7 +130,8 @@ class DistributionPlatform(enum.Enum):
         template_url="https://repo1.maven.org/maven2/{owner_namespace}/{package}/maven-metadata.xml",
         # Below is the old template using the maven search API - but the index isn't updated quickly enough for us
         # template_url="https://search.maven.org/solrsearch/select?q=g:{owner_namespace}+AND+a:{package}+AND+v:{version}&core=gav&rows=20&wt=json",
-        template_staging_url="https://repository.apache.org:4443/repository/maven-staging/{owner_namespace}/{package}/maven-metadata.xml",
+        template_staging_url="https://repository.apache.org/content/groups/staging/{owner_namespace}/{package}/maven-metadata.xml",
+        # template_staging_url="https://repository.apache.org:4443/repository/maven-staging/{owner_namespace}/{package}/maven-metadata.xml",
         # https://repository.apache.org/content/repositories/orgapachePROJECT-NNNN/
         # There's no JSON, but each individual package has maven-metadata.xml
         requires_owner_namespace=True,


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@tooling.apache.org
For additional commands, e-mail: commits-help@tooling.apache.org


(tooling-trusted-releases) 02/02: Fix trailing whitespace issue with default email templates

Posted by ar...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

alitheg pushed a commit to branch arm
in repository https://gitbox.apache.org/repos/asf/tooling-trusted-releases.git

commit c1cc49019a3e80a8dc9f420f0b9f33cbeb793f1b
Author: Alastair McFarlane <ar...@apache.org>
AuthorDate: Wed Jun 3 16:29:57 2026 +0100

    Fix trailing whitespace issue with default email templates
---
 atr/storage/writers/policy.py | 69 +++++++++++++++----------------------------
 1 file changed, 23 insertions(+), 46 deletions(-)

diff --git a/atr/storage/writers/policy.py b/atr/storage/writers/policy.py
index 3a5c6c22..5f04ed30 100644
--- a/atr/storage/writers/policy.py
+++ b/atr/storage/writers/policy.py
@@ -28,7 +28,6 @@ import strictyaml.ruamel.error as error
 
 import atr.cycles as cycles
 import atr.db as db
-import atr.hashes as hashes
 import atr.models as models
 import atr.storage as storage
 import atr.util as util
@@ -343,15 +342,9 @@ class CommitteeMember(CommitteeParticipant):
         project: models.sql.Project,
         release_policy: models.sql.ReleasePolicy,
     ) -> None:
-        submitted_subject = submitted_subject.strip()
-        current_default_text = project.policy_announce_release_subject_default
-        current_default_hash = hashes.compute_sha3_256(current_default_text.encode())
-        submitted_hash = hashes.compute_sha3_256(submitted_subject.encode())
-
-        if submitted_hash == current_default_hash:
-            release_policy.announce_release_subject = ""
-        else:
-            release_policy.announce_release_subject = submitted_subject
+        release_policy.announce_release_subject = _collapse_to_default(
+            submitted_subject, project.policy_announce_release_subject_default
+        )
 
     def __set_announce_release_template(
         self,
@@ -359,15 +352,9 @@ class CommitteeMember(CommitteeParticipant):
         project: models.sql.Project,
         release_policy: models.sql.ReleasePolicy,
     ) -> None:
-        submitted_template = submitted_template.replace("\r\n", "\n")
-        current_default_text = project.policy_announce_release_default
-        current_default_hash = hashes.compute_sha3_256(current_default_text.encode())
-        submitted_hash = hashes.compute_sha3_256(submitted_template.encode())
-
-        if submitted_hash == current_default_hash:
-            release_policy.announce_release_template = ""
-        else:
-            release_policy.announce_release_template = submitted_template
+        release_policy.announce_release_template = _collapse_to_default(
+            submitted_template, project.policy_announce_release_default
+        )
 
     def __set_min_hours(
         self,
@@ -388,15 +375,9 @@ class CommitteeMember(CommitteeParticipant):
         project: models.sql.Project,
         release_policy: models.sql.ReleasePolicy,
     ) -> None:
-        submitted_subject = submitted_subject.strip()
-        current_default_text = project.policy_start_vote_subject_default
-        current_default_hash = hashes.compute_sha3_256(current_default_text.encode())
-        submitted_hash = hashes.compute_sha3_256(submitted_subject.encode())
-
-        if submitted_hash == current_default_hash:
-            release_policy.start_vote_subject = ""
-        else:
-            release_policy.start_vote_subject = submitted_subject
+        release_policy.start_vote_subject = _collapse_to_default(
+            submitted_subject, project.policy_start_vote_subject_default
+        )
 
     def __set_start_vote_template(
         self,
@@ -404,15 +385,7 @@ class CommitteeMember(CommitteeParticipant):
         project: models.sql.Project,
         release_policy: models.sql.ReleasePolicy,
     ) -> None:
-        submitted_template = submitted_template.replace("\r\n", "\n")
-        current_default_text = project.policy_start_vote_default
-        current_default_hash = hashes.compute_sha3_256(current_default_text.encode())
-        submitted_hash = hashes.compute_sha3_256(submitted_template.encode())
-
-        if submitted_hash == current_default_hash:
-            release_policy.start_vote_template = ""
-        else:
-            release_policy.start_vote_template = submitted_template
+        release_policy.start_vote_template = _collapse_to_default(submitted_template, project.policy_start_vote_default)
 
     def __set_finish_vote_template(
         self,
@@ -420,15 +393,9 @@ class CommitteeMember(CommitteeParticipant):
         project: models.sql.Project,
         release_policy: models.sql.ReleasePolicy,
     ) -> None:
-        submitted_template = submitted_template.replace("\r\n", "\n")
-        current_default_text = project.policy_finish_vote_default
-        current_default_hash = hashes.compute_sha3_256(current_default_text.encode())
-        submitted_hash = hashes.compute_sha3_256(submitted_template.encode())
-
-        if submitted_hash == current_default_hash:
-            release_policy.finish_vote_template = ""
-        else:
-            release_policy.finish_vote_template = submitted_template
+        release_policy.finish_vote_template = _collapse_to_default(
+            submitted_template, project.policy_finish_vote_default
+        )
 
 
 class SystemService:
@@ -506,6 +473,16 @@ async def _get_or_create_policy(
     return project, release_policy
 
 
+def _collapse_to_default(submitted: str, default_text: str) -> str:
+    # Storing "" lets the project default apply. We compare ignoring line endings and
+    # surrounding whitespace, otherwise a default that has been through a textarea - which
+    # can drop the trailing newline - fails the match and gets saved as a spurious custom value.
+    submitted = submitted.replace("\r\n", "\n").strip()
+    if submitted == default_text.strip():
+        return ""
+    return submitted
+
+
 def _normalise_text_list(values: list[str]) -> list[str]:
     return [value.strip() for value in values if value.strip()]
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@tooling.apache.org
For additional commands, e-mail: commits-help@tooling.apache.org