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

sbp pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tooling-trusted-release.git


The following commit(s) were added to refs/heads/main by this push:
     new 6239f5e  Make license header checks case insensitive
6239f5e is described below

commit 6239f5eb248ef3fcbd6c2f81569aaf5f9787631e
Author: Sean B. Palmer <[email protected]>
AuthorDate: Fri Jun 20 17:08:07 2025 +0100

    Make license header checks case insensitive
---
 atr/tasks/checks/license.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/atr/tasks/checks/license.py b/atr/tasks/checks/license.py
index 5385e2c..cc1d9a2 100644
--- a/atr/tasks/checks/license.py
+++ b/atr/tasks/checks/license.py
@@ -180,10 +180,10 @@ def headers_validate(content: bytes, _filename: str) -> 
tuple[bool, str | None]:
     for span in r_span.finditer(content):
         # Get only the words in the span
         words = r_words.findall(span.group(0))
-        joined = b" ".join(words)
-        if joined == HTTP_APACHE_LICENSE_HEADER:
+        joined = b" ".join(words).lower()
+        if joined == HTTP_APACHE_LICENSE_HEADER.lower():
             return True, None
-        elif joined == HTTPS_APACHE_LICENSE_HEADER:
+        elif joined == HTTPS_APACHE_LICENSE_HEADER.lower():
             return True, None
     return False, "Could not find Apache License header"
 


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to