phil294 / GitLG

A free, interactive Git UI for VSCode
MIT License
155 stars 15 forks source link

Better handling of start-up errors #93

Open dimateos opened 7 months ago

dimateos commented 7 months ago

There are a bunch of errors when you open the view before vscode source control has loaded any git repo. Or when you open (restoring last selected repo?) and the selected repo is not loaded yet. This loading process can be fast with a few repos as in the following pic, but for large workspaces it can be quite slow.

image

Also happens a lot when the extension editor is open when you close vscode and then later restore the workspace along with all the editors (this is when it always occurs to me, and quite often)

vscode error bubbles ![image](https://github.com/phil294/git-log--graph/assets/26868611/0b21da7e-bca9-4776-a08b-83f2f26a0399)
console log * Stiched together as idk of a better method to share it, feel free to suggest other way or request more info. * Some lines might not be related to the extension, I capture where related messages started till the end: ![2024-04-17_(092202)](https://github.com/phil294/git-log--graph/assets/26868611/0eb86cc9-b5a0-4854-8431-6010485229c9)

Dunno if related to https://github.com/phil294/git-log--graph/issues/82, but keep happening to me as of the last version. ATM I use the hotkey to open the view, but would be nice to have button to open+switch to different repos.

Feature request

Probably these error messages are useful for unexpected errors during usage, but there could be a way to silent them when clearly the issue is that the source control repos are not loaded yet. Or maybe directly avoid doing the queries when so.

Basically Ive never seen them pop up other than in the explained situations.

Best regards!

phil294 commented 7 months ago

I've never had these errors come up, but I guess it should be rather easy to reproduce, particularly given how much information you provided. And personally I'm a fan of big aggressive ugly error message popups as they are more likely to be reported than silent console.logs - as long as they're fixed rapidly