Re: Issue with GWT 2.9.0 and Annotations/Predicates emulation

2020-05-29 Thread David Nouls
I was too quick to declare victory. 

I did not realize that I was no longer building with GWT 2.9.0 due to a bad 
merge my pom was overwritten with 2.8.2 again.

But what you just wrote helped indeed. I was still using jsinterop-base 
1.0.0-RC1 and jsinterop-annotations 1.0.0.

Thanks for the help once more. Now I have a second problem, this time with 
some generics that is accepted by javac or IntelliJ but GWTC seems to not 
support it.


On Thursday, May 28, 2020 at 8:25:37 PM UTC+2, Colin Alworth wrote:
>
> Glad you solved yours! As another update, we've seen two other cases of 
> something that looks sort of similar to this.
>
> In one instance, there was a dependency in the project of an old version 
> of jsinterop-annotations, instead of the expected 2.0.0 release.
>
> In the other instance, the project was creating a massive "reflection 
> cache" of all annotations - the two fixes are to either exclude the 
> jsinterop annotations from the cache (abbreviated rant: a cache like this 
> should be based on a whitelist, not a blacklist), or provide sources and a 
> .gwt.xml file for the annotations.
>
> -Colin
>
> On Thursday, May 28, 2020 at 1:03:48 PM UTC-5, David Nouls wrote:
>>
>> Strange, just retried today and now the compile worked properly.
>>
>> Thanks for the support!
>> On 19 May 2020, 16:41 +0200, Colin Alworth > >, wrote:
>>
>> Nothing should have changed here as far as I am aware - GWT itself 
>> continues to have emulation for Annotation, Enum, etc (Predicate doesnt 
>> seem to be listed in your error)
>>
>> https://gwt.googlesource.com/gwt/+/master/user/super/com/google/gwt/emul/java/lang/annotation/Annotation.java
>>
>> https://gwt.googlesource.com/gwt/+/master/user/super/com/google/gwt/emul/java/lang/Enum.java
>>
>> One change was made in .gwt.xml files with their inherits - the 
>> jsinterop-annotations jar no longer contains a .gwt.xml file, and so 
>> Core.gwt.xml no longer references it (nor did it need to to begin with).
>>
>> Are you compiling with -strict, and if so, is this the entire log?
>>
>> I just pulled https://github.com/nmorel/gwt-jackson/ and updated it to 
>> use gwt 2.9, and it seems to run its tests cleanly for the main gwt-jackson 
>> package, and after I also update guava, the whole build passes:
>> [INFO] Reactor Summary for gwt-jackson :: Extensions :: Guava 
>> 0.15.5-SNAPSHOT:
>> [INFO]
>> [INFO] gwt-jackson :: Extensions :: Guava . SUCCESS [ 
>> 35.796 s]
>> [INFO] gwt-jackson :: Extensions :: Objectify . SUCCESS [ 
>> 27.423 s]
>> [INFO] gwt-jackson :: Extensions :: Remote Logging  SUCCESS [ 
>> 22.288 s]
>> [INFO] gwt-jackson :: Examples  SUCCESS [  
>> 0.241 s]
>> [INFO] gwt-jackson :: Examples :: Minimal . SUCCESS [ 
>> 11.884 s]
>> [INFO] gwt-jackson :: Examples :: Hello World . SUCCESS [ 
>> 15.610 s]
>> [INFO] gwt-jackson :: Examples :: GWTP  SUCCESS [ 
>> 17.687 s]
>> [INFO] gwt-jackson :: Examples :: Requestor ... SUCCESS [ 
>> 19.848 s]
>> [INFO] gwt-jackson :: Examples :: RestyGWT  SUCCESS [ 
>> 16.277 s]
>> [INFO] 
>> 
>> [INFO] BUILD SUCCESS
>> [INFO] 
>> 
>> [INFO] Total time:  02:47 min
>> [INFO] Finished at: 2020-05-19T09:36:53-05:00
>> [INFO] 
>> 
>>
>> Changes I made to run this:
>>
>> diff --git a/extensions/guava/pom.xml b/extensions/guava/pom.xml
>> index 99e928a..739b629 100644
>> --- a/extensions/guava/pom.xml
>> +++ b/extensions/guava/pom.xml
>> @@ -29,7 +29,7 @@
>>Extension to support Guava types like Optional or 
>> ImmutableSet
>>  
>>
>> -19.0
>> +29.0-jre
>>
>>  
>>
>> diff --git a/pom.xml b/pom.xml
>> index 8eb1f1d..6250ad4 100644
>> --- a/pom.xml
>> +++ b/pom.xml
>> @@ -86,10 +86,10 @@
>>  2.8.1
>>  2.4
>>  2.10.4
>> -2.7.0
>> +2.8.2
>>  
>>  
>> -2.7.0
>> +2.9.0
>>  2.10.1
>>  1.0.0
>>  4.12
>> @@ -201,6 +201,7 @@
>>  1000
>>  

GWTC 2.9.0 has problems compiling my generics

2020-05-29 Thread David Nouls
I switched from GWT 2.8.2 to GWT 2.9.0 and I get some GWTC compilation 
errors when compiling with certain generic constructs.
It compiles fine with JDK11 and in IntelliJ, but GWTC no longer seems to 
support this:

[INFO] --- gwt-maven-plugin:1.0.0:compile (default-compile) @ 
cloud.platform.ui.demo-app ---
[INFO] Compiling module com.swift.cloud.platform.ui.demo.Demo
[INFO]Tracing compile failure path for type 
'com.swift.cloud.platform.ui.webcomponent.widget.query.QueryEditor'
[INFO]   [ERROR] Errors in 
'jar:file:/home/dnouls/liteevolutiontfr/platform/main/ui/webcomponent/target/cloud.platform.ui.webcomponent-0.0.5-SNAPSHOT.jar!/com/swift/cloud/platform/ui/webcomponent/widget/query/QueryEditor.java'
[INFO]  [ERROR] Line 376: The method byKey(IFilterKey) in the 
type QueryConfiguration is not applicable for the arguments (capture#67-of 
? extends IFilterKey)
[INFO][ERROR] Aborting compile due to errors in some input files


A small piece of the QueryEditor class where this error is reported:

  public void setFilterKeys(Set> filterKeys) {
this.allowedFilterKeys = filterKeys.stream().filter(key -> 
config.byKey(key).isPresent()).collect(Collectors.toCollection(ArrayList::new));

// sort by label

allowedFilterKeys.sort(Comparator.comparing(config.getLabels()::getKeyLabel));
  }

This is the method that it is trying to call:
  @SuppressWarnings("unchecked")
  public > 
Optional byKey(IFilterKey key) {
return Optional.ofNullable((CONFIG) byKey.get(key));
  }

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/011da579-79ee-4bf2-946f-93e095d0c58d%40googlegroups.com.


Re: GWTC 2.9.0 has problems compiling my generics

2020-05-29 Thread Gordan Krešić
Interestingly, I've run into exactly the same issue yesterday, but other way 
around: my code compiles in GWT 2.9 (and javac and Eclipse), but not in GWT 
2.8.2 which refuses to accept parameters for one method with generics-heavy 
signature.


I've even explored the possibility to force GWT 2.8.2 to use newer ecj, but 
it's bundled in gwt.dev.jar.


Any help is appreciated.

-gkresic.


On 29. 05. 2020. 14:07, David Nouls wrote:
I switched from GWT 2.8.2 to GWT 2.9.0 and I get some GWTC compilation 
errors when compiling with certain generic constructs.
It compiles fine with JDK11 and in IntelliJ, but GWTC no longer seems to 
support this:


[INFO] --- gwt-maven-plugin:1.0.0:compile (default-compile) @ 
cloud.platform.ui.demo-app ---

[INFO] Compiling module com.swift.cloud.platform.ui.demo.Demo
[INFO]    Tracing compile failure path for type 
'com.swift.cloud.platform.ui.webcomponent.widget.query.QueryEditor'
[INFO]   [ERROR] Errors in 
'jar:file:/home/dnouls/liteevolutiontfr/platform/main/ui/webcomponent/target/cloud.platform.ui.webcomponent-0.0.5-SNAPSHOT.jar!/com/swift/cloud/platform/ui/webcomponent/widget/query/QueryEditor.java'
[INFO]  [ERROR] Line 376: The method byKey(IFilterKey) in the 
type QueryConfiguration is not applicable for the arguments (capture#67-of ? 
extends IFilterKey)

[INFO]    [ERROR] Aborting compile due to errors in some input files


A small piece of the QueryEditor class where this error is reported:

   public void setFilterKeys(Set> filterKeys) {
     this.allowedFilterKeys = filterKeys.stream().filter(key -> 
config.byKey(key).isPresent()).collect(Collectors.toCollection(ArrayList::new));


     // sort by label
 
allowedFilterKeys.sort(Comparator.comparing(config.getLabels()::getKeyLabel));

   }

This is the method that it is trying to call:
   @SuppressWarnings("unchecked")
   public > 
Optional byKey(IFilterKey key) {

     return Optional.ofNullable((CONFIG) byKey.get(key));
   }

--
You received this message because you are subscribed to the Google Groups 
"GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an 
email to google-web-toolkit+unsubscr...@googlegroups.com 
.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/011da579-79ee-4bf2-946f-93e095d0c58d%40googlegroups.com 
.


--
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/c4ba1317-bac8-9682-022c-3d3e9e0c26fc%40steatoda.com.


Re: GWTC 2.9.0 has problems compiling my generics

2020-05-29 Thread Jens
So the Eclipse JDT version GWT uses has a generics bug then. Have you tried 
open the project/code in Eclipse to see if Eclipse complains as well? If 
Eclipse does not complain then it is probably fixed and we can likely just 
upgrade JDT again in GWT.

-- J.

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/1e4ad874-4106-46e6-ae82-86691ee50951%40googlegroups.com.


Re: GWTC 2.9.0 has problems compiling my generics

2020-05-29 Thread David Nouls
I don't have access to eclipse in my work environment - not allowed. 

On Friday, May 29, 2020 at 3:02:00 PM UTC+2, Jens wrote:
>
> So the Eclipse JDT version GWT uses has a generics bug then. Have you 
> tried open the project/code in Eclipse to see if Eclipse complains as well? 
> If Eclipse does not complain then it is probably fixed and we can likely 
> just upgrade JDT again in GWT.
>
> -- J.
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/7109c742-05c9-4d8b-8dcf-f96e4caa4142%40googlegroups.com.


Re: Issue with GWT 2.9.0 and Annotations/Predicates emulation

2020-05-29 Thread Thomas Broyer

On Friday, May 29, 2020 at 1:55:42 PM UTC+2, David Nouls wrote:
>
>
> Now I have a second problem, this time with some generics that is accepted 
> by javac or IntelliJ but GWTC seems to not support it.
>

Same here (on a third-party lib that hasn't been maintained for nearly 2 
years 😭)

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/653933bc-c3fe-4ac5-9929-79903aa0cec1%40googlegroups.com.


Re: Issue with GWT 2.9.0 and Annotations/Predicates emulation

2020-05-29 Thread Colin Alworth
We did see type inference issues in earlier builds of the JDT version that 
GWT uses, but after an update was done we thought that the issues were 
resolved.

Can you give an example so we can check to see if JDT has handled this in a 
later update that we can migrate to?

On Friday, May 29, 2020 at 9:21:54 AM UTC-5, Thomas Broyer wrote:
>
>
> On Friday, May 29, 2020 at 1:55:42 PM UTC+2, David Nouls wrote:
>>
>>
>> Now I have a second problem, this time with some generics that is 
>> accepted by javac or IntelliJ but GWTC seems to not support it.
>>
>
> Same here (on a third-party lib that hasn't been maintained for nearly 2 
> years 😭)
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/9297b6cc-dc08-467e-88bd-0f8a61e1a79a%40googlegroups.com.


Re: Issue with GWT 2.9.0 and Annotations/Predicates emulation

2020-05-29 Thread Colin Alworth
Whoops, sorry, I see it in the other thread 
"https://groups.google.com/d/topic/google-web-toolkit/aCWkpXWVsD4/discussion";.

On Friday, May 29, 2020 at 9:43:36 AM UTC-5, Colin Alworth wrote:
>
> We did see type inference issues in earlier builds of the JDT version that 
> GWT uses, but after an update was done we thought that the issues were 
> resolved.
>
> Can you give an example so we can check to see if JDT has handled this in 
> a later update that we can migrate to?
>
> On Friday, May 29, 2020 at 9:21:54 AM UTC-5, Thomas Broyer wrote:
>>
>>
>> On Friday, May 29, 2020 at 1:55:42 PM UTC+2, David Nouls wrote:
>>>
>>>
>>> Now I have a second problem, this time with some generics that is 
>>> accepted by javac or IntelliJ but GWTC seems to not support it.
>>>
>>
>> Same here (on a third-party lib that hasn't been maintained for nearly 2 
>> years 😭)
>>
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/8abd3efd-c2f0-423d-8a2d-fa062d7f96a1%40googlegroups.com.


Re: Issue with GWT 2.9.0 and Annotations/Predicates emulation

2020-05-29 Thread David Nouls
Sorry, I created a different topic since I did not want to mix 2 problems 
in one group chat.

On Friday, May 29, 2020 at 4:44:46 PM UTC+2, Colin Alworth wrote:
>
> Whoops, sorry, I see it in the other thread "
> https://groups.google.com/d/topic/google-web-toolkit/aCWkpXWVsD4/discussion
> ".
>
> On Friday, May 29, 2020 at 9:43:36 AM UTC-5, Colin Alworth wrote:
>>
>> We did see type inference issues in earlier builds of the JDT version 
>> that GWT uses, but after an update was done we thought that the issues were 
>> resolved.
>>
>> Can you give an example so we can check to see if JDT has handled this in 
>> a later update that we can migrate to?
>>
>> On Friday, May 29, 2020 at 9:21:54 AM UTC-5, Thomas Broyer wrote:
>>>
>>>
>>> On Friday, May 29, 2020 at 1:55:42 PM UTC+2, David Nouls wrote:


 Now I have a second problem, this time with some generics that is 
 accepted by javac or IntelliJ but GWTC seems to not support it.

>>>
>>> Same here (on a third-party lib that hasn't been maintained for nearly 2 
>>> years 😭)
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/b600dbc8-50b2-40f3-b38e-3a326f118bd0%40googlegroups.com.


Re: GWTC 2.9.0 has problems compiling my generics

2020-05-29 Thread David Nouls
I changed my maven pom to select 3.20.0 of org.eclipse.jdt:ecj as that 
seemed to be the only dependency from eclipse.jdt.
But the compilation still failed with the same error.

I also tried 3.21.0 but there the compilation does not seem to ever finish 
(cpu usage goes to 0%).


On Friday, May 29, 2020 at 4:16:14 PM UTC+2, David Nouls wrote:
>
> I don't have access to eclipse in my work environment - not allowed. 
>
> On Friday, May 29, 2020 at 3:02:00 PM UTC+2, Jens wrote:
>>
>> So the Eclipse JDT version GWT uses has a generics bug then. Have you 
>> tried open the project/code in Eclipse to see if Eclipse complains as well? 
>> If Eclipse does not complain then it is probably fixed and we can likely 
>> just upgrade JDT again in GWT.
>>
>> -- J.
>>
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/2813517e-37db-4cc2-8dde-6b14cb6a6eee%40googlegroups.com.


Re: GWTC 2.9.0 has problems compiling my generics

2020-05-29 Thread Thomas Broyer
Log of the error in our project:
   Tracing compile failure path for type 
'org.waveprotocol.wave.model.supplement.WaveletBasedSupplement'
  [ERROR] Errors in 
'jar:file:/home/tbr/.gradle/caches/modules-2/files-2.1/org.waveprotocol.waveinabox/waveinabox-model/0.3-atolcd-1206559-patched-4/4a2a46fd36d1308d05cc705a3ee055401c6cc5e3/waveinabox-model-0.3-atolcd-1206559-patched-4-sources.jar!/org/waveprotocol/wave/model/supplement/WaveletBasedSupplement.java'
 [ERROR] Line 948: The method createWaveletSeenVersion(
DocumentEventRouter) in the type WaveletBasedSupplement is 
not applicable for the arguments (DocumentEventRouter)
 [ERROR] Line 943: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 953: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 918: The method createMuted(DocumentEventRouter) in the type WaveletBasedSupplement is not applicable for the 
arguments (DocumentEventRouter)
 [ERROR] Line 933: The method createPendingNotification(
DocumentEventRouter) in the type WaveletBasedSupplement is 
not applicable for the arguments (DocumentEventRouter)
 [ERROR] Line 938: The method createWaveletReadState(
DocumentEventRouter, ObservablePrimitiveSupplement.Listener) 
in the type WaveletBasedSupplement is not applicable for the arguments (
DocumentEventRouter, 
ObservablePrimitiveSupplement.Listener)
 [ERROR] Line 958: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 923: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 913: The method createFolders(DocumentEventRouter) in the type WaveletBasedSupplement is not applicable for the 
arguments (DocumentEventRouter)
 [ERROR] Line 913: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 938: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 933: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 943: The method createWaveletCollapsedState(
DocumentEventRouter, ObservablePrimitiveSupplement.Listener) 
in the type WaveletBasedSupplement is not applicable for the arguments (
DocumentEventRouter, 
ObservablePrimitiveSupplement.Listener)
 [ERROR] Line 948: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 923: The method createCleared(DocumentEventRouter) in the type WaveletBasedSupplement is not applicable for the 
arguments (DocumentEventRouter)
 [ERROR] Line 958: The method createAbuseStore(DocumentEventRouter) in the type WaveletBasedSupplement is not applicable for the 
arguments (DocumentEventRouter)
 [ERROR] Line 953: The method createWaveletNotifiedVersion(
DocumentEventRouter) in the type WaveletBasedSupplement is 
not applicable for the arguments (DocumentEventRouter)
 [ERROR] Line 918: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 963: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 928: The method create(ObservableMutableDocument) in the type DefaultDocumentEventRouter is not applicable for the 
arguments (ObservableMutableDocument)
 [ERROR] Line 963: The method createGadgetStatesDoc(
DocumentEventRouter, ObservablePrimitiveSupplement.Listener) 
in the type WaveletBasedSupplement is not applicable for the arguments (
DocumentEventRouter, 
ObservablePrimitiveSupplement.Listener)
 [ERROR] Line 928: The method createWaveletArchiveState(
DocumentEventRouter) in the type WaveletBasedSupplement is 
not applicable for the arguments (DocumentEventRouter)
   [ERROR] Aborting compile due to errors in some input files


This is the exact file that doesn't compile (and yes, it's very, very old! 
not even the latest code from the Wave project)
https://github.com/apache/incubator-retired-wave/blob/cdee9941674e5ad5e010eed361c64c4233aebf2e/src/org/waveprotocol/wave/model/supplement/WaveletBasedSupplement.java

Ha ha, notice the comment above those errors: 
https://github.com/apache/in