I am getting error when importing csv using rdd in intellij
Error: exception in thread "main" java.lang.illegalaccesserror: class org.apache.spark.storage.storageutils$ (in unnamed module #0x9225652) cannot access class sun.nio.ch.directbuffer (in module java.base) because module java.base does not export sun.nio.ch to unnamed module #0x9225652
Related
Generator.groovy*
import jenkins.model.Jenkins
import javaposse.jobdsl.dsl.DslFactory
import com.cs.folderCreation
//Normal code
.............................
EndOfFile*********
----------Error log--------------------------
Generator.groovy: 5: unable to resolve class com.cs.folderCreation
# line 5, column 1.
import com.bmw.cs.folderCreation
^
1 error
Finished: FAILURE
Resloved!
It was just a plugin issue.
Improper configuration can lead to unknown issues.
I am using below Task and running this from VS Code.
Task("Build")
.Does(() =>
{
// Use MSBuild
MSBuild("E:/Repos/Code/TestService/TestWindowsService.sln", settings =>
settings.SetConfiguration(configuration));
});
But I am getting below error when I Was try to run this Script.
MSBUILD: error MSB1009: Project file does not exist.
Switch: E:/Repos/Code/Cake/Code/TestService/TestWindowsService.sln
An error occurred when executing task 'Build'.
Error: One or more errors occurred.
MSBuild: Process returned an error (exit code 1).
When trying to run docker-compose,e.g.:
docker-compose --version
the following error message appears:
Fatal Python error: Py_Initialize: unable to load the file system codec ModuleNotFoundError: No module named ‘encodings’
Current thread 0x0000228c (most recent call first):
Any suggestions how to fix it?
Thanks in advance
i'm trying to create a docker image to run my java program inside the container. i new to docker i have no idea how to set the classpath. i have a datafile.properties, Sample.java,lib folder which contains all my dependancy jar files and my webdriver inside the folder C:\users\accessibility in my local machine. Please find the dockerfile below:
FROM java8:jdk
WORKDIR C:\\accessibility
COPY Sample.java C:\\accessibility\\Sample.java
COPY ./lib C:\\accessibility\\lib
ENV CLASSPATH C:\\accessibility\\lib\\axe-selenium-2.0.jar;C:\\accessibility\\lib\\java-json;C:\\accessibility\\lib\\json-simple-1.1;C:\\accessibility\\lib\\selenium-java-2.45.0;C:\\accessibility\\lib\\selenium-server-standalone-3.4.0
RUN javac Sample.java
CMD ["java","Sample"]
i'm trying to run it using the below command:
docker build -t accessibility C:\users\accessibility
i get shown the below error:
Sending build context to Docker daemon 29.33 MB
Step 1/6 : FROM java8:jdk
---> 97491cd5aa74
Step 2/6 : WORKDIR C:\\accessibility
---> Using cache
---> 0c8cfb951153
Step 3/6 : COPY Sample.java C:\\accessibility\\Sample.java
---> d083489522eb
Removing intermediate container f794396cc8eb
Step 4/6 : ENV CLASSPATH C:\\accessibility\\lib\\axe-selenium-2.0.jar;C:\\accessibility\\lib\\java-json;C:\\accessibility\\lib\\json-simple-1.1;C:\\accessibility\\lib\\selenium-java-2.45.0;C:\\accessibility\\lib\\selenium-server-standalone-3.4.0
---> Running in 3f0da277efaa
---> 2c32806352cb
Removing intermediate container 3f0da277efaa
Step 5/6 : RUN javac Sample.java
---> Running in 8ba2e1e7b45c
Sample.java:9: error: package org.json does not exist
import org.json.JSONArray;
^
Sample.java:10: error: package org.json does not exist
import org.json.JSONException;
^
Sample.java:11: error: package org.openqa.selenium does not exist
import org.openqa.selenium.By;
^
Sample.java:12: error: package org.openqa.selenium does not exist
import org.openqa.selenium.WebDriver;
^
Sample.java:13: error: package org.openqa.selenium.chrome does not exist
import org.openqa.selenium.chrome.ChromeDriver;
^
Sample.java:14: error: package com.nft.parsing does not exist
import com.nft.parsing.Parsing;
^
Sample.java:15: error: package com.nft.testing does not exist
import com.nft.testing.Testing;
^
Sample.java:22: error: cannot find symbol
static Testing t=new Testing();
^
symbol: class Testing
location: class Sample
Sample.java:24: error: package org.json.simple does not exist
ArrayList<org.json.simple.JSONArray> final10=new ArrayList<org.json.simple.JSONArray>();
^
Sample.java:26: error: cannot find symbol
static JSONArray jsonresults=null;
^
symbol: class JSONArray
location: class Sample
Sample.java:32: error: package org.json.simple.parser does not exist
public static void main(String[] args) throws FileNotFoundException, IOException, org.json.simple.parser.ParseException, JSONException{
^
Sample.java:32: error: cannot find symbol
public static void main(String[] args) throws FileNotFoundException, IOException, org.json.simple.parser.ParseException, JSONException{
^
symbol: class JSONException
location: class Sample
Sample.java:22: error: cannot find symbol
static Testing t=new Testing();
^
symbol: class Testing
location: class Sample
Sample.java:24: error: package org.json.simple does not exist
ArrayList<org.json.simple.JSONArray> final10=new ArrayList<org.json.simple.JSONArray>();
^
Sample.java:59: error: cannot find symbol
WebDriver driver = new ChromeDriver();
^
symbol: class WebDriver
location: class Sample
Sample.java:59: error: cannot find symbol
WebDriver driver = new ChromeDriver();
^
symbol: class ChromeDriver
location: class Sample
Sample.java:62: error: cannot find symbol
driver.findElement(By.id("userName")).sendKeys("admin");
^
symbol: variable By
location: class Sample
Sample.java:63: error: cannot find symbol
driver.findElement(By.id("passWord")).sendKeys("welcome");
^
symbol: variable By
location: class Sample
Sample.java:64: error: cannot find symbol
driver.findElement(By.id("login")).click();
^
symbol: variable By
location: class Sample
Note: Sample.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
19 errors
it is not referring the jar files. classpath is not set properly. Kindly help me with the sample dockerfile or any advise on this would be helpful. Thanks in advance
If I create an SBT project, even a simple "hello world", compile (successfully) and then exec, the folowing error is thrown. WHat may the reason be and how to fix this?
java.lang.ArrayIndexOutOfBoundsException: 0
at java.lang.ProcessBuilder.start(ProcessBuilder.java:459)
at sbt.SimpleProcessBuilder.run(ProcessImpl.scala:381)
at sbt.AbstractProcessBuilder.run(ProcessImpl.scala:130)
at sbt.AbstractProcessBuilder.$bang(ProcessImpl.scala:158)
at sbt.ExecProject$$anonfun$execOut$1.apply(ScalaProject.scala:436)
at sbt.ExecProject$$anonfun$execOut$1.apply(ScalaProject.scala:435)
at sbt.TaskManager$Task.invoke(TaskManager.scala:62)
at sbt.impl.RunTask.doRun$1(RunTask.scala:77)
at sbt.impl.RunTask.runTask(RunTask.scala:85)
at sbt.impl.RunTask.run(RunTask.scala:32)
at sbt.impl.RunTask$.apply(RunTask.scala:17)
at sbt.impl.RunTask$.apply(RunTask.scala:16)
at sbt.Project$class.run(Project.scala:98)
at sbt.Project$class.call(Project.scala:93)
at sbt.BasicScalaProject.call(DefaultProject.scala:21)
at sbt.xMain$$anonfun$7.apply(Main.scala:512)
at sbt.xMain$$anonfun$7.apply(Main.scala:512)
at sbt.xMain.withAction(Main.scala:541)
at sbt.xMain.sbt$xMain$$handleAction(Main.scala:512)
at sbt.xMain.handleCommand(Main.scala:502)
at sbt.xMain.processAction(Main.scala:441)
at sbt.xMain.process$1(Main.scala:257)
at sbt.xMain$Continue$1.apply(Main.scala:132)
at sbt.xMain.run$1(Main.scala:136)
at sbt.xMain.processArguments(Main.scala:266)
at sbt.xMain.startProject(Main.scala:107)
at sbt.xMain.run(Main.scala:84)
at sbt.xMain.run0$1(Main.scala:35)
at sbt.xMain.run(Main.scala:42)
at xsbt.boot.Launch$.run(Launch.scala:53)
at xsbt.boot.Launch$$anonfun$explicit$1.apply(Launch.scala:42)
at xsbt.boot.Launch$$anonfun$explicit$1.apply(Launch.scala:42)
at xsbt.boot.Launch$.launch(Launch.scala:57)
at xsbt.boot.Launch$.explicit(Launch.scala:42)
at xsbt.boot.Launch$.initialized(Launch.scala:38)
at xsbt.boot.Launch$.parsed(Launch.scala:31)
at xsbt.boot.Launch$.configured(Launch.scala:21)
at xsbt.boot.Launch$.apply(Launch.scala:16)
at xsbt.boot.Launch$.apply(Launch.scala:13)
at xsbt.boot.Boot$.runImpl(Boot.scala:24)
at xsbt.boot.Boot$.run(Boot.scala:19)
at xsbt.boot.Boot$.main(Boot.scala:15)
at xsbt.boot.Boot.main(Boot.scala)
[info] == exec ==
[error] Error running exec: java.lang.ArrayIndexOutOfBoundsException: 0
The purpose of the build action exec is to execute a command on the underlying shell. As such it needs to be followed with a command. EG:
exec killall firefox
Under the covers, SBT calls java.lang.ProcessBuilder, which throws this Exception if the caller tries to start it but has not provided any parameters.
IndexOutOfBoundsException - If the command is an empty list (has size 0)
I reckon SBT should not be propagating this exception and that this is a bug. You should get an error message instead.
Perhaps you were looking for the build action run, which will invoke your main class.