kaiwangleo commented on code in PR #996:
URL: https://github.com/apache/flink-agents/pull/996#discussion_r3793377435


##########
tools/check-license.sh:
##########
@@ -20,41 +20,84 @@
 # NOTE: This script is adapted from the Apache Spark project.
 
 
-acquire_rat_jar () {
+validate_rat_jar() {
+  local jar_cmd
+
+  if command -v unzip >/dev/null 2>&1; then
+    unzip -tq "$JAR" >/dev/null 2>&1
+    return $?

Review Comment:
   Thanks for the detailed reproduction. I agree this is a real status-code 
collision: unzip can return 2 for a corrupt archive, while acquire_rat_jar 
currently treats 2 as a missing validator and allows a cached JAR to proceed. I 
will normalize both validator paths to return 0 for valid, 1 for invalid, and 
reserve 2 for missing tools, while preserving the existing 
cached-versus-downloaded policy. I will also add a regression test for the 
unzip-return-2 case and run the focused checks before reporting the result.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to