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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stuck at "Sync: Reading Settings and Extensions", consuming 100% CPU #1071

Open
borekb opened this issue Oct 16, 2019 · 10 comments
Open

Stuck at "Sync: Reading Settings and Extensions", consuming 100% CPU #1071

borekb opened this issue Oct 16, 2019 · 10 comments
Milestone

Comments

@borekb
Copy link

borekb commented Oct 16, 2019

馃悰 Describe the bug

When I run Sync: Update/Upload Settings, the process is stuck at "Sync: Reading Settings and Extensions" and the Code Helper process is consuming 100% CPU until I restart VSCode.

Screenshot 2019-10-16 at 12 43 26

I think it started happening after I update to VSCode 1.39 but I might be wrong.

馃尨 Visual Studio Code Version : 1.39.2
馃尨 Code Settings Sync Version : 3.4.3
馃尨 Standard or Insiders : standard
馃尨 Portable or Installed : installed
馃尨 OSS or Official Build : official
馃尨 Operating System : macOS Catalina
馃尨 Occurs On: Upload
馃尨 Proxy Enabled: No
馃尨 Gist Id: n/a

馃摵 Console Error Log

Nothing in the dev tools console (searched for "sync").

@shanalikhan
Copy link
Owner

Nothing in the dev tools console (searched for "sync").

Have you tried

  1. removing the extension,
  2. deleting the folder of extension (if code in any case doesnt remove it)
  3. installing and resetting the extension settings
  4. Restarting the code

@shanalikhan
Copy link
Owner

Kindly let me know about the status, or i'm closing this issue assuming its fixed.

@borekb
Copy link
Author

borekb commented Nov 6, 2019

@shanalikhan Sorry, just got to it. Unfortunately, the problem persists. I followed your steps but when passing OAuth on GitHub, I end up on this strange screen:

Screenshot 2019-11-06 at 13 09 34

There should probably be a list of Gists but I see nothing. BTW this is my settings Gist:

https://gist.github.com/borekb/da094142cab10f5f40ad024da92bf692

Back on the "Welcome to Settings Sync" screen, there's a link called "Download Public Gist" which I followed. However, it ended up in an error:

Screenshot 2019-11-06 at 13 15 58

In dev tools console, there were two errors:

console.ts:137 [Extension Host] Sync: Result content is not a valid JSON. Unexpected token ] in JSON at position 2566 
[
  {
    "key": "ctrl+l",
    "command": "workbench.files.action.showActiveFileInExplorer"
  },
  {
    "key": "cmd+shift+f",
    "command": "filesExplorer.findInFolder",
    "when": "explorerViewletVisible && filesExplorerFocus"
  },

  {
    "key": "alt+cmd+right",
    "command": "editor.action.smartSelect.expand",
    "when": "editorTextFocus"
  },
  {
    "key": "alt+cmd+left",
    "command": "editor.action.smartSelect.shrink",
    "when": "editorTextFocus"
  },
  {
    "key": "alt+cmd+right",
    "command": "-workbench.action.nextEditor"
  },
  {
    "key": "alt+cmd+left",
    "command": "-workbench.action.previousEditor"
  },
  {
    "key": "alt+cmd+j",
    "command": "workbench.action.togglePanelPosition"
  },
  {
    "key": "shift+cmd+backspace",
    "command": "workbench.action.navigateToLastEditLocation"
  },
  {
    "key": "cmd+k cmd+q",
    "command": "-workbench.action.navigateToLastEditLocation"
  },
  {
    "command": "editor.action.insertSnippet",
    "args": {
      "snippet": "[$TM_SELECTED_TEXT]($0)"
    },
    "key": "cmd+l",
    "when": "editorTextFocus && editorLangId == 'markdown'"
  },
  {
    "key": "cmd+b",
    "command": "-markdown.extension.editing.toggleBold",
    "when": "editorTextFocus && !editorReadonly && editorLangId == 'markdown'"
  },
  {
    "key": "alt+cmd+b",
    "command": "markdown.extension.editing.toggleBold",
    "when": "editorTextFocus && !editorReadonly && editorLangId == 'markdown'"
  },
  {
    "key": "cmd+k b",
    "command": "workbench.action.toggleSidebarVisibility"
  },
  {
    "key": "shift+cmd+i",
    "command": "-emojisense.quickEmojitext",
    "when": "editorTextFocus"
  },
  {
    "key": "shift+cmd+i",
    "command": "-emojisense.quickEmojitextTerminal",
    "when": "terminalFocus"
  },
  {
    "key": "cmd+i",
    "command": "-emojisense.quickEmoji",
    "when": "editorTextFocus"
  },
  {
    "key": "cmd+i",
    "command": "-emojisense.quickEmojiTerminal",
    "when": "terminalFocus"
  },
  {
    "key": "cmd+=",
    "command": "zoombar-vscode.zoomIn"
  },
  {
    "key": "cmd+-",
    "command": "zoombar-vscode.zoomOut"
  },
  {
    "key": "cmd+0",
    "command": "zoombar-vscode.resetZoom"
  },
  {
    "key": "cmd+-",
    "command": "-workbench.action.zoomOut"
  },
  {
    "key": "shift+cmd+-",
    "command": "-workbench.action.zoomOut"
  },
  {
    "key": "cmd+=",
    "command": "-workbench.action.zoomIn"
  },
  {
    "key": "shift+cmd+=",
    "command": "-workbench.action.zoomIn"
  },
  {
    "key": "cmd+0",
    "command": "-workbench.action.focusSideBar"
  },
]

and

/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:243 [Extension Host] TypeError: Cannot read property 'trim' of undefined at Function.e.toggleComments (/Users/borekb/.vscode/extensions/shan.code-settings-sync-3.4.3/out/extension.js:726:6351) at Function.e.checkNextLines (/Users/borekb/.vscode/extensions/shan.code-settings-sync-3.4.3/out/extension.js:726:6813) at Function.e.getIgnoredBlocks (/Users/borekb/.vscode/extensions/shan.code-settings-sync-3.4.3/out/extension.js:726:6156) at Function.e.processBeforeWrite (/Users/borekb/.vscode/extensions/shan.code-settings-sync-3.4.3/out/extension.js:726:4806) at /Users/borekb/.vscode/extensions/shan.code-settings-sync-3.4.3/out/extension.js:290:23304 at /Users/borekb/.vscode/extensions/shan.code-settings-sync-3.4.3/out/extension.js:290:11611 at Object.next (/Users/borekb/.vscode/extensions/shan.code-settings-sync-3.4.3/out/extension.js:290:11716) at a (/Users/borekb/.vscode/extensions/shan.code-settings-sync-3.4.3/out/extension.js:290:10462)

That "JSON" above is probably some inbetween step as I don't have comment-less keybindings.json neitner on my computer, neither in Gist (see here).

I suspect the trailing comma in keybindings.json may have something to do with it but this was working fine before.

@borekb
Copy link
Author

borekb commented Nov 6, 2019

Sorry, I sent the comment before fully finishing it, it's now updated with all the info.

@borekb
Copy link
Author

borekb commented Nov 6, 2019

(I only see the error on download; upload doesn't produce any errors, just gets stuck and uses 100% CPU until I restart VSCode.)

@arnauldvm
Copy link

arnauldvm commented Nov 8, 2019

I have a similar issue and found this in the console:

TypeError: Cannot read property 'trim' of undefined
    at Function.e.toggleComments (c:\Users\avm\.vscode\extensions\shan.code-settings-sync-3.4.3\out\extension.js:726:6351)
    at Function.e.checkNextLines (c:\Users\avm\.vscode\extensions\shan.code-settings-sync-3.4.3\out\extension.js:726:6813)
    at Function.e.getIgnoredBlocks (c:\Users\avm\.vscode\extensions\shan.code-settings-sync-3.4.3\out\extension.js:726:6156)
    at Function.e.processBeforeWrite (c:\Users\avm\.vscode\extensions\shan.code-settings-sync-3.4.3\out\extension.js:726:4806)
    at c:\Users\avm\.vscode\extensions\shan.code-settings-sync-3.4.3\out\extension.js:290:23304
    at c:\Users\avm\.vscode\extensions\shan.code-settings-sync-3.4.3\out\extension.js:290:11611
    at Object.next (c:\Users\avm\.vscode\extensions\shan.code-settings-sync-3.4.3\out\extension.js:290:11716)
    at a (c:\Users\avm\.vscode\extensions\shan.code-settings-sync-3.4.3\out\extension.js:290:10462)
t.log @ /C:/Program Files (x86)/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:250

@borekb
Copy link
Author

borekb commented Nov 24, 2019

I've tried to manually remove trailing commas from my JSON in the Gist but it didn't help:

Screenshot 2019-11-24 at 18 34 06

I haven't yet found a workaround that would allow me continue using this extension.

@shanalikhan
Copy link
Owner

@borekb @arnauldvm

I will hopefully share a custom build fixing this issue in this week with you guys before releasing it to public.

@filmico
Copy link

filmico commented Dec 15, 2019

Guys, I麓m experiencing this same issue with win 7/win10. IT was working great and suddenly I cannot sync anymore in new installations.
Just for testing, I reset the extension in a computer that all was working and syncing and clean the gist on git hub to start over again and the same problem start to happen in this station were all was working fine. Any idea on how to fix it? what are the files we can edit and check for extra comma in the json config file?

image

@shanalikhan shanalikhan added this to the v3.4.4 milestone Dec 17, 2019
@borekb
Copy link
Author

borekb commented Jan 20, 2020

@shanalikhan do you have a build that we could test already? Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants