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

Cannot resolve non-ascii url-encoded JSON schema url #178

Open
hsl0 opened this issue Mar 7, 2023 · 0 comments
Open

Cannot resolve non-ascii url-encoded JSON schema url #178

hsl0 opened this issue Mar 7, 2023 · 0 comments

Comments

@hsl0
Copy link

hsl0 commented Mar 7, 2023

When I apply JSON schema with URL including non-ascii character, Unable to load schema from '...': Request path contains unescaped characters. warning occurs despite the URL being URL-encoded.

Steps to Reproduce

  1. Open a new VSCode window.
  2. Open a new file.
  3. Write JSON code as below:
{
  "$schema": "https://libertygame.miraheze.org/w/index.php?title=%EB%A6%AC%EB%B2%84%ED%8B%B0%EA%B2%8C%EC%9E%84:%EA%B2%8C%EC%9E%84_%EB%A9%94%ED%83%80%EB%8D%B0%EC%9D%B4%ED%84%B0/%EC%8A%A4%ED%82%A4%EB%A7%88.json&action=raw&ctype=application/json"
}

What happened

Unable to load schema from 'https://libertygame.miraheze.org/w/index.php?title=리버티게임:게임_메타데이터/스키마.json&action=raw&ctype=application/json': Request path contains unescaped characters. warning occurs. The URL in the warning message is URL-decoded. I think it decodes the URL and tries to resolve the schema with decoded URL so that error occurs.

Warning message data

[{
	"resource": "Untitled-1",
	"owner": "_generated_diagnostic_collection_name_#1",
	"code": "768",
	"severity": 4,
	"message": "Unable to load schema from 'https://libertygame.miraheze.org/w/index.php?title=리버티게임:게임_메타데이터/스키마.json&action=raw&ctype=application/json': Request path contains unescaped characters.",
	"startLineNumber": 2,
	"startColumn": 16,
	"endLineNumber": 2,
	"endColumn": 246
}]

What should it be

JSON schema should be imported successfully without any errors. I believe the schema in that URL is valid.

Environment

  • VS Code Version: 1.76.0
  • OS Version: Windows 11 Version 22H2 Build 22621.1344 (Windows_NT x64 10.0.22621)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant