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

Error to upload image, error to refresh, multiple errors on Extension Host output #358

Open
fleps opened this issue Jun 13, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@fleps
Copy link

fleps commented Jun 13, 2024

Describe the bug
I've been using it for months now, and the basic features still works normally - I can create Gists, edit, rename, etc.

Today I tried to add an image to a Markdown Gist file, following the extension guide, and all went hell.

First, I tried to paste an image copied directly from an editor, I got this error on a popup:

Error applying edit 'Insert Markdown Image': Unable to write file 'gist://984954219ddfd9dd9d048e5d9324a616/graph.png' (Error: fatal: couldn't find remote ref master )

If then tried to use the "Upload File" context menu on the Gists list, it will insert a broken image on the Markdown, it will show the "Uploading file", and then nothing happens (no error appears, no image is uploaded).

I then tried to hit the refresh button on the extension, which doesn't work and shows the below error:

Error running command gistpad.refreshGists: Cannot read properties of undefined (reading 'appendLine'). This is likely caused by the extension that contributes gistpad.refreshGists.

I then tried each step multiple different ways, with different images, and decided to check the Extension Host output, which I then noted that even when the error popup doesn't appear (using the "Upload File" option), the same first error as above happens on the Extension Host.

And then after this error, the Extension Host will start going hell with multiple errors per second with the below message:

2024-06-13 10:40:17.274 [error] Error: [ExtensionListenerError] Extension 'vsls-contrib.gistfs' FAILED to handle event: TypeError: Cannot read properties of undefined (reading 'document') at n.value (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:163:20749) at l.y (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:82:664) at l.z (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:82:734) at l.fire (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:82:950) at S.$acceptModelChanged (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:153:81758) at E.S (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:150:5970) at E.Q (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:150:5736) at E.M (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:150:4762) at E.L (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:150:3589) at n.value (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:150:2282) at l.y (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:82:664) at l.fire (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:82:881) at s.fire (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:107:14502) at n.value (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:176:8481) at l.y (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:82:664) at l.fire (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:82:881) at s.fire (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:107:14502) at MessagePortMain.<anonymous> (c:\Users\flep\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:176:6631) at MessagePortMain.emit (node:events:514:28) at MessagePortMain.emit (node:domain:488:12) at Object.MessagePortMain._internalPort.emit (node:electron/js2c/utility_init:2:2285)

It will stay outputting the above until I disable the extension and enable it again.

When I enable it again, it also shows some other errors (but at least they stop):

2024-06-13 10:42:05.996 [error] TypeError: Cannot read properties of undefined (reading 'appendLine') at Object.get followedUsers [as followedUsers] (c:\Users\flep\.vscode\extensions\vsls-contrib.gistfs-0.6.0\dist\extension.js:2:780311) at t.refreshGists (c:\Users\flep\.vscode\extensions\vsls-contrib.gistfs-0.6.0\dist\extension.js:2:776491) at processTicksAndRejections (node:internal/process/task_queues:95:5) at y (c:\Users\flep\.vscode\extensions\vsls-contrib.gistfs-0.6.0\dist\extension.js:2:778251) at v (c:\Users\flep\.vscode\extensions\vsls-contrib.gistfs-0.6.0\dist\extension.js:2:778699) at t.initializeAuth (c:\Users\flep\.vscode\extensions\vsls-contrib.gistfs-0.6.0\dist\extension.js:2:779191)

2024-06-13 10:42:32.356 [error] [vsls-contrib.gistfs] provider FAILED 2024-06-13 10:42:32.356 [error] TypeError: undefined is not iterable (cannot read property Symbol(Symbol.iterator))

  • VS Code Version
    Version: 1.90.0 (user setup)
    Commit: 89de5a8d4d6205e5b11647eb6a74844ca23d2573
    Date: 2024-06-04T19:33:54.889Z
    Electron: 29.4.0
    ElectronBuildId: 9593362
    Chromium: 122.0.6261.156
    Node.js: 20.9.0
    V8: 12.2.281.27-electron.0
    OS: Windows_NT x64 10.0.22631 -

  • GistPad Version v0.6.0


As I said, I can still use it to keep editing my files, but would like to understand what is going on and how to fix this, so I can use the images with it.

I do have 2 Markdown extensions related to Markdown edits/previews, but even with them disabled the same happens, so no idea what's going on.

@fleps fleps added the bug Something isn't working label Jun 13, 2024
@maziac
Copy link

maziac commented Nov 6, 2024

I also see the error about "TypeError: Cannot read properties of undefined (reading 'appendLine')" as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants