Sorry, I phrased that poorly.
Old scheduler with "old events" (i.e. from JSNI that correctly uses $entry, buggy JSNI forgetting $entry doesnt count) will work properly, and old/new events with new scheduler will work too. The problem is in old scheduler with "new" events - anything using plain jsinterop and avoiding $entry on its way into JS from Java. There is no fix we can do in GWT for it, old Scheduler assumes always that Entry owns all chances for JS to call Java, and so correctly wires up GWT's side of the event loop as well as uncaught exception handling.
Another option than triggering a fixed delay is to decide when the finally should be invoked, and call SchedulerImpl.INSTANCE.flushFinallyCommands(), that will trigger them all to take place right away. This is what $entry does, after your event is entirely handled in Java.
As a workaround, it may be possible to extend com.google.gwt.core.client.SchedulerImpl and splice in the Promise wiring found in gwt-core. Three bad effects off the top of my head:
* scheduleEntry won't work (deprecated in gwt-core, there is no way to do this without requiring $entry or the like)
* legacy dev mode won't work (it _might_ be possible to work around this, but for this last issue...)
* any browser without Promise support won't work, or will have a still-wrong hack in it (without promises, you need another microtask implementation, and of the browsers that don't have Promise, most don't have MutationObserver either which is the go-to hack I've found. Are there other hacks?) - you may end up with the "finally" happening after the next event or after some other timer instead of before it.
Filing it sounds good - we can offer the tradeoffs, and if someone has the need and the bandwidth to resolve this problem fully, we probably can get most of the way there, provided they can accept the caveats and test heavily.
> You received this message because you are subscribed to a topic in the
> Google Groups "GWT Users" group.
> To unsubscribe from this topic, visit
> To unsubscribe from this group and all its topics, send an email to
> To view this discussion on the web visit