dsmiley commented on code in PR #4227:
URL: https://github.com/apache/solr/pull/4227#discussion_r2974628066


##########
solr/test-framework/src/java/org/apache/solr/util/ExternalPaths.java:
##########
@@ -83,10 +83,13 @@ static Path determineSourceHome() {
       }
 
       Path base = file.toAbsolutePath();
-      while (!Files.exists(base.resolve("solr/test-framework/build.gradle")) 
&& null != base) {

Review Comment:
   This is a subtle difference that I bet nobody will notice.  Not the null 
check but the path.  Notice I removed the leading "solr/" component, and then 
some lines below here, I removed adding the "solr/" back on when we return, as 
it becomes pointless.  On one hand, this subtle difference is a 
micro-optimization -- why iterate to the root of the project when we can 
iterate and stop at the "solr/" child and then reach success one iteration 
sooner.  My _real_ motivation is that this is absolutely **critical** for 
`test-external-client`, which uses `ExternalPaths`.  We want that project to 
experience what any project outside Solr would see -- null for all paths here.  
So @epugh that answers why it's critical that `test-external-client` be at the 
root, or at least *not* inside `solr/`.



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