-
Notifications
You must be signed in to change notification settings - Fork 169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NullPointerException: Cannot invoke "com.vaadin.flow.server.VaadinSession.getErrorHandler()" logged when session is closed #12100
Comments
Underlying
|
I'm sorry but I'm not able to reproduce the issue. Could you please provide which steps should be taken to see that exception? I have tried logging out, invalidating the session, ..., but no NPE has was shown in the logs. Thanks and best regards, Miguel |
At least I've been consistently been able to get the exception by running the project inside IntelliJ Idea, with mvn spring-boot:run, and leaving it running for enough time (30 minutes, or maybe longer?) Edit: also should happen with starting the app by debugging the Application.java, as I was able to add a breakpoint to Vaadin Service |
ok. Great. Thanks, Olli. I will try to reproduce it |
Hi Olli, definitely I'm not able to reproduce it. I have left the application running for more than 1 hour to let the session end several times and I have never experienced the issue you describe. Surely one collegue will contact you during next days, in order to dig deeper into this. Thanks! |
Unfortunately, I've also had problems being able to reproduce the issue. It's weird because when I was able to reproduce the issue, it was consistent (even if slow to appear) - and when I was running the application in Debug, I was able to add the breakpoint and see the issue occur live. |
Saw this today in an start.vaadin.com "all" project using 14.7.8, running with command line Maven. Potentially related to using a collaboration engine view in the session |
What happens in my case is:
It seems that the problem is that the wrapping in UI.access assumes that the UI is always attached when an error occurs. That is not true. |
…12531) (#12591) Fixes #12100 Co-authored-by: Artur <[email protected]>
…12531) (#12591) Fixes #12100 Co-authored-by: Artur <[email protected]>
…12531) (#12591) (#12596) Fixes #12100 Co-authored-by: Artur <[email protected]> Co-authored-by: caalador <[email protected]> Co-authored-by: Artur <[email protected]>
This ticket/PR has been released with platform 22.0.2. |
This ticket/PR has been released with platform 14.8.1. |
Description of the bug / feature
If your session times out, you may get the following exception:
This is due to
getSession()
returningnull
.Minimal reproducible example
(fresh project from start.vaadin.com)
status-dashboard.zip
Expected behavior
Log should not show a NullPointerException but either nothing or a sensible message stating that the session has expired or somethingsimilar.
Actual behavior
NPE is shown in the log.
Versions:
The text was updated successfully, but these errors were encountered: