[ClavaLaraApi] Improves Clava.runClavaParallel()
Now converts all elements in the command array and argsLists to string
before calling ClavaWeaverLauncher.executeParallel();
@@ -117,13 +117,22 @@ Clava.runClavaParallel = function(argsLists, threads, clavaCommand) {
clavaCommand = ["clava"];
}
+ // Assures all elements in the argsLists are String
+ var safeArgsLists = [];
+ for(var argsList of argsLists) {
+ safeArgsLists.push(argsList.map(value => value.toString()));
+ }
+
/*
// If string, separate arguments
if(typeof args === "string") {
args = ArgumentsParser.newCommandLine().parse(args);
}
*/
- return ClavaWeaverLauncher.executeParallel(argsLists, threads, JavaInterop.arrayToList(clavaCommand));
+
+ //return ClavaWeaverLauncher.executeParallel(argsLists, threads, JavaInterop.arrayToList(clavaCommand));
+ return ClavaWeaverLauncher.executeParallel(safeArgsLists, threads, JavaInterop.arrayToStringList(clavaCommand));
+
}
/**
