Exception in thread “main” java.lang.NoClassDefFoundError: org/rogach/scallop/ScallopConfHow do I get sbt 0.10.0 to compile files in a subdirectory?Can't execute jar- file: “no main manifest attribute”sbteclipse: Managed dependencies not found by eclipseSBT and External Libraries in IntellijAdd swf file in sbt processscalatest : object scalatest is not a member of package orghow to connect to cassandra through scala in play frameworkFailed running activator run after play-slick upgradebuild.sbt ProjectRef : not enough arguments for method applysbt unresolved dependency on Windows 7

Why do radiation hardened IC packages often have long leads?

Is it safe to change the harddrive power feature so that it never turns off?

What would prevent chimeras from reproducing with each other?

How do free-speech protections in the United States apply in public to corporate misrepresentations?

Is there a set of positive integers of density 1 which contains no infinite arithmetic progression?

Why is long-term living in Almost-Earth causing severe health problems?

Non-aqueous eyes?

Origin of "boor"

What aircraft was used as Air Force One for the flight between Southampton and Shannon?

Write a function that checks if a string starts with or contains something

What would be the way to say "just saying" in German? (Not the literal translation)

Is it possible to have 2 different but equal size real number sets that have the same mean and standard deviation?

Why Does Mama Coco Look Old After Going to the Other World?

If I leave the US through an airport, do I have to return through the same airport?

Getting UPS Power from One Room to Another

Electricity free spaceship

What differences exist between adamantine and adamantite in all editions of D&D?

Is there a DSLR/mirorless camera with minimal options like a classic, simple SLR?

Separate SPI data

How to befriend someone who doesn't like to talk?

How to safely destroy (a large quantity of) valid checks?

I have a problematic assistant manager, but I can't fire him

Is it okay to have a sequel start immediately after the end of the first book?

Varying the size of dots in a plot according to information contained in list



Exception in thread “main” java.lang.NoClassDefFoundError: org/rogach/scallop/ScallopConf


How do I get sbt 0.10.0 to compile files in a subdirectory?Can't execute jar- file: “no main manifest attribute”sbteclipse: Managed dependencies not found by eclipseSBT and External Libraries in IntellijAdd swf file in sbt processscalatest : object scalatest is not a member of package orghow to connect to cassandra through scala in play frameworkFailed running activator run after play-slick upgradebuild.sbt ProjectRef : not enough arguments for method applysbt unresolved dependency on Windows 7






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








1















As I want to execute the jar generated by my scala project in the Command Line Interface, I get the following problem:
Exception in thread "main" java.lang.NoClassDefFoundError: org/rogach/scallop/ScallopConf



Although in the dependency file I mentionned scallop dependency as follow



import sbt._

object Dependencies
lazy val betterFiles = "com.github.pathikrit" %% "better-files" % "3.7.0"
lazy val scalaz = "org.scalaz" %% "scalaz-core" % "7.2.27"
lazy val scallop = "org.rogach" %% "scallop" % "3.1.5"

// -- Logging
lazy val scalaLogging = "com.typesafe.scala-logging" %% "scala-logging" % "3.9.2"
lazy val slf4jBackend = "org.slf4j" % "slf4j-simple" % "1.7.26"

// -- Testing
lazy val scalaTest = "org.scalatest" %% "scalatest" % "3.0.5"




My build.sbt file is the following:



import Dependencies._

ThisBuild / scalaVersion := "2.12.5"
ThisBuild / sbtVersion := "1.2.6"
ThisBuild / version := "0.1.0-SNAPSHOT"

lazy val root = (project in file("."))
.settings(
name := "phenix-challenge",
libraryDependencies ++= Seq(
betterFiles,
scalaz,
scallop,

scalaLogging,
slf4jBackend % Runtime,

scalaTest % Test
)
)



If you have an Idea that could resolve my Issue please HELP!



Many thanks in advance










share|improve this question






















  • try invalidate cache/restart may be the issue will get resolve.

    – Raman Mishra
    Mar 25 at 6:36











  • Can you tell us how do you generate the jar file before you call the main class?

    – Alexey Novakov
    Mar 25 at 8:22











  • @AlexeyNovakov as I am working with eclipse I package the project with sbt package then run sbt eclipse on the CLI

    – Iriel
    Mar 25 at 9:18












  • @JijiAR sbt package: Creates a JAR file (or WAR file for web projects) containing the files in src/main/scala, src/main/java, and resources in src/main/resources. It won't package libraries inside.

    – Alexey Novakov
    Mar 25 at 10:31











  • Do want to execute your jar as fat-jar outside of sbt?

    – Alexey Novakov
    Mar 25 at 10:55

















1















As I want to execute the jar generated by my scala project in the Command Line Interface, I get the following problem:
Exception in thread "main" java.lang.NoClassDefFoundError: org/rogach/scallop/ScallopConf



Although in the dependency file I mentionned scallop dependency as follow



import sbt._

object Dependencies
lazy val betterFiles = "com.github.pathikrit" %% "better-files" % "3.7.0"
lazy val scalaz = "org.scalaz" %% "scalaz-core" % "7.2.27"
lazy val scallop = "org.rogach" %% "scallop" % "3.1.5"

// -- Logging
lazy val scalaLogging = "com.typesafe.scala-logging" %% "scala-logging" % "3.9.2"
lazy val slf4jBackend = "org.slf4j" % "slf4j-simple" % "1.7.26"

// -- Testing
lazy val scalaTest = "org.scalatest" %% "scalatest" % "3.0.5"




My build.sbt file is the following:



import Dependencies._

ThisBuild / scalaVersion := "2.12.5"
ThisBuild / sbtVersion := "1.2.6"
ThisBuild / version := "0.1.0-SNAPSHOT"

lazy val root = (project in file("."))
.settings(
name := "phenix-challenge",
libraryDependencies ++= Seq(
betterFiles,
scalaz,
scallop,

scalaLogging,
slf4jBackend % Runtime,

scalaTest % Test
)
)



If you have an Idea that could resolve my Issue please HELP!



Many thanks in advance










share|improve this question






















  • try invalidate cache/restart may be the issue will get resolve.

    – Raman Mishra
    Mar 25 at 6:36











  • Can you tell us how do you generate the jar file before you call the main class?

    – Alexey Novakov
    Mar 25 at 8:22











  • @AlexeyNovakov as I am working with eclipse I package the project with sbt package then run sbt eclipse on the CLI

    – Iriel
    Mar 25 at 9:18












  • @JijiAR sbt package: Creates a JAR file (or WAR file for web projects) containing the files in src/main/scala, src/main/java, and resources in src/main/resources. It won't package libraries inside.

    – Alexey Novakov
    Mar 25 at 10:31











  • Do want to execute your jar as fat-jar outside of sbt?

    – Alexey Novakov
    Mar 25 at 10:55













1












1








1








As I want to execute the jar generated by my scala project in the Command Line Interface, I get the following problem:
Exception in thread "main" java.lang.NoClassDefFoundError: org/rogach/scallop/ScallopConf



Although in the dependency file I mentionned scallop dependency as follow



import sbt._

object Dependencies
lazy val betterFiles = "com.github.pathikrit" %% "better-files" % "3.7.0"
lazy val scalaz = "org.scalaz" %% "scalaz-core" % "7.2.27"
lazy val scallop = "org.rogach" %% "scallop" % "3.1.5"

// -- Logging
lazy val scalaLogging = "com.typesafe.scala-logging" %% "scala-logging" % "3.9.2"
lazy val slf4jBackend = "org.slf4j" % "slf4j-simple" % "1.7.26"

// -- Testing
lazy val scalaTest = "org.scalatest" %% "scalatest" % "3.0.5"




My build.sbt file is the following:



import Dependencies._

ThisBuild / scalaVersion := "2.12.5"
ThisBuild / sbtVersion := "1.2.6"
ThisBuild / version := "0.1.0-SNAPSHOT"

lazy val root = (project in file("."))
.settings(
name := "phenix-challenge",
libraryDependencies ++= Seq(
betterFiles,
scalaz,
scallop,

scalaLogging,
slf4jBackend % Runtime,

scalaTest % Test
)
)



If you have an Idea that could resolve my Issue please HELP!



Many thanks in advance










share|improve this question














As I want to execute the jar generated by my scala project in the Command Line Interface, I get the following problem:
Exception in thread "main" java.lang.NoClassDefFoundError: org/rogach/scallop/ScallopConf



Although in the dependency file I mentionned scallop dependency as follow



import sbt._

object Dependencies
lazy val betterFiles = "com.github.pathikrit" %% "better-files" % "3.7.0"
lazy val scalaz = "org.scalaz" %% "scalaz-core" % "7.2.27"
lazy val scallop = "org.rogach" %% "scallop" % "3.1.5"

// -- Logging
lazy val scalaLogging = "com.typesafe.scala-logging" %% "scala-logging" % "3.9.2"
lazy val slf4jBackend = "org.slf4j" % "slf4j-simple" % "1.7.26"

// -- Testing
lazy val scalaTest = "org.scalatest" %% "scalatest" % "3.0.5"




My build.sbt file is the following:



import Dependencies._

ThisBuild / scalaVersion := "2.12.5"
ThisBuild / sbtVersion := "1.2.6"
ThisBuild / version := "0.1.0-SNAPSHOT"

lazy val root = (project in file("."))
.settings(
name := "phenix-challenge",
libraryDependencies ++= Seq(
betterFiles,
scalaz,
scallop,

scalaLogging,
slf4jBackend % Runtime,

scalaTest % Test
)
)



If you have an Idea that could resolve my Issue please HELP!



Many thanks in advance







scala jar sbt






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Mar 24 at 20:38









IrielIriel

56211




56211












  • try invalidate cache/restart may be the issue will get resolve.

    – Raman Mishra
    Mar 25 at 6:36











  • Can you tell us how do you generate the jar file before you call the main class?

    – Alexey Novakov
    Mar 25 at 8:22











  • @AlexeyNovakov as I am working with eclipse I package the project with sbt package then run sbt eclipse on the CLI

    – Iriel
    Mar 25 at 9:18












  • @JijiAR sbt package: Creates a JAR file (or WAR file for web projects) containing the files in src/main/scala, src/main/java, and resources in src/main/resources. It won't package libraries inside.

    – Alexey Novakov
    Mar 25 at 10:31











  • Do want to execute your jar as fat-jar outside of sbt?

    – Alexey Novakov
    Mar 25 at 10:55

















  • try invalidate cache/restart may be the issue will get resolve.

    – Raman Mishra
    Mar 25 at 6:36











  • Can you tell us how do you generate the jar file before you call the main class?

    – Alexey Novakov
    Mar 25 at 8:22











  • @AlexeyNovakov as I am working with eclipse I package the project with sbt package then run sbt eclipse on the CLI

    – Iriel
    Mar 25 at 9:18












  • @JijiAR sbt package: Creates a JAR file (or WAR file for web projects) containing the files in src/main/scala, src/main/java, and resources in src/main/resources. It won't package libraries inside.

    – Alexey Novakov
    Mar 25 at 10:31











  • Do want to execute your jar as fat-jar outside of sbt?

    – Alexey Novakov
    Mar 25 at 10:55
















try invalidate cache/restart may be the issue will get resolve.

– Raman Mishra
Mar 25 at 6:36





try invalidate cache/restart may be the issue will get resolve.

– Raman Mishra
Mar 25 at 6:36













Can you tell us how do you generate the jar file before you call the main class?

– Alexey Novakov
Mar 25 at 8:22





Can you tell us how do you generate the jar file before you call the main class?

– Alexey Novakov
Mar 25 at 8:22













@AlexeyNovakov as I am working with eclipse I package the project with sbt package then run sbt eclipse on the CLI

– Iriel
Mar 25 at 9:18






@AlexeyNovakov as I am working with eclipse I package the project with sbt package then run sbt eclipse on the CLI

– Iriel
Mar 25 at 9:18














@JijiAR sbt package: Creates a JAR file (or WAR file for web projects) containing the files in src/main/scala, src/main/java, and resources in src/main/resources. It won't package libraries inside.

– Alexey Novakov
Mar 25 at 10:31





@JijiAR sbt package: Creates a JAR file (or WAR file for web projects) containing the files in src/main/scala, src/main/java, and resources in src/main/resources. It won't package libraries inside.

– Alexey Novakov
Mar 25 at 10:31













Do want to execute your jar as fat-jar outside of sbt?

– Alexey Novakov
Mar 25 at 10:55





Do want to execute your jar as fat-jar outside of sbt?

– Alexey Novakov
Mar 25 at 10:55












1 Answer
1






active

oldest

votes


















1














To execute the jar generated by your scala project in the Command Line Interface you can use sbt plugin to assembly a fat-jar including your libraries/dependencies. Having such jar you would be able to run your app via java -jar ...



There are several SBT plugins for build a fat-jar. Perhaps the easiest one would be the sbt-assembly.



  1. Add this plugin to file project/plugins.sbt (create this file if needed):
    addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.9")

  2. Now use sbt to build a fat-jar:

sbt assembly


  1. Then run via java -jar YouMainClass

Another option is to use pure sbt to run Main class using command sbt run, then you do really need to build a fat-jar.






share|improve this answer























  • Thank you very much your solution works perfectly for me. In fact I had to think about the fact of generating a fat jar and then I should use sbt assembly. Thanks again!

    – Iriel
    Mar 25 at 12:28











Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55328335%2fexception-in-thread-main-java-lang-noclassdeffounderror-org-rogach-scallop-sc%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









1














To execute the jar generated by your scala project in the Command Line Interface you can use sbt plugin to assembly a fat-jar including your libraries/dependencies. Having such jar you would be able to run your app via java -jar ...



There are several SBT plugins for build a fat-jar. Perhaps the easiest one would be the sbt-assembly.



  1. Add this plugin to file project/plugins.sbt (create this file if needed):
    addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.9")

  2. Now use sbt to build a fat-jar:

sbt assembly


  1. Then run via java -jar YouMainClass

Another option is to use pure sbt to run Main class using command sbt run, then you do really need to build a fat-jar.






share|improve this answer























  • Thank you very much your solution works perfectly for me. In fact I had to think about the fact of generating a fat jar and then I should use sbt assembly. Thanks again!

    – Iriel
    Mar 25 at 12:28















1














To execute the jar generated by your scala project in the Command Line Interface you can use sbt plugin to assembly a fat-jar including your libraries/dependencies. Having such jar you would be able to run your app via java -jar ...



There are several SBT plugins for build a fat-jar. Perhaps the easiest one would be the sbt-assembly.



  1. Add this plugin to file project/plugins.sbt (create this file if needed):
    addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.9")

  2. Now use sbt to build a fat-jar:

sbt assembly


  1. Then run via java -jar YouMainClass

Another option is to use pure sbt to run Main class using command sbt run, then you do really need to build a fat-jar.






share|improve this answer























  • Thank you very much your solution works perfectly for me. In fact I had to think about the fact of generating a fat jar and then I should use sbt assembly. Thanks again!

    – Iriel
    Mar 25 at 12:28













1












1








1







To execute the jar generated by your scala project in the Command Line Interface you can use sbt plugin to assembly a fat-jar including your libraries/dependencies. Having such jar you would be able to run your app via java -jar ...



There are several SBT plugins for build a fat-jar. Perhaps the easiest one would be the sbt-assembly.



  1. Add this plugin to file project/plugins.sbt (create this file if needed):
    addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.9")

  2. Now use sbt to build a fat-jar:

sbt assembly


  1. Then run via java -jar YouMainClass

Another option is to use pure sbt to run Main class using command sbt run, then you do really need to build a fat-jar.






share|improve this answer













To execute the jar generated by your scala project in the Command Line Interface you can use sbt plugin to assembly a fat-jar including your libraries/dependencies. Having such jar you would be able to run your app via java -jar ...



There are several SBT plugins for build a fat-jar. Perhaps the easiest one would be the sbt-assembly.



  1. Add this plugin to file project/plugins.sbt (create this file if needed):
    addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.9")

  2. Now use sbt to build a fat-jar:

sbt assembly


  1. Then run via java -jar YouMainClass

Another option is to use pure sbt to run Main class using command sbt run, then you do really need to build a fat-jar.







share|improve this answer












share|improve this answer



share|improve this answer










answered Mar 25 at 11:52









Alexey NovakovAlexey Novakov

49949




49949












  • Thank you very much your solution works perfectly for me. In fact I had to think about the fact of generating a fat jar and then I should use sbt assembly. Thanks again!

    – Iriel
    Mar 25 at 12:28

















  • Thank you very much your solution works perfectly for me. In fact I had to think about the fact of generating a fat jar and then I should use sbt assembly. Thanks again!

    – Iriel
    Mar 25 at 12:28
















Thank you very much your solution works perfectly for me. In fact I had to think about the fact of generating a fat jar and then I should use sbt assembly. Thanks again!

– Iriel
Mar 25 at 12:28





Thank you very much your solution works perfectly for me. In fact I had to think about the fact of generating a fat jar and then I should use sbt assembly. Thanks again!

– Iriel
Mar 25 at 12:28



















draft saved

draft discarded
















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid …


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55328335%2fexception-in-thread-main-java-lang-noclassdeffounderror-org-rogach-scallop-sc%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

How to preserve electronics (computers, tablets and phones) for hundreds of years Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern) The network's official Twitter account is up and running again. What content…How might modern humans leave a message for 50,000 years?How would an aquatic race develop computers?How do we make computers care for human life?Keeping supplies for 1000 yearsWhat will cell phones become in 100 years?What body armor protects against a laser?Could a society attain 1800s technology if limited to using copper and bronze?Electricity power (magic) and electronicsScavenging metal resources in post-apocalypse after 100 yearsWhy would precursors create devices that can survive and still work after hundreds of years?

155 수학 과학 기타 둘러보기 메뉴eh추가해eh문서를 완성해

Convert JSON to MapSimplest way to convert a string representing JSON array into Java array List of key value pairsHow to take String JSON values into HashMapConvert a JSON String to a HashMapCreating BSON object from JSON stringJSONObject - How to get a value ?Better Map ConstructorReading JSON from Url javaUpdate columns if input values are not null otherwise ignore and keep the existing values of column in databaseHow to store object represented as Json string into Couchbase Lite?Go JSON into MapHow do I efficiently iterate over each entry in a Java Map?Sort a Map<Key, Value> by valuesHow to round a number to n decimal places in JavaCan comments be used in JSON?How do I read / convert an InputStream into a String in Java?How can I pretty-print JSON in a shell script?What is the correct JSON content type?How can I deserialize JSON to a simple Dictionary<string,string> in ASP.NET?Why does Google prepend while(1); to their JSON responses?Parse JSON in JavaScript?