piyushghai commented on a change in pull request #14020: Fix jar path and add
missing ones for spark jobs
URL: https://github.com/apache/incubator-mxnet/pull/14020#discussion_r254470801
##########
File path:
scala-package/spark/src/test/scala/org/apache/mxnet/spark/SharedSparkContext.scala
##########
@@ -81,19 +81,18 @@ trait SharedSparkContext extends FunSuite with
BeforeAndAfterEach with BeforeAnd
}
private def getJarFilePath(root: String): String = {
- for (platform <- List("linux-x86_64-cpu", "linux-x86_64-gpu",
"osx-x86_64-cpu")) {
- val jarFiles = new File(s"$root/$platform/target/").listFiles(new
FileFilter {
- override def accept(pathname: File) = {
- pathname.getAbsolutePath.endsWith(".jar") &&
- !pathname.getAbsolutePath.contains("javadoc") &&
- !pathname.getAbsolutePath.contains("sources")
- }
- })
- if (jarFiles != null && jarFiles.nonEmpty) {
- return jarFiles.head.getAbsolutePath
+ val jarFiles = new File(s"$root/target/").listFiles(new FileFilter {
+ override def accept(pathname: File) = {
+ pathname.getAbsolutePath.endsWith(".jar") &&
+ !pathname.getAbsolutePath.contains("bundle") &&
Review comment:
I agree with Zach here. We should also ignore the others
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services