Visual Studio Code Version : [ 1.11.2]
Code Settings Sync Version : [ 2.6.2]
Operating System : [ Windows 10 ]
Occurs On: [Upload]
Proxy Enabled: [ No ]
GIst Id: [ 1be69ce1a0ddc18a632b7f4108df3740]
I followed the instructions and created a GitHub Personal Access Token.
When I attempted to upload my settings, the following is displayed in VS Code
Cannot read property 'ignoreUploadFiles' of nullSync : Unable to read syncLocalSettings.json. Make sure its Valid JSON.These errors were also shown in VS Code debugger tool.
I went to the following directory C:Users???AppDataRoamingCodeUser and viewed the syncLocalSettings.json and noticed the file was empty. Based on blog post Code Settings Sync Customizable Sync, I manually added the following configuration to the syncLocalSettings.json
{
"ignoreUploadFiles": [
"projects.json",
"projects_cache_git.json"
],
"ignoreUploadFolders": [
"workspaceStorage"
],
"replaceCodeSettings":
{
"http.proxy" :"",
"files.autoSave" :"off"
}
}
After making these changes, the upload process worked and a gist was created on my GitHub account.
Can you delete the file once again, and check the empty file is being created with the json data ?
Also there will be any exception logged in the console. please paste that log when you get it again.
Hi, I am having the same issue so can help you, Now I am unaware where this file has been created, can you give me the directory it will put this file on ubuntu 16.04 as that what I am using.
And I can say what the issue with my file.
The file is in the same folder User folder where your code settings and other settings are placed
{
"ignoreUploadFiles": [
"projects.json",
"projects_cache_git.json"
],
"ignoreUploadFolders": [
"workspaceStorage"
],
"ignoreUploadSettings": {},
"replaceCodeSettings": {},
"gistDescription": "Visual Studio Code Settings Sync Gist",
"version": 270
}
That's what my file contains I can't see any issues with the file. shall I delete it and rebuild it?
Dont remove this file.
Extension needs this file to upload / download
Okay but how come I get the error? saying invalid JSON sometimes?
Make sure you donet have trailing commas at the end, when you get, remove the file or backup it somewhere and then remove it.
Restart code, extension will create the file itself.
Removing the file solved the issue on Windows 10. I tried to open it before, but vscode said it's binary format or can't open it. Next start the file was recreated, I entered again the gist token and everything works just like before.
I'm getting the same error. There's no syncLocalSettings.json in ~/.config/Code/. I've tried restarting VSCode too.
I'm getting the same error. I've tried everything I can think of including the suggestions in this thread. This only happens in Windows 10. I also have it installed in Linux and it works fine. Also, is there a way to disable the opening of browsers all the time. I'd rather it just print a message in the console with the URL. I can open a separate ticket for that if it helps.
Having the same problem here.. windows 7.
Same issue, Windows 7, just installed VSCode v 6.1.7601. Maybe it's because of VSCode updates?
I recently encountered the same problem with a message saying: "Sync : Unable to read syncLocalSettings.json. Make sure its Valid JSON."But I solved this problem with just one click. Check "Download Public Gist" in Sync Settings and it will be successfully synchronized.(Or modify {"downloadPublicGist": true} in the %APPDATA%\Code\User\syncLocalSettings.json file)
我最近遇到了相同的问题,提示信息显示:"Sync : Unable to read syncLocalSettings.json. Make sure its Valid JSON."
但是我只用了一次点击便解决了这个问题,在Sync Settings里面勾选"下载公开Gist",立刻就能成功同步了。(或者在%APPDATA%\Code\User\syncLocalSettings.json文件中修改{"downloadPublicGist": true})
I recently encountered the same problem with a message saying: "Sync : Unable to read syncLocalSettings.json. Make sure its Valid JSON."But I solved this problem with just one click. Check "Download Public Gist" in Sync Settings and it will be successfully synchronized.(Or modify {"downloadPublicGist": true} in the
%APPDATA%\Code\User\syncLocalSettings.jsonfile)我最近遇到了相同的问题,提示信息显示:"Sync : Unable to read syncLocalSettings.json. Make sure its Valid JSON."
但是我只用了一次点击便解决了这个问题,在Sync Settings里面勾选"下载公开Gist",立刻就能成功同步了。(或者在%APPDATA%\Code\User\syncLocalSettings.json文件中修改{"downloadPublicGist": true})
still not working
delete the syncLocalSettings.json file from - %APPDATA%CodeUser - repository (folder) and restart vscode.
after restart vs code automatically generate the file and the issue is solved.
There is an easier way. Ctrl + Shift + p and type Sync: Reset Extension Settings. Then scroll down on the Extension and Sign in with Github and it should redownload your Gist.
Most helpful comment
I recently encountered the same problem with a message saying: "Sync : Unable to read syncLocalSettings.json. Make sure its Valid JSON."But I solved this problem with just one click. Check "Download Public Gist" in Sync Settings and it will be successfully synchronized.(Or modify {"downloadPublicGist": true} in the
%APPDATA%\Code\User\syncLocalSettings.jsonfile)我最近遇到了相同的问题,提示信息显示:"Sync : Unable to read syncLocalSettings.json. Make sure its Valid JSON."
但是我只用了一次点击便解决了这个问题,在Sync Settings里面勾选"下载公开Gist",立刻就能成功同步了。(或者在
%APPDATA%\Code\User\syncLocalSettings.json文件中修改{"downloadPublicGist": true})