Closed craxal closed 1 month ago
@houlgap Just to get some details, how long is this brief moment? I assume this happens for every JSON file you try? Do you have app logs you can share?
The formatted json is displayed for a fraction of a second, and it happens for every json file I have attempted so far. Here is a video of the repro https://github.com/user-attachments/assets/63e5ffb3-e98a-47e9-8103-f00e17b07a79
Is there a secure way to upload the logs? I have reviewed them but they don't seem to capture anything relevant to this issue.
@houlgap Sensitive information is redacted automatically from the logs, so you can share them safely here. If you're still concerned, you can share them privately by sending them to sehelp at microsoft dot com.
I am also able to reproduce this. I've also noticed the "Format JSON" command does not change to "Restore JSON", so something is causing it to revert back immediately.
See trace logs attached StorageExplorerLogs.zip
Problem seems to have started after commit 2711461 when tab lifecycle was introduced. No idea why this would affect the Monaco editor....
I believe this has the same root cause as #8235.
We've discovered the problem. Code that sets up the <webview>
element is run in the update
method of a custom Knockout binding. Formatting JSON modifies the display name of the tab. Since the display name of the tab is an observable, the update
method runs again, which means the setup code is run again, ultimately creating a new <webview>
renderer process. This is why the JSON appears to reset almost immediately and why a crash happens when trying to close the tab.
This feels serious enough for a hotfix, so you should see a fix in 1.36.1 soon.
Preflight Checklist
Storage Explorer Version
1.36.0
Regression From
1.35
Architecture
x64
Storage Explorer Build Number
20241012.1
Platform
All
OS Version
Windows 11
Bug Description
Formatting json files no longer works, it changes but then reverts back to unformatted json.
Steps to Reproduce
Actual Experience
When selecting the "Format JSON" option, the formatted json is displayed for a brief moment, before reverting back to unformatted json.
Expected Experience
I would expect the formatted json to be displayed.
Additional Context
No response