How can I build a fat jar to build my Chisel code with sbt-assembly? - sbt

I would like to build a fat JAR that can build my Chisel code. I have built these previously using Maven assembly:
https://github.com/hutch31/ChiselCodeGenerator
But I would like to get this working with chisel 3.5 and sbt-assembly, which I have done this branch:
https://github.com/hutch31/ChiselCodeGenerator/tree/chisel3.5
Per the docs I simply add the dependency and go, but it's unable to resolve the dependency when I do so:
not found: /home/guy/.ivy2/localcom.eed3si9n/sbt-assembly/scala_2.13/sbt_1.0/1.2.0/ivys/ivy.xml
not found: https://repo1.maven.org/maven2/com/eed3si9n/sbt-assembly_2.13_1.0/1.2.0/sbt-assembly-1.2.0.pom
(ssExtractDependencies) sbt.librarymanagement.ResolveException: Error downloading com.eed3si9n:sbt-assembly;sbtVersion=1.0;scalaVersion=2.13:1.2.0

Related

error: GenerateFeatureFileCodeBehindTask task could not be loaded from the assembly

We have ported our project from .NET to .NET Core in order to use an AWS pipeline with Docker containers which requires Linux.
The application builds successfully on our local computers (which run Windows) but in the AWS pipeline the build steps shows this error - GenerateFeatureFileCodeBehindTask ... task could not be loaded from the assembly ... SpecFlow.Tools.MsBuild.Generation.dll:
Full error:
/root/.nuget/packages/specflow.tools.msbuild.generation/3.0.225/build/SpecFlow.Tools.MsBuild.Generation.targets(78,5): error MSB4062: The "SpecFlow.Tools.MsBuild.Generation.GenerateFeatureFileCodeBehindTask" task could not be loaded from the assembly /root/.nuget/packages/specflow.tools.msbuild.generation/3.0.225/build/../tasks/netcoreapp2.0/SpecFlow.Tools.MsBuild.Generation.dll. Assembly with same name is already loaded Confirm that the <UsingTask> declaration is correct, that the assembly and all its dependencies are available, and that the task contains a public class that implements
Microsoft.Build.Framework.ITask. [/codebuild/output/src814/src/s3/00/ProjectFoo/ProjectFoo.csproj]
I have found 2 links mentioning this error but no solution - https://ci.appveyor.com/project/SpecFlow/specflow-kx1o3/build/build1119 and https://www.gitmemory.com/issue/techtalk/SpecFlow/1699/520196304.
I have checked and I have no <UsingTask> in my csproj files. Any idea what this SpecFlow task is, and why it is throwing this error?
The GenerateFeatureFileCodeBehindTask is contained in the SpecFlow.Tools.MSBuild.Generation package. It is used to generate the code-behind files of your feature files.
You don't find a <UsingTask> because it is done in the NuGet package.
The GitHub issue for this is: https://github.com/techtalk/SpecFlow/issues/1699/
Currently I have no idea why this error is thrown. But we are currently fixing our build/tests for Linux.

Installing SystemML from MVN/GitHub?

SystemML is available on https://github.com/SparkTC/systemml
How do I get it started with? I am newbie to GitHub.
I created a directory in my Ubuntu and copied the POM.xml file - when I issued mvn clean package, I am getting the error:
mvn clean package
[INFO] Scanning for projects...
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]
[ERROR] The project com.ibm.systemml:systemml-parent:5.2-SNAPSHOT (/home/vmuser/system-ml/pom.xml) has 1 error
[ERROR] Child module /home/vmuser/system-ml/system-ml of /home/vmuser/system-ml/pom.xml does not exist
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException
When I went to R and issued the following command on R 64 bit ver 3.1.1, I got error too:
> install.packages(c("batch", "bitops", "boot", "caTools", "data.table", "doMC", "doSNOW", "ggplot2", "glmnet", "lda", "Matrix", "matrixStats", "moments", "plotrix", "psych", "reshape", "topicmodels", "wordcloud", "methods"), dependencies=TRUE)
--- Please select a CRAN mirror for use in this session ---
Warning: unable to access index for repository https://cran.rstudio.com/bin/windows/contrib/3.1
Warning: package ‘methods’ is in use and will not be installed
Warning message:
packages ‘batch’, ‘bitops’, ‘boot’, ‘caTools’, ‘data.table’, ‘doMC’, ‘doSNOW’, ‘ggplot2’, ‘glmnet’, ‘lda’, ‘Matrix’, ‘matrixStats’, ‘moments’, ‘plotrix’, ‘psych’, ‘reshape’, ‘topicmodels’, ‘wordcloud’ are not available (for R version 3.1.1)
>
The error message you received tells you what the problem is (formatting mine):
The project com.ibm.systemml:systemml-parent:5.2-SNAPSHOT (/home/vmuser/system-ml/pom.xml) has 1 error
Child module /home/vmuser/system-ml/system-ml of /home/vmuser/system-ml/pom.xml does not exist
You said:
I created a directory in my Ubuntu and copied the POM.xml file
You don't just need the pom.xml file; you need the whole project. Either git clone it or download the source as a zip and extract it, then run mvn clean package from the project directory.
git clone is a better option if you intend to modify the source code. It will give you some powerful tools for integrating upstream changes and for submitting your modifications to the parent project. If you just want to use the project as-is, either option should be fine.
SystemML became an Apache (incubating) project in November of 2015. Its main website is located at http://systemml.apache.org/. The project can now be found on GitHub at https://github.com/apache/incubator-systemml.
Probably the quickest way to get started with Apache SystemML is to download a pre-built release package from the Apache SystemML Downloads page (see the main website). Information about Apache SystemML can be found at the Apache SystemML Documentation site, which is linked to from the main site. This includes information about running SystemML in notebooks, on Spark, and on Hadoop.
If you would like to clone the SystemML repository and build it locally with Maven, instructions to do so can be found in the project README on GitHub.

How to add scalax.io as dependency in SBT?

I want to use scalax.io._ to manipulate file operations with SBT.
When I ran it, I got the error message showing scalax is not found.
>sbt run
import scalax.io._
[error] ^
[error] iotest.scala:49: not found: object scalax
How to find the library dependency for this particular one?
A more general question, how to obtain the library dependency information for any library?
For example, if I need use actor in scala, I need specify a library dependency. How to find the library dependency?
"the library dependency information for any library" is part of the library's documentation and the author(s) is supposed to publish the info for different project management tools, sbt including. After all, what would be the purpose of developing a library that's hard to use?
Use http://search.maven.org/ to search for a library, and when you search for scala-io you'll get a list of available scala-io libraries.
Since I've never worked with the library I copied the ScalaIOExample example from Scala IO Documentation to have a working example. It needs the scalax.io and scalax.file packages that are distributed as scala-io-file artifact. Searching for the artifact leads to Artifact Details For com.github.scala-incubator.io:scala-io-file_2.10:0.4.2 with information on how to use it with Scala SBT in Dependency Information section.
With this, I created the following build.sbt in a sbt project:
scalaVersion := "2.10.3"
libraryDependencies += "com.github.scala-incubator.io" %% "scala-io-file" % "0.4.2"
It will add scala-io-file_2.10-0.4.2.jar to classpath and executing run in the project gives the following results:
$ sbt run
[info] Loading global plugins from /Users/jacek/.sbt/0.13/plugins
[info] Loading project definition from /Users/jacek/sandbox/stackoverflow/sbt-scala-io/project
[info] Set current project to sbt-scala-io (in build file:/Users/jacek/sandbox/stackoverflow/sbt-scala-io/)
[info] Running ScalaIOExample
Not interrupting system thread Thread[Keep-Alive-Timer,8,system]
Not interrupting system thread Thread[Keep-Alive-SocketCleaner,8,system]
[success] Total time: 5 s, completed Dec 31, 2013 11:16:42 PM

Missing resource bundle com.adobe.flex.framework:playerglobal:rb.swc:ko_KR:4.5.1.21328

facing a issue while creating locale file with maven build for Korean locale.
rest of language resource bundle get created properly only Korean locale giving problem.
the following error occur.
[ERROR] Failed to execute goal org.sonatype.flexmojos:flexmojos-maven-plugin:4.0-RC2:compile-swf (default-compile-swf) on project
---: Execution default-compile-swf of goal org.sonatype.flexmojos:flexmojos-maven-plugin:4.0-RC2:compile-swf failed: Missing
resource bundle 'com.adobe.flex.framework:flash-integration:rb.swc:ko_KR:4.5.1.21328
For this I have bundled required swc in my package and called same from maven build.

Maven build(with Flexmojos) for multi module project throwing an error

I am trying to setup a Flex/Java multi module project in Eclipse. Using Maven to run the build and generate the war file. The details of the versions I am using are as follows:
Flexmojos : 3.5.0
Flex framework/compiler : 4.5.1.21328
Target player : 10.2.0
And the playerglobal dependency in my pom file uses classifier as 10.2 with version 4.5.1.21328
Now when I run the build using 'mvn install', I get the following error:
[ERROR] Failed to execute goal
org.sonatype.flexmojos:flexmojos-maven-plugin:3.5.0:compile-swf
(default-compile-swf) on project client: TargetPlayer and
playerglobal dependency version doesn't match! Target player: 10.2.0,
player global: 10.2 -> [Help 1]
Any ideas why this might be happening?
I tried just playing around changing those version numbers, but still couldn't make it work for Flex 4.5.1. Please let me know how to go about this (and if you need more information). Thanks.
Regards
Basith
Have you tried simply referencing "10.2" instead of "10.2.0"? I think there was only one Flash player deployed with a 3-segment version number.

Resources