1104056452 opened a new pull request, #36447:
URL: https://github.com/apache/spark/pull/36447
What changes were proposed in this pull request?
The File.getCanonicalPath method will return the drive letter in the windows
system. The RpcEnvFileServer.validateDirectoryUri method uses the
File.getCanonicalPath method to process the baseuri, which will cause the
baseuri not to comply with the URI verification rules. For example, the /
classes is processed into F: \ classes.This causes the sparkcontext to fail to
start on windows.
This PR modifies the RpcEnvFileServer.validateDirectoryUri method and
replaces `new File(baseUri).getCanonicalPath` with
`new URI(baseUri).normalize().getPath`. This method can work normally in
windows.
Why are the changes needed?
Fix the startup error of spark shell on Windows system
[[SPARK-35691](https://issues.apache.org/jira/browse/SPARK-35691)]
introduced this regression.
Does this PR introduce any user-facing change?
No
How was this patch tested?
CI
--
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]