Problems compiling Widgetset after vaadin8 migration - widget

I just have upgrade from vaadin 7.7.7 to vaadin 8.3.0. I have added compatibility package to server, themes and client. I can run "clean install" or "vaadin:update-widgetset install", but when I try to compile in eclipse, with vaadin widgetset I have lot of errors. There are a lot, I have snipped only a few part of the big FAIL.
[INFO] Tracing compile failure path for type 'javaemul.internal.HashCodes'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/google/gwt/gwt-user/2.8.2/gwt-user-2.8.2.jar!/com/google/gwt/emul/javaemul/internal/HashCodes.java'
[INFO] [ERROR] Line 25: The method getStringHashCode(String) in the type HashCodes is not applicable for the arguments (Object)
[INFO] [ERROR] Line 29: The method hashCode() in the type Boolean is not applicable for the arguments (boolean)
[INFO] Tracing compile failure path for type 'com.vaadin.client.communication.AtmospherePushConnection'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/vaadin/vaadin-client/8.3.1/vaadin-client-8.3.1.jar!/com/vaadin/client/communication/AtmospherePushConnection.java'
[INFO] [ERROR] Line 159: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 153: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 183: Lambda expressions are allowed only at source level 1.8 or above
[INFO] Tracing compile failure path for type 'com.vaadin.client.componentlocator.VaadinFinderLocatorStrategy'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/vaadin/vaadin-client/8.3.1/vaadin-client-8.3.1.jar!/com/vaadin/client/componentlocator/VaadinFinderLocatorStrategy.java'
[INFO] [ERROR] Line 679: Method references are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 674: Method references are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 672: The method stream(Integer[]) is undefined for the type Arrays
[INFO] [ERROR] Line 676: The method stream(Integer[]) is undefined for the type Arrays
[INFO] Tracing compile failure path for type 'com.vaadin.client.ui.VMenuBar'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/vaadin/vaadin-client/8.3.1/vaadin-client-8.3.1.jar!/com/vaadin/client/ui/VMenuBar.java'
[INFO] [ERROR] Line 112: Lambda expressions are allowed only at source level 1.8 or above
[INFO] Tracing compile failure path for type 'com.vaadin.client.widgets.Grid'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/vaadin/vaadin-client/8.3.1/vaadin-client-8.3.1.jar!/com/vaadin/client/widgets/Grid.java'
[INFO] [ERROR] Line 2954: Method references are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 6253: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 3887: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 6571: The method addColumnsSkipSelectionColumnCheck(Collection<Grid.Column<?,T>>, int) in the type Grid<T> is not applicable for the arguments (Set<C>, int)
[INFO] [ERROR] Line 6594: The method forEach((<no type> col) -> {}) is undefined for the type Collection<Grid.Column<?,T>>
[INFO] [ERROR] Line 1033: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 8021: The method addColumnsSkipSelectionColumnCheck(Collection<Grid.Column<?,T>>, int) in the type Grid<T> is not applicable for the arguments (Set<Grid<T>.SelectionColumn>, int)
[INFO] [ERROR] Line 3897: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 6251: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 2957: Method references are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 4026: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 2339: The method getCell(Element) in the type RowContainer is not applicable for the arguments (JavaScriptObject)
[INFO] [ERROR] Line 5988: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 1459: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 3811: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 4074: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 3356: Method references are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 6508: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 8682: Method references are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 1466: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 2946: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 1822: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 1061: The type Grid<T>.EditorRequestImpl<T> must implement the inherited abstract method EditorHandler.EditorRequest<T>.failure(String, Collection<Grid.Column<?,T>>)
[INFO] [ERROR] Line 6594: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 949: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 4558: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 8681: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 6277: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 6247: The method setSelectionModel(SelectionModel<T>) in the type Grid<T> is not applicable for the arguments (SelectionModel.NoSelectionModel<Object>)
[INFO] [ERROR] Line 6591: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 3338: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 1891: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 8681: The method stream() is undefined for the type List<Grid.Column<?,T>>
[INFO] [ERROR] Line 8977: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 6579: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 6591: The method stream() is undefined for the type Collection<Grid.Column<?,T>>
[INFO] [ERROR] Line 1608: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 592: Type mismatch: cannot convert from ArrayList<Grid.Column<?,capture#36-of ?>> to List<Grid.Column<?,?>>
[INFO] [ERROR] Line 6579: The method forEach((<no type> col) -> {}) is undefined for the type Collection<Grid.Column<?,T>>
[INFO] [ERROR] Line 8273: Lambda expressions are allowed only at source level 1.8 or above
[INFO] Tracing compile failure path for type 'java.util.function.IntConsumer'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/google/gwt/gwt-user/2.8.2/gwt-user-2.8.2.jar!/com/google/gwt/emul/java/util/function/IntConsumer.java'
[INFO] [ERROR] Line 29: Default methods are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 33: Cannot refer to the non-final local variable after defined in an enclosing scope
[INFO] [ERROR] Line 31: Lambda expressions are allowed only at source level 1.8 or above
[INFO] Tracing compile failure path for type 'com.vaadin.client.ui.tabsheet.TabsheetConnector'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/vaadin/vaadin-client/8.3.1/vaadin-client-8.3.1.jar!/com/vaadin/client/ui/tabsheet/TabsheetConnector.java'
[INFO] [ERROR] Line 37: Lambda expressions are allowed only at source level 1.8 or above
[INFO] Tracing compile failure path for type 'com.vaadin.client.ui.textfield.ValueChangeHandler'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/vaadin/vaadin-client/8.3.1/vaadin-client-8.3.1.jar!/com/vaadin/client/ui/textfield/ValueChangeHandler.java'
[INFO] [ERROR] Line 48: Lambda expressions are allowed only at source level 1.8 or above
[INFO] Tracing compile failure path for type 'com.vaadin.shared.ui.dnd.criteria.Criterion'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/vaadin/vaadin-shared/8.3.1/vaadin-shared-8.3.1.jar!/com/vaadin/shared/ui/dnd/criteria/Criterion.java'
[INFO] [ERROR] Line 180: Method references are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 175: The method stream() is undefined for the type Collection<Payload>
[INFO] [ERROR] Line 180: Type mismatch: cannot convert from Object to boolean
[INFO] [ERROR] Line 176: Lambda expressions are allowed only at source level 1.8 or above
[INFO] Tracing compile failure path for type 'java.util.Optional'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/google/gwt/gwt-user/2.8.2/gwt-user-2.8.2.jar!/com/google/gwt/emul/java/util/Optional.java'
[INFO] [ERROR] Line 45: Type mismatch: cannot convert from Optional<capture#2-of ? extends Object> to Optional<T>
[INFO] [ERROR] Line 82: Type mismatch: cannot convert from Optional<capture#9-of ? extends U> to Optional<U>
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/google/gwt/gwt-user/2.8.2/gwt-user-2.8.2.jar!/com/google/gwt/emul/java/util/function/Consumer.java'
[INFO] [ERROR] Line 33: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 31: Default methods are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 35: Cannot refer to the non-final local variable after defined in an enclosing scope
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/google/gwt/gwt-user/2.8.2/gwt-user-2.8.2.jar!/com/google/gwt/emul/java/util/function/Predicate.java'
[INFO] [ERROR] Line 46: Default methods are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 32: The target type of this expression must be a functional interface
[INFO] [ERROR] Line 31: Static methods are allowed in interfaces only at source level 1.8 or above
[INFO] [ERROR] Line 48: Cannot refer to the non-final local variable other defined in an enclosing scope
[INFO] [ERROR] Line 43: Cannot refer to the non-final local variable other defined in an enclosing scope
[INFO] [ERROR] Line 31: Illegal modifier for the interface method isEqual; only public & abstract are permitted
[INFO] [ERROR] Line 41: Default methods are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 37: Default methods are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 48: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 32: Method references are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 38: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 43: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/google/gwt/gwt-user/2.8.2/gwt-user-2.8.2.jar!/com/google/gwt/emul/java/util/function/Function.java'
[INFO] [ERROR] Line 38: Cannot refer to the non-final local variable after defined in an enclosing scope
[INFO] [ERROR] Line 30: Static methods are allowed in interfaces only at source level 1.8 or above
[INFO] [ERROR] Line 41: Default methods are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 31: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 36: Default methods are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 43: Cannot refer to the non-final local variable before defined in an enclosing scope
[INFO] [ERROR] Line 30: Illegal modifier for the interface method identity; only public & abstract are permitted
[INFO] [ERROR] Line 38: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 43: Lambda expressions are allowed only at source level 1.8 or above
[INFO] Tracing compile failure path for type 'java.io.ByteArrayOutputStream'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/google/gwt/gwt-user/2.8.2/gwt-user-2.8.2.jar!/com/google/gwt/emul/java/io/ByteArrayOutputStream.java'
[INFO] [ERROR] Line 196: The method write(byte[], int, int) of type ByteArrayOutputStream must override or implement a supertype method
[INFO] [ERROR] Line 214: The method write(int) of type ByteArrayOutputStream must override or implement a supertype method
[INFO] [ERROR] Line 82: The method close() is undefined for the type OutputStream
[INFO] [ERROR] Line 76: The method close() of type ByteArrayOutputStream must override or implement a supertype method
[INFO] [ERROR] Line 231: The method write(byte[], int, int) is undefined for the type OutputStream
[INFO] Tracing compile failure path for type 'com.vaadin.client.extensions.javascriptmanager.JavaScriptManagerConnector'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/vaadin/vaadin-client/8.3.1/vaadin-client-8.3.1.jar!/com/vaadin/client/extensions/javascriptmanager/JavaScriptManagerConnector.java'
[INFO] [ERROR] Line 41: Lambda expressions are allowed only at source level 1.8 or above
[INFO] Finding entry point classes
[INFO] Tracing compile failure path for type 'com.vaadin.client.ApplicationConfiguration'
[INFO] [ERROR] Errors in 'jar:file:/C:/Users/cristian.lopez/.m2/repository/com/vaadin/vaadin-client/8.3.1/vaadin-client-8.3.1.jar!/com/vaadin/client/ApplicationConfiguration.java'
[INFO] [ERROR] Line 466: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Line 710: Lambda expressions are allowed only at source level 1.8 or above
[INFO] [ERROR] Hint: Check the inheritance chain from your module; it may not be inheriting a required module or a module may not be adding its source path entries properly
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 21.517 s
[INFO] Finished at: 2018-02-14T16:47:06+01:00
[INFO] Final Memory: 18M/434M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.vaadin:vaadin-maven-plugin:8.3.1:compile (default-cli) on project selektron_Rotapick_TestDB: Command [[
[ERROR] C:\Program Files\Java\jdk1.8.0_111\jre\bin\java -Xmx1G -Dgwt.persistentunitcache=false com.google.gwt.dev.Compiler -logLevel INFO -style OBF -war C:\Users\cristian.lopez\workspace\vaadin_Rotapick_8_Compatibility\target\classes\VAADIN\widgetsets -localWorkers 4 -failOnError -XfragmentCount -1 -sourceLevel auto -gen C:\Users\cristian.lopez\workspace\vaadin_Rotapick_8_Compatibility\target\.generated de.psb_gmbh.visualtools.Visualtools
[ERROR] ]] failed with status 1
[ERROR] -> [Help 1]
[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/MojoExecutionException
I have added to my UI class this #Widgetset("com.vaadin.v7.Vaadin7WidgetSet")
In my pom this is what I have.
<packaging>war</packaging>
<version>1.00.02</version>
<name>selektron</name>
<prerequisites>
<maven>3</maven>
</prerequisites>
<properties>
<vaadin.version>8.3.1</vaadin.version>
<vaadin.plugin.version>8.3.1</vaadin.plugin.version>
<jetty.plugin.version>9.3.9.v20160517</jetty.plugin.version>
<project.build.sourceEncoding>ISO-8859-1</project.build.sourceEncoding>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<vaadin.widgetset.mode>local</vaadin.widgetset.mode>
</properties>
As you can see, in every error or almost every one of them, it says "Lambda expressions are allowed only at source level 1.8 or above".
I hope some one have an Idea

Thanks guys for your quick answer.
I've found that there is a problem with vaadin 8 and gwt under 2.8 for lambda's expressions so I needed to upgrade my gwt dependencies from 2.7.0 to 2.8.0 (enter link description here)

Related

GPG key skipped during maven release

I am following all the instructions listed here to release my project to sonatype repo: https://dzone.com/articles/publish-your-artifacts-to-maven-central
But still getting the following error during signing artifacts
[INFO] --- maven-gpg-plugin:3.0.1:sign (sign-artifacts) # exceptionless-client ---
gpg: skipped "0x9d0e3e1d": No secret key
gpg: signing failed: No secret key
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 42.750 s
[INFO] Finished at: 2021-08-03T10:52:18+05:30
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-gpg-plugin:3.0.1:sign (sign-artifacts) on project exceptionless-client: Exit code: 2 -> [Help 1]
[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 rezad the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
I can see the key listed when I run gpg --list-key command.
I used git bash to generate new keys, but I didn't know that git bash also comes with a bundled gpg program and it was using that. However, the maven-gpg-plugin was trying to find keys using the gpg program installed under C:/Program Files(x86). After I created keys using this I installed it worked perfectly.

gcloud function: Could not find local artifact: How to solve?

My cloud function code, is a maven-jar-project. It depends on other internal maven jar, so I have added that dependency to the pom.xml.
Expected: I expect that the dependent jars will be automatically included in the cloud function deployment, however I get an error "could not find artifact". Local compilation & running does not have any issue.
I don't want to copy paste those dependency sourcecode directly to my gcloud maven project. [bad ]
[INFO] Installing <removed>-0.0.1-SNAPSHOT.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.659 s
[INFO] Finished at: 2021-04-10T16:31:39-04:00
[INFO] ------------------------------------------------------------------------
>gcloud functions deploy response-adapter --entry-point fun.pubsub.<removed> --runtime java11 --memory 512MB --trigger-topic <removed>
--env-vars-file env.yml
Deploying function (may take a while - up to 2 minutes)...-
For Cloud Build Stackdriver Logs, visit:
Deploying function (may take a while - up to 2 minutes)...failed.
ERROR: (gcloud.functions.deploy) OperationError: code=3, message=Build failed: ...maven-plugin-2.2.0.jar
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/com/google/cloud/tools/appengine-plugins-core/0.8.1/appengine-plugins-core-0.8.1.jar
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/com/google/inject/guice/4.2.1/guice-4.2.1-no_aop.jar (521 kB at 375 kB/s)
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/org/yaml/snakeyaml/1.21/snakeyaml-1.21.jar
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/commons/commons-lang3/3.8.1/commons-lang3-3.8.1.jar (502 kB at 357 kB/s)
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/org/glassfish/javax.json/1.0.4/javax.json-1.0.4.jar
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/com/google/cloud/tools/appengine-maven-plugin/2.2.0/appengine-maven-plugin-2.2.0.jar (76 kB at 53 kB/s)
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/org/apache/commons/commons-compress/1.19/commons-compress-1.19.jar
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/com/google/cloud/tools/appengine-plugins-core/0.8.1/appengine-plugins-core-0.8.1.jar (236 kB at 164 kB/s)
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/commons-io/commons-io/2.5/commons-io-2.5.jar
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/glassfish/javax.json/1.0.4/javax.json-1.0.4.jar (85 kB at 59 kB/s)
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/yaml/snakeyaml/1.21/snakeyaml-1.21.jar (299 kB at 205 kB/s)
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/commons/commons-compress/1.19/commons-compress-1.19.jar (615 kB at 416 kB/s)
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/commons-io/commons-io/2.5/commons-io-2.5.jar (209 kB at 141 kB/s)
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/com/google/cloud/functions/invoker/java-function-invoker/1.0.2/java-function-invoker-1.0.2.jar (4.2 MB at 2.6 MB/s)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 17.127 s
[INFO] Finished at: 2021-04-10T20:35:09Z
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project gcf-removed-adapter: Could not resolve dependencies for project gcf-demo:gcf-removed-adapter:jar:0.0.1-SNAPSHOT: Could not find artifact myadaptor:removed-mapper:jar:1.0-
SNAPSHOT -> [Help 1]
[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/DependencyResolutionException; Error ID: efa79f31
To achieve this, you need to deploy from JAR. Like that, you create a JAR with all the dependency already included in it (maven shade). No resolution at deployment time, only get your JAR and put it in Cloud Functions.

Compiling Modules Separately and Linking

I'm compiling some very large projects in chisel3 with lots of wires and connections. Right now, the top level object and all of its submodules are in the same Scala package, and I run sbt "runMain top.Instantiator --verilog". However, it crashes in FIRRTL with:
[info] Done packaging.
[info] Running top.Instantiator --verilog --testArgs vcs
[info] [0.005] Elaborating design...
[info] [68.146] Done elaborating.
[error] (run-main-0) java.lang.NegativeArraySizeException
[error] java.lang.NegativeArraySizeException
[error] at java.util.Arrays.copyOf(Arrays.java:3332)
[error] at org.antlr.v4.runtime.ANTLRInputStream.load(ANTLRInputStream.java:101)
[error] at org.antlr.v4.runtime.ANTLRInputStream.<init>(ANTLRInputStream.java:64)
[error] at org.antlr.v4.runtime.ANTLRInputStream.<init>(ANTLRInputStream.java:60)
[error] at org.antlr.v4.runtime.ANTLRInputStream.<init>(ANTLRInputStream.java:68)
[error] at firrtl.Parser$$anonfun$1.apply(Parser.scala:35)
[error] at firrtl.Parser$$anonfun$1.apply(Parser.scala:29)
[error] at firrtl.Utils$.time(Utils.scala:135)
[error] at firrtl.Parser$.parse(Parser.scala:29)
[error] at firrtl.Driver$$anonfun$execute$1.apply(Driver.scala:171)
[error] at firrtl.Driver$$anonfun$execute$1.apply(Driver.scala:140)
[error] at logger.Logger$$anonfun$makeScope$1.apply(Logger.scala:129)
[error] at scala.util.DynamicVariable.withValue(DynamicVariable.scala:58)
[error] at logger.Logger$.makeScope(Logger.scala:127)
[error] at firrtl.Driver$.execute(Driver.scala:140)
[error] at chisel3.Driver$.execute(Driver.scala:180)
[error] at chisel3.Driver$.execute(Driver.scala:200)
[error] at fringe.CommonMain$class.main(CommonMain.scala:64)
[error] at top.Instantiator$.main(Instantiator.scala:17)
[error] at top.Instantiator.main(Instantiator.scala)
[error] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[error] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[error] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[error] at java.lang.reflect.Method.invoke(Method.java:498)
[error] Nonzero exit code: 1
[error] (Compile / runMain) Nonzero exit code: 1
My guess is that the huge number of wires and connections in the project are causing some overflow. Does anyone have experience with this kind of error and advice on how to go about debugging it? Right now, my ideas are to
1) refactor the chisel code to make it easier to compile
2) figure out a way to generate verilog for each module separately and then link them together at the end. Is there a way to compile non-recursively so I don't run into the same error when I get to compiling top.Instantiator?
3) separate the packages/projects somehow so that sbt works on each one separately
Thanks
Adding idea 4) Use protobuf serialization between chisel and firrtl.
I can see that firrtl is blowing up in the parser. The protobuf support is fairly new, but I believe it is much less memory intensive than the antlr based parser.
Here's an example of producing a firrtl protobuf serialization from chisel3
import chisel3._
class XX extends Module {
val io = IO(new Bundle {
val i = Input(UInt(1.W))
val o = Output(UInt(1.W))
})
io.o := io.i
}
object PB {
def main(args: Array[String]): Unit = {
val c = Driver.elaborate(() => new XX)
Driver.dumpProto(c, None)
}
}
You can then generate the verilog with the firrtl compiler
firrtl -i XX.pb -X verilog -o XX.v
Or build your own compiler something like
import firrtl._
object PB {
def main(args: Array[String]): Unit = {
Driver.execute(Array("-i", "XX.pb", "-X", "verilog", "-o", "XX.v"))
}
}
Your other options may be worth pursuing but this might be an easier quick fix.

Jenkins error: Authorization failed to svn in sonarqube.

I am using Jenkins 2.8 with Sonarqube Plugin 2.2.1. A week ago we had a problem with the sonar server and we get this error. To solve the problem we decided to create a new mysql schema and link it with sonar server.
We did something like this:
mysql –u root -plinux;
create database sonarqube2 character set utf8;
grant all privileges on sonarqube2.* to 'sonarsuer'#'localhost' identified by 'linux';
grant all privileges sonarqube2.* to 'sonaruser'#'%' identified by 'linux';
flush privileges;
Note: We used the same user we had in the old database
After update sonar.jdbc.url with the new data in sonar.properties and in Jenkins configuration we manage to deploy sonarqube again. Then, we tried to launch a SONAR job that we have already created before and we get this error:
[ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.6:sonar (default-cli) on project cas: The svn blame command [svn blame --xml --non-interactive -x -w src/main/java/net/mycompany/cas/CookieRetrievingCookieGeneratorPatch.java] failed: svn: OPTIONS of 'https://my_svn_server/svn/mycompanyxf/cas/trunk/src/main/java/net/mycompany/cas/CookieRetrievingCookieGeneratorPatch.java': authorization failed: Could not authenticate to server: rejected Basic challenge (https://my_svn_server) -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.6:sonar (default-cli) on project cas: The svn blame command [svn blame --xml --non-interactive -x -w src/main/java/net/mycompany/cas/CookieRetrievingCookieGeneratorPatch.java] failed: svn: OPTIONS of 'https://my_svn_server/svn/mycompanyxf/cas/trunk/src/main/java/net/mycompany/cas/CookieRetrievingCookieGeneratorPatch.java': authorization failed: Could not authenticate to server: rejected Basic challenge (https://my_svn_server)
This is the whole stacktrace:
[INFO] --- sonar-maven-plugin:2.6:sonar (default-cli) # cas ---
[INFO] SonarQube version: 5.0.1
[WARNING] Invalid POM for org.samba.jcifs:jcifs-ext:jar:0.9.4, transitive dependencies (if any) will not be available, enable debug logging for more details
INFO: Default locale: "es_ES", source code encoding: "UTF-8" (analysis is platform dependent)
INFO: Work directory: /u01/jenkins_home/jobs/SONAR - MC - Cas/workspace/trunk/target/sonar
INFO: SonarQube Server 5.0.1
[INFO] [13:47:05.297] Load global referentials...
[INFO] [13:47:05.751] Load global referentials done: 458 ms
[INFO] [13:47:05.771] User cache: /home/tomcat/.sonar/cache
[INFO] [13:47:05.801] Install plugins
[INFO] [13:47:07.792] Install JDBC driver
[INFO] [13:47:07.802] Create JDBC datasource for jdbc:mysql://myserver:3306/sonarqube2?useUnicode=true&characterEncoding=utf8
[INFO] [13:47:11.353] Initializing Hibernate
[ERROR] [13:47:15.591] No license for plugin views
[INFO] [13:47:16.958] Load project referentials...
[INFO] [13:47:18.003] Load project referentials done: 1045 ms
[INFO] [13:47:18.003] Load project settings
[INFO] [13:47:19.038] Loading technical debt model...
[INFO] [13:47:19.097] Loading technical debt model done: 59 ms
[INFO] [13:47:19.115] Apply project exclusions
[INFO] [13:47:19.336] ------------- Scan CAS (Central Authentication Service)
[INFO] [13:47:19.339] Load module settings
[INFO] [13:47:21.334] Loading rules...
[INFO] [13:47:23.049] Loading rules done: 1715 ms
[INFO] [13:47:23.115] Configure Maven plugins
[INFO] [13:47:23.367] No quality gate is configured.
[INFO] [13:47:29.435] Initializer FindbugsMavenInitializer...
[INFO] [13:47:29.437] Initializer FindbugsMavenInitializer done: 2 ms
[INFO] [13:47:29.437] Base dir: /u01/jenkins_home/jobs/SONAR - MC - Cas/workspace/trunk
[INFO] [13:47:29.437] Working dir: /u01/jenkins_home/jobs/SONAR - MC - Cas/workspace/trunk/target/sonar
[INFO] [13:47:29.438] Source paths: src/main/webapp, pom.xml, src/main/java
[INFO] [13:47:29.438] Test paths: src/test/java
[INFO] [13:47:29.439] Binary dirs: target/classes
[INFO] [13:47:29.439] Source encoding: UTF-8, default locale: es_ES
[INFO] [13:47:29.439] Index files
[INFO] [13:47:30.480] 36 files indexed
[INFO] [13:47:31.213] Quality profile for java: Sonar way
[INFO] [13:47:31.213] Quality profile for js: Sonar way
[INFO] [13:47:31.300] JIRA issues sensor will not run as some parameters are missing.
[INFO] [13:47:31.392] Sensor JavaSquidSensor...
[INFO] [13:47:32.089] Java Main Files AST scan...
[INFO] [13:47:32.094] 25 source files to be analyzed
[INFO] [13:47:36.733] Java Main Files AST scan done: 4643 ms
[INFO] [13:47:36.733] 25/25 source files analyzed
[INFO] [13:47:36.746] Java bytecode scan...
[INFO] [13:47:37.302] Java bytecode scan done: 556 ms
[INFO] [13:47:37.305] Java Test Files AST scan...
[INFO] [13:47:37.306] 5 source files to be analyzed
[INFO] [13:47:37.626] 5/5 source files analyzed
[INFO] [13:47:37.627] Java Test Files AST scan done: 321 ms
[INFO] [13:47:37.633] Package design analysis...
[INFO] [13:47:37.684] Package design analysis done: 51 ms
[INFO] [13:47:37.801] Sensor JavaSquidSensor done: 6409 ms
[INFO] [13:47:37.813] Sensor QProfileSensor...
[INFO] [13:47:37.819] Sensor QProfileSensor done: 6 ms
[INFO] [13:47:37.819] Sensor Maven dependencies...
[INFO] [13:47:40.023] Sensor Maven dependencies done: 2204 ms
[INFO] [13:47:40.026] Sensor JavaScriptSquidSensor...
[INFO] [13:47:40.205] 6 source files to be analyzed
[INFO] [13:47:45.590] 6/6 source files analyzed
[INFO] [13:47:48.499] Sensor JavaScriptSquidSensor done: 8473 ms
[INFO] [13:47:48.506] Sensor CoverageSensor...
[INFO] [13:47:48.507] Sensor CoverageSensor done: 1 ms
[INFO] [13:47:48.507] Sensor InitialOpenIssuesSensor...
[INFO] [13:47:48.525] Sensor InitialOpenIssuesSensor done: 18 ms
[INFO] [13:47:48.525] Sensor ProjectLinksSensor...
[INFO] [13:47:48.557] Sensor ProjectLinksSensor done: 32 ms
[INFO] [13:47:48.558] Sensor VersionEventsSensor...
[INFO] [13:47:48.600] Sensor VersionEventsSensor done: 42 ms
[INFO] [13:47:48.600] Sensor FileHashSensor...
[INFO] [13:47:48.608] Sensor FileHashSensor done: 8 ms
[INFO] [13:47:48.610] Sensor CoberturaSensor...
[INFO] [13:47:48.616] parsing /u01/jenkins_home/jobs/SONAR - MC - Cas/workspace/trunk/target/site/cobertura/coverage.xml
[INFO] [13:47:49.078] Sensor CoberturaSensor done: 468 ms
[INFO] [13:47:49.078] Sensor SCM Sensor...
[INFO] [13:47:49.089] SCM provider for this project is: svn
[INFO] [13:47:49.089] Retrieve SCM blame information...
[INFO] [13:47:49.218] 36 files to be analyzed
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1:04.240s
[INFO] Finished at: Fri Aug 12 13:47:54 CEST 2016
[INFO] Final Memory: 58M/955M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.6:sonar (default-cli) on project cas: The svn blame command [svn blame --xml --non-interactive -x -w src/main/java/net/mycompany/cas/CookieRetrievingCookieGeneratorPatch.java] failed: svn: OPTIONS of 'https://my_svn_server/svn/mycompanyxf/cas/trunk/src/main/java/net/mycompany/cas/CookieRetrievingCookieGeneratorPatch.java': authorization failed: Could not authenticate to server: rejected Basic challenge (https://my_svn_server) -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.6:sonar (default-cli) on project cas: The svn blame command [svn blame --xml --non-interactive -x -w src/main/java/net/mycompany/cas/CookieRetrievingCookieGeneratorPatch.java] failed: svn: OPTIONS of 'https://my_svn_server/svn/mycompanyxf/cas/trunk/src/main/java/net/mycompany/cas/CookieRetrievingCookieGeneratorPatch.java': authorization failed: Could not authenticate to server: rejected Basic challenge (https://my_svn_server)
Should I change aditional credential in Jenkins?
Any help would be appreciated.
See SonarQube 5.0 SCM support documentation for details on how to configure SVN authentication (which is what is failing here) using sonar.svn.username and sonar.svn.password.secured.
(side-note: SonarQube 5.0 is pretty old and known for having performance issues, you should really upgrade to latest/LTS version)

Chisel tools installation; Unable to fint scct

I am trying to get started with Chisel. Following the instructions on Chisel web page, I installed scala 2.11 and sbt, copied the build.sbt and Hello World example. However, I am unable to run the example. I am getting following errors.
tariq#ubuntu:~/work/scala-test$ sbt run
[info] Set current project to scala-test (in build file:/home/tariq/work/scala-test/)
[info] Updating {file:/home/tariq/work/scala-test/}scala-test...
[info] Resolving com.github.scct#sbt-scct;0.2.1 ...
[warn] Host repo1.maven.org not found. url=https://repo1.maven.org/maven2/com/github/scct/sbt-scct_2.11_0.13/0.2.1/sbt-scct-0.2.1.pom
[info] You probably access the destination server through a proxy server that is not well configured.
[warn] module not found: com.github.scct#sbt-scct;0.2.1
[warn] ==== local: tried
<snip>
info] Resolving jline#jline;2.12 ...
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: UNRESOLVED DEPENDENCIES ::
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: com.github.scct#sbt-scct;0.2.1: not found
[warn] :: edu.berkeley.cs#chisel_2.11;latest.release: not found
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn]
[warn] Note: Some unresolved dependencies have extra attributes. Check that these dependencies exist with the requested attributes.
[warn] com.github.scct:sbt-scct:0.2.1 (sbtVersion=0.13, scalaVersion=2.11)
<snip>
at java.lang.Thread.run(Thread.java:745)
[error] (*:update) sbt.ResolveException: unresolved dependency: com.github.scct#sbt-scct;0.2.1: not found
[error] unresolved dependency: edu.berkeley.cs#chisel_2.11;latest.release: not found
[error] Total time: 23 s, completed Nov 19, 2014 4:26:38 PM
It appears sbt can't reach the internet (4th [info] line refers to this).
sbt needs to be able to reach the internet in order to download packages.
Are you behind a proxy? Are you running this in a VM?