Okay, I'm about 80% sure that I understand and can remedy the problem within HtmlUnit itself. Will update once I finish syncing the apparently canonical SVN repo to git, so I can go over the history more carefully and ensure that this break isn't deliberate.
A question for my fellow GWT maintainers: should I patch the version of HtmlUnit that we presently use, so that we avoid breaking downstream expectations (plugins that specify specific browsers, use if IE8 or IE11 as a user agent to run the tests as)? Or should I see about getting this patch into the next version of HtmlUnit, and we wait on their release cycle, and leave this broken until then?
Okay, I'm about 80% sure that I understand and can remedy the problem within HtmlUnit itself. Will update once I finish syncing the apparently canonical SVN repo to git, so I can go over the history more carefully and ensure that this break isn't deliberate.
Exactly - I wasn't planning on adding the javaToJs(), but was going to unwrap the exception before calling onerror (or have ScriptException implement Scriptable). Have a short test that demonstrates the issue without gwt (but wow they have a lot of GWT in their source tree), and am was waiting for my svn->git sync to finish to confirm what you did by hand. Just in case we decide to rebase it along, or make other improvements down the road...
Like we do for com.google.gwt.junit.RunStyleHtmlUnit.HostedJavaScriptEngine so we can hook in the "plugin". Looks like that idea might be a winner! Just make sure to swap it in both cases, don't want to kill tests in old dev mode.
Patch is accepted and merged into upstream HtmlUnit, see https://sourceforge.net/p/htmlunit/bugs/1924/ for more detail.Daniel, when you can take a look at Thomas's question, we can get this change made to open source GWT as you requested.
--
You received this message because you are subscribed to the Google Groups "GWT Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit-co...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit-contributors/245093f8-c1c1-4e71-9291-0b9e3af66eb9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
I'll try with the manual runstyle, i.e. with a real browser, and see how it goes. Thanks for the feedback.
--
You received this message because you are subscribed to the Google Groups "GWT Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit-contributors+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit-contributors/1fab1f52-557b-4857-a0a9-f017c1d4822d%40googlegroups.com.
tbroyer: Are you using batch mode while testing? We are using -batch module internally and maybe you guys do not externally? (though you linked the code that only runs in batch mode, IIRC).
As discussed minutes ago in meeting: here's the patch to enable -batch module for all our HtmlUnit tests: https://gwt-review.googlesource.com/c/gwt/+/19740
Once that one and the HtmlUnit workaround are in, we can rebase Daniel's patch about trapping window.onerror by default.
On Wednesday, October 11, 2017 at 10:52:41 AM UTC+2, Thomas Broyer wrote:
On Wednesday, October 11, 2017 at 4:52:06 AM UTC+2, Goktug Gokdogan wrote:tbroyer: Are you using batch mode while testing? We are using -batch module internally and maybe you guys do not externally? (though you linked the code that only runs in batch mode, IIRC).That's right, we do not use batch mode, **and** it fixes the tests! \o/I wonder, should the default batching strategy be changed to module? or should we use "-batch module" for all tests? only HtmlUnit tests? (we only run those on CI anyway; also I tested in Firefox with -runStyle ExternalBrowser:firefox, and the tests pass without the need for -batch module)What would you recommend?Colin: do we try to slip this into 2.8.2 at the last minute? (and possibly revert if there's any red flag during smoke testing)Daniel/Goktug: iiuc, this change means that you no longer need to wrap everything into $entry() to get the UncaughtExceptionHandler called on errors, right? This makes things easier with JsInterop and @JsFunction callbacks (or exposing objects whose @JsMethods will be called from JS), but as a non-negligible side effect you won't get the Scheduler.scheduleEntry and Scheduler.scheduleFinally commands called. Am I getting things right?
On Tue, Oct 10, 2017 at 1:04 PM, Thomas Broyer <t.br...@gmail.com> wrote:
I'll try with the manual runstyle, i.e. with a real browser, and see how it goes. Thanks for the feedback.
--
You received this message because you are subscribed to the Google Groups "GWT Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit-contributors+unsu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit-contributors/1fab1f52-557b-4857-a0a9-f017c1d4822d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "GWT Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit-contributors+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit-contributors/f9fcbd96-ae33-430e-8fda-1cca8ad8b07a%40googlegroups.com.
PS: pls avoid the urge to discuss technical stuff in steering commitee and try to keep it in the contributor list ;)
Alternatively, gitter.im/gwtproject/gwt is extremely active, and only missing representation from google. LIkewise could schedule some time to quickly discuss things.
--
You received this message because you are subscribed to the Google Groups "GWT Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit-contributors+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit-contributors/dcb140db-cb06-4cca-8d29-51364f5a95a9%40googlegroups.com.
There should be something around syncToServer + HtmlUnit causes the issue (I guess RPC gets called back sooner than timeout(0) but didn't debug) but I don't think this in practice will effect anything else.Enabling batch mode by default for everything potentially effects timeouts also sometimes it might be incompatible with the test runner that drives the java side of the tests (for example it doesn't work well with our internal test sharding mechanism). Hence I don't think it worths the trouble. I think just having batch mode enabled for junit tests is good enough to move forward.
Daniel's patch is important for both hand written jsinterop code and Elemental2 and yes unfortunately Scheduler.scheduleFinally will be affected.
PS: pls avoid the urge to discuss technical stuff in steering commitee and try to keep it in the contributor list ;)