[🐛 BUG] De-synchronized front-ends and back-end #2344
Labels
🖰 GUI
Related to GUI
💥Malfunction
Addresses an identified problem.
🟧 Priority: High
Must be addressed as soon
What went wrong? 🤔
Front-ends get de-synchronized when re-running an application.
This is more important than it looks like, as it happens frequently and gives users the wrong impression that their application has a bug.
For example, it happens frequently during an application's development phase, especially with the default behavior of Gui().run(), which opens a new tab without closing the previous tabs.
It also happens when re-deploying a live application, causing the wrong error messages at a very bad time.
Reproduce the situation
The problem arises when:
Expected Behavior
De-synchronized front-ends should be aware that the back-end version they are connected to is incorrect. The front-end application should automatically display a message to let the user know he/she should refresh the browser.
Solution Proposed
What about generating a unique identifier each time we run the server? It could represent a
run_identifier
. Each of the clients (the tabs) could know this uniquerun_identifier
.The clients could pass the
run_identifier
to the back end every time it communicates with it. On the server side, the client request is properly rejected if therun_identifier
received from the client does not match its own internalrun_identifier
. The front end should be able to display a message asking the user to refresh the tab.Version of Taipy
Linked issues
Acceptance Criteria
Code of Conduct
The text was updated successfully, but these errors were encountered: