Skip to content
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

git graph often crash in vscodeinsider #604

Closed
heartacker opened this issue Dec 20, 2021 · 7 comments
Closed

git graph often crash in vscodeinsider #604

heartacker opened this issue Dec 20, 2021 · 7 comments
Assignees
Labels
vscode-bug Something isn't working in Visual Studio Code, that affects Git Graph and all other extensions.

Comments

@heartacker
Copy link

Describe the Bug
A clear and concise description of what the bug is.

Steps to Reproduce
Steps to reproduce the behaviour:
i don‘t konw, but it will crash when i upgrate vscode to insider

Expected Behaviour
A clear and concise description of what you expected to happen.

Environment
版本: 1.64.0-insider (system setup)
提交: 807bf598bea406dcb272a9fced54697986e87768
日期: 2021-12-20T07:18:13.749Z
Electron: 13.5.2
Chromium: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Windows_NT x64 10.0.22523

Screenshots (optional)
image

@heartacker heartacker added the bug Something isn't working label Dec 20, 2021
@heartacker
Copy link
Author

microsoft/vscode#139526

@mhutchie
Copy link
Owner

Hi @heartacker,

The behaviour you're observing occurs when Visual Studio Code (or Insiders) doesn't provided the necessary JavaScript & CSS resources that the extension requests when the Visual Studio Code Webview is loading. What you see in your screenshot is the base HTML of the Webview - as soon as the required Javascript and/or CSS are provided by Visual Studio Code, the interface would immediately appear differently (similar to how a webpage loads).

When the Git Graph View (Webview) is visible, if you run the "Developer: Open Webview Developer Tools" command from the Visual Studio Code Command Palette, and switch to the Console Tab, you'll be able to see the errors that Visual Studio Code is having. These error logs will tell you to path of the two required files out.min.js and out.min.css.


There have been two sources of this behaviour reported by extension users over the last two years, both caused by Visual Studio Code (or Insiders).

Problem 1: When Visual Studio Code is updated, or the extension is installed / updated, in some rare cases the JavaScript & CSS resources of the extension are no longer present on the file system. If this is the problem, then the Git Graph View (Webview) will never load correctly. You can check your file system for the two files I mentioned above. If they don't exist, downgrading and then reinstalling the latest version of the extension will fix the issue.

Problem 2: For the last two years, Microsoft have released numerous Visual Studio Code Insiders (and in rare cases Visual Studio Code) bugs that intermittently (or always for some users) prevent these JavaScript & CSS resources from loading. Every time this has occurred, Microsoft have had to fix their Webview implementation as it affects all extensions that use Webviews (not just Git Graph). If so, please open a Visual Studio Code issue on GitHub providing this additional information (titled "Visual Studio Code Webview Resources not loading in the latest Insiders release").


When I tried using the extension with the same version of Visual Studio Code Insiders as you, the extension was working fine for me. This confirms that there isn't some fundamental incompatibility between the extension and Visual Studio Code Insiders 1.64.0, and is almost certainly a similar root cause to the issues last year. You did mention what version of Git Graph you're using, but please make sure you've updated to the latest version.

Version: 1.64.0-insider (user setup)
Commit: 807bf598bea406dcb272a9fced54697986e87768
Date: 2021-12-20T07:18:13.749Z
Electron: 13.5.2
Chromium: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Windows_NT x64 10.0.19043

FYI: #436 is one of numerous issues raised by users observing a similar behaviour.

@mhutchie mhutchie added vscode-bug Something isn't working in Visual Studio Code, that affects Git Graph and all other extensions. and removed bug Something isn't working labels Dec 20, 2021
@heartacker
Copy link
Author

thanks for your respond,
and I believe there is something related to vscode-insiders.

I have two PC, and both of them have same problem within vscode-insider and both of them work well within vscode-stable

BTW, we could see the full view of git-graph and after some view-switching, git-graph crash randomly.
there is a screen-record gif:
git-graph
hope that will help to debug

@mhutchie
Copy link
Owner

Thanks for the additional information.

When the user first opens the Git Graph View (Webview), or it becomes visible again, the HTML for the Webview is set. Based on the screen recording, it clearly indicates that the JavaScript & CSS resources that are requested by Git Graph do exist on the file system. There must be an issue introduced into Visual Studio Code Insiders 1.46 when Webviews are restored, where Visual Studio Code doesn't provide the requested resources.

I can't manage to replicate the same behaviour using the same Visual Studio Code Insider build, so this issue only affects some users.

@donotlb
Copy link

donotlb commented Dec 27, 2021

maybe you could replicate the same behaviour by opening a folder containing multiple git repo

@bradlitterell
Copy link

Experiencing same - with VSCode insiders 1.64.0-insiders @ 99305570d8. Was not reproing before I went on holiday break so definitely seems to be an issue with an insider update since Git-Graph has not been updated. Seems to happen when the git-graph window has been open for a while and I switch back to the git-graph tab. I have reinstalled git-graph and the behavior remains the same: git-graph opens fine, but fails sometime later.

@heartacker
Copy link
Author

least fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
vscode-bug Something isn't working in Visual Studio Code, that affects Git Graph and all other extensions.
Projects
None yet
Development

No branches or pull requests

4 participants