Search terms
rename file, unsaved changes, progress loss, UI state, editor refresh
Expected Behavior
Renaming a .waldiez file should not affect the editing session.
If the file is currently open in Waldiez Studio, the editor should continue saving changes normally after the rename.
Actual Behavior
In Waldiez Studio, renaming a .waldiez file while it is open in the editor causes the editor to enter an inconsistent state:
- The rename succeeds in the file explorer.
- The editor tab remains open and still shows the previous unsaved edits.
- The UI makes it appear as if editing continues normally.
However,:
- Ctrl + S does not save changes
- The editor is effectively detached from the renamed file
- The user receives no indication that saving no longer works
- If the user closes the tab, all edits are lost permanently.
This can lead to loss of work/progress, since the editor still appears active but is no longer properly linked to the renamed file.
Additionally, VSCode renaming the file causes the open tab to refresh to the last saved version. Which means if the user didn't do any recent save, the forced refresh after renaming the file makes progress lost in an instant.
I think user prompting and warning is necessary here before the editors taking any action.
Steps to reproduce the bug
Open waldiez file, make some edits. Then rename the file.
Environment
- Versions:
- Python version: 3.11
- waldiez version: 0.7.1
- OS: Windows 11
Search terms
rename file, unsaved changes, progress loss, UI state, editor refresh
Expected Behavior
Renaming a .waldiez file should not affect the editing session.
If the file is currently open in Waldiez Studio, the editor should continue saving changes normally after the rename.
Actual Behavior
In Waldiez Studio, renaming a .waldiez file while it is open in the editor causes the editor to enter an inconsistent state:
However,:
This can lead to loss of work/progress, since the editor still appears active but is no longer properly linked to the renamed file.
Additionally, VSCode renaming the file causes the open tab to refresh to the last saved version. Which means if the user didn't do any recent save, the forced refresh after renaming the file makes progress lost in an instant.
I think user prompting and warning is necessary here before the editors taking any action.
Steps to reproduce the bug
Open waldiez file, make some edits. Then rename the file.
Environment