VS code problems loading package.json schema

Whenever I open a pacakage.json file I get this error. I am not running any proxy and I haven tried turning it off like the few answers on internet suggested but that didn't fix it. I have tried disabling and uninstalling what 5 extensions I use. I have also tried putting this
"json.schemas": [
{
"fileMatch": ["/package.json"],
"url": "https://json.schemastore.org/package",
"schema": true
}
]
"json.schemas": [
{
"fileMatch": ["/package.json"],
"url": "https://json.schemastore.org/package",
"schema": true
}
]
in my settings.json and that makes the warning go away but I don't get any tooltip when hovering over properties in the package json so I don't think it's working. I'll appreciate any help
No description
17 Replies
Ganesh
GaneshOP2mo ago
btw this is from settings.json but vscode schemas are probably local so maybe it itsn't fetching anything
No description
ἔρως
ἔρως2mo ago
try adding .json to the url
Ganesh
GaneshOP2mo ago
No description
Ganesh
GaneshOP2mo ago
hmm the error returned
ἔρως
ἔρως2mo ago
same file or a different one?
Ganesh
GaneshOP2mo ago
same
ἔρως
ἔρως2mo ago
restart vscode if it doesnt work, go to "settings", search for json schema download and enable it
Ganesh
GaneshOP2mo ago
no dice A couple days ago I was having trouble when fetching in node due to it's implementaion of happy path algorithm. Do you think that can be the problem here? I forgot if electron bundled node with it or just browser environment ok it appears to bundle both. Tho I'm not sure how to test this theory in vs code. for node i could just pass --network-family-autoselection-attempt-timeout=500 not sure how to achieve that in vs code
ἔρως
ἔρως2mo ago
no, thats a vscode thing, not node thing check if there is an update available
Ganesh
GaneshOP2mo ago
already did on the latest version
ἔρως
ἔρως2mo ago
im out of ideas then disable the schema downloading then, so it doesnt bug you
Ganesh
GaneshOP2mo ago
I'll let it stay on it was mostly cause i was curious about the error. Maybe i'll create a js script that downloads the package schema and adds it locally in the project you can do that right?
Ganesh
GaneshOP2mo ago
actually wtf
No description
Ganesh
GaneshOP2mo ago
I removed the json.schema snippet from the settings json and it suddenly started working whatever we'll see if it breaks with next npm init thanks for helping btw ἔρως
ἔρως
ἔρως2mo ago
you're welcome didnt think about removing that, to be honest
Ganesh
GaneshOP2mo ago
It shouldn't work technically since I didn't have it when i first got error it's probably some spagetti code
ἔρως
ἔρως2mo ago
probably some tool being overly helpful to you

Did you find this page helpful?