kahole / edamagit

Magit for VSCode

Home Page:https://marketplace.visualstudio.com/items?itemName=kahole.magit

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Tips for debugging Cannot read properties of undefined (reading 'repository')

stuarth opened this issue · comments

Recently have been seeing the error

Cannot read properties of undefined (reading 'repository')

when invoking the plugin. Any tips on debugging?

cmd-shift-p -> Search Show Logs -> Extension Host

Thanks @kahole ! Looks like it's related to the vscode insiders build as everything is good in the normal channel. If you're curious

[2022-07-30 15:07:40.496] [exthost] [error] TypeError: Cannot read properties of undefined (reading 'repository')
	at Object.t.gitRun (/Users/stuarth/.vscode-insiders/extensions/kahole.magit-0.6.29/dist/extension.js:1:111480)
	at Object.h [as internalMagitStatus] (/Users/stuarth/.vscode-insiders/extensions/kahole.magit-0.6.29/dist/extension.js:1:75421)
	at async Function.getCurrentMagitRepo (/Users/stuarth/.vscode-insiders/extensions/kahole.magit-0.6.29/dist/extension.js:1:115145)
	at async t.magitStatus (/Users/stuarth/.vscode-insiders/extensions/kahole.magit-0.6.29/dist/extension.js:1:82414)
	at async a._executeContributedCommand (/Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:85:63914) magit.status {"value":"kahole.magit","_lower":"kahole.magit"}

❤️ the plugin btw! Thank you for your work on it!

vscode insiders build

Interesting. This means there might be a breaking API change coming up