chovy-3012 opened a new pull request, #18685:
URL: https://github.com/apache/dolphinscheduler/pull/18685

   ## Was this PR generated or assisted by AI?
   
   NO.
   
   ## Purpose of the pull request
   
   `ShellParameters.checkParameters()` only checks `rawScript != null && 
!rawScript.isEmpty()` without trimming. A whitespace-only script (e.g. `"   
\n\t  "`) passes validation and creates a meaningless empty task.
   
   Closes #18684
   
   ## Brief change log
   
   - `ShellParameters.java`: `checkParameters()` use `trim()` to reject 
whitespace-only scripts
   - `ShellParametersTest.java`: Add 4 unit tests covering null, empty, valid, 
and whitespace-only scripts
   
   ## Verify this pull request
   
   This change added tests and can be verified as follows:
   
   ```
   ./mvnw test -pl dolphinscheduler-task-plugin/dolphinscheduler-task-shell
   ```
   
   ## Pull Request Notice
   [Pull Request 
Notice](https://github.com/apache/dolphinscheduler/blob/dev/docs/docs/en/contribute/join/pull-request.md)


-- 
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