zhengruifeng opened a new pull request, #40943:
URL: https://github.com/apache/spark/pull/40943

   ### What changes were proposed in this pull request?
   Refine the script:
   
   1. rename the file name to be more specific;
   2. make it work in `SPARK_HOME` dir;
   3. add a optional `branch` parameter;
   
   
   ### Why are the changes needed?
   ```
   (spark_dev) ➜  spark git:(master) ./dev/detect_breaking_changes.sh 
   ./dev/detect_breaking_changes.sh: line 28: pushd: 
connector/connect/common/src/main: No such file or directory
   Failure: failed to enumerate module files: open .Trash: operation not 
permitted
   Buf detected breaking changes for your Pull Request. Please verify.
   Please make sure your branch is current against spark/master.
   ```
   
   
   ### Does this PR introduce _any_ user-facing change?
   no, dev-only
   
   
   ### How was this patch tested?
   manually tests:
   
   ```
   (spark_dev) ➜  spark git:(new_breaking_change_script) ✗ 
./dev/protobuf-breaking-changes-check.sh 
   ~/Dev/spark/connector/connect/common/src/main ~/Dev/spark
   Start checking against master
   (spark_dev) ➜  spark git:(new_breaking_change_script) ✗ 
./dev/protobuf-breaking-changes-check.sh master
   ~/Dev/spark/connector/connect/common/src/main ~/Dev/spark
   Start checking against master
   (spark_dev) ➜  spark git:(new_breaking_change_script) ✗ 
./dev/protobuf-breaking-changes-check.sh branch-3.4  
   ~/Dev/spark/connector/connect/common/src/main ~/Dev/spark
   Start checking against branch-3.4
   (spark_dev) ➜  spark git:(new_breaking_change_script) ✗ 
./dev/protobuf-breaking-changes-check.sh branch-3.4 xyz
   Illegal number of parameters.
   Usage: ./dev/protobuf-breaking-changes-check.sh [branch]
   the default branch is 'master', available options are 'master', 
'branch-3.4', etc
   (spark_dev) ➜  spark git:(new_breaking_change_script) ✗ 
./dev/protobuf-breaking-changes-check.sh branch-3.3    
   ~/Dev/spark/connector/connect/common/src/main ~/Dev/spark
   Start checking against branch-3.3
   Failure: no .proto target files found
   Buf detected breaking changes for your Pull Request. Please verify.
   Please make sure your branch is current against spark/branch-3.3.
   
   
   ```
   


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


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

Reply via email to