flow icon indicating copy to clipboard operation
flow copied to clipboard

Upgrade to vaadin 23.2 causes navigation to fail/timeout

Open bsutton opened this issue 2 years ago • 3 comments

Description of the bug

We have just upgraded from vadin 23.1.3 to 23.2.0

We have an oauth login process that displays a 'validating login' page which is displayed whilst a background thread completes the validation. Once the validation completes we essentially call:

ui.access(() -> UI.getCurrent().navigate(HomePage.class);

The problem is that the navigation is hanging for some 10+seconds and then continues. In the browser console logs we are seeing: Firefox can’t establish a connection to the server at wss://squarephone.biz:45801/VAADIN/.

Watching the network traffic it looks like that after the second time firefox complains (with the above error), vite then does a restart and then the login resumes.

This is in a development environment so I assume that vite is running its own little server.

We have had this same problem with earlier attempts to move to vaadin/vite.

If I re-activate webpack via: com.vaadin.experimental.webpackForFrontendBuild=true

Then the problem goes away.

Expected behavior

navigation to home page should proceed without a long delay.

Minimal reproducible example

as per the bug description.

Versions

  • Vaadin / Flow version: 23.2
  • Java version: 17
  • OS version: ubuntu 22.04
  • Browser version (if applicable): firefox 104.02
  • Application Server (if applicable): spring boot
  • IDE (if applicable): eclipse

bsutton avatar Sep 15 '22 06:09 bsutton

I've just tested using vite with chrome and chrome doesn't have the same problem.

So this looks like its a vite/firefox bug.

bsutton avatar Sep 15 '22 06:09 bsutton

Hi, are you able to create a small example project that demonstrates the problem? Without any possibility to debug it sounds quite impossible to fix. If oauth2 is relevant, maybe it can be based on the test project in https://github.com/vaadin/flow/issues/14253#issuecomment-1212577437, otherwise maybe based on start.vaadin.com

Artur- avatar Sep 15 '22 06:09 Artur-

Possibly related to https://stackoverflow.com/questions/73846068/vaadin-23-typeerror-error-loading-dynamically-imported-module

TatuLund avatar Sep 26 '22 06:09 TatuLund

@bsutton Closed, because of no answer since Sep 15. Please provide a reproducible example project and re-open this ticket if it still an issue for you.

mshabarov avatar Nov 29 '22 12:11 mshabarov