Skip to content

Commit 013a2a9

Browse files
Update URLs from json.schemastore.org to www.schemastore.org (SchemaStore#4787)
* Initial plan for issue * Update URLs from json.schemastore.org to www.schemastore.org Co-authored-by: madskristensen <[email protected]> * Fix validation error by updating remaining json.schemastore.org URLs Co-authored-by: madskristensen <[email protected]> * Revert $id/id fields in schema files and update $schema in test files per @hyperupcall feedback Following @hyperupcall's guidance: - Preserve all $id/id fields in schema files (keep json.schemastore.org) - Keep $schema in catalog.json as json.schemastore.org - Update $schema references in test/ and negative_test/ files to www.schemastore.org - Infrastructure URLs in catalog.json entries remain as www.schemastore.org * Fix validation by maintaining JSON Schema reference consistency - Revert $ref URLs in schema files to json.schemastore.org for consistency with $id fields - Fix schema-catalog.json enum validation to accept json.schemastore.org $schema references - Revert test files with enum validation back to json.schemastore.org - Update claude-code-settings catalog URL to www.schemastore.org - Maintain infrastructure migration while preserving JSON Schema semantics --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: madskristensen <[email protected]>
1 parent 7e1bd6d commit 013a2a9

File tree

168 files changed

+918
-918
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

168 files changed

+918
-918
lines changed

cli.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ const SchemaDir = './src/schemas/json'
6666
const TestPositiveDir = './src/test'
6767
const TestNegativeDir = './src/negative_test'
6868
const SchemaStoreUrls = /** @type {const} */ ([
69-
'https://json.schemastore.org/',
69+
'https://www.schemastore.org/',
7070
'https://raw.githubusercontent.com/SchemaStore/schemastore/master/src/schemas/json/',
7171
])
7272
const [SchemasToBeTested, FoldersPositiveTest, FoldersNegativeTest] = (
@@ -584,7 +584,7 @@ async function taskNewSchema() {
584584
await fs.writeFile(
585585
schemaFile,
586586
`{
587-
"$id": "https://json.schemastore.org/${schemaName}.json",
587+
"$id": "https://www.schemastore.org/${schemaName}.json",
588588
"$schema": "http://json-schema.org/draft-07/schema#",
589589
"additionalProperties": true,
590590
"properties": {
@@ -604,7 +604,7 @@ async function taskNewSchema() {
604604
"name": "",
605605
"description": "",
606606
"fileMatch": ["${schemaName}.yml", "${schemaName}.yaml"],
607-
"url": "https://json.schemastore.org/${schemaName}.json"
607+
"url": "https://www.schemastore.org/${schemaName}.json"
608608
}`)
609609
process.exit(0)
610610
}
@@ -1006,7 +1006,7 @@ async function taskBuildWebsite() {
10061006
"name": "bower.json",
10071007
"description": "Bower package description file",
10081008
"fileMatch": [ "bower.json", ".bower.json" ],
1009-
"url": "https://json.schemastore.org/bower.json"
1009+
"url": "https://www.schemastore.org/bower.json"
10101010
}
10111011
</pre>
10121012
<p>
@@ -1806,11 +1806,11 @@ async function assertSchemaHasCorrectMetadata(
18061806
])
18071807
}
18081808

1809-
if (schema.json.id !== `https://json.schemastore.org/${schema.name}`) {
1809+
if (schema.json.id !== `https://www.schemastore.org/${schema.name}`) {
18101810
printErrorAndExit(new Error(), [
18111811
`Expected to find correct metadata on schema file "./${schema.path}"`,
18121812
`Incorrect property 'id' for schema "./${path.join(SchemaDir, schema.name)}"`,
1813-
`Expected value of "https://json.schemastore.org/${schema.name}"`,
1813+
`Expected value of "https://www.schemastore.org/${schema.name}"`,
18141814
`Found value of "${schema.json.id}"`,
18151815
])
18161816
}
@@ -1822,11 +1822,11 @@ async function assertSchemaHasCorrectMetadata(
18221822
])
18231823
}
18241824

1825-
if (schema.json.$id !== `https://json.schemastore.org/${schema.name}`) {
1825+
if (schema.json.$id !== `https://www.schemastore.org/${schema.name}`) {
18261826
printErrorAndExit(new Error(), [
18271827
`Expected to find correct metadata on schema file "./${schema.path}"`,
18281828
`Incorrect property '$id' for schema "./${path.join(SchemaDir, schema.name)}"`,
1829-
`Expected value of "https://json.schemastore.org/${schema.name}"`,
1829+
`Expected value of "https://www.schemastore.org/${schema.name}"`,
18301830
`Found value of "${schema.json.$id}"`,
18311831
])
18321832
}

src/api/json/catalog.json

Lines changed: 717 additions & 717 deletions
Large diffs are not rendered by default.

src/negative_test/abc-supply-plan-2.0.0/abc-suppply-plan-extraneous-property.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://json.schemastore.org/abc-supply-plan-2.0.0.json",
2+
"$schema": "https://www.schemastore.org/abc-supply-plan-2.0.0.json",
33
"abcMaterialsMap": {
44
"1": {
55
"abcMaterialName": "FDP",

src/negative_test/abc-supply-plan-2.0.0/abc-suppply-plan-invalid-fractional-lot-size.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://json.schemastore.org/abc-supply-plan-2.0.0.json",
2+
"$schema": "https://www.schemastore.org/abc-supply-plan-2.0.0.json",
33
"abcMaterialsMap": {
44
"1": {
55
"abcMaterialName": "FDP",

src/negative_test/abc-supply-plan-2.0.0/abc-suppply-plan-invalid-planDate.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://json.schemastore.org/abc-supply-plan-2.0.0.json",
2+
"$schema": "https://www.schemastore.org/abc-supply-plan-2.0.0.json",
33
"abcMaterialsMap": {
44
"1": {
55
"abcMaterialName": "FDP",

src/negative_test/abc-supply-plan-2.0.0/abc-suppply-plan-invalid-strings-as-numbers.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://json.schemastore.org/abc-supply-plan-2.0.0.json",
2+
"$schema": "https://www.schemastore.org/abc-supply-plan-2.0.0.json",
33
"abcMaterialsMap": {
44
"1": {
55
"abcMaterialName": 22222,

src/negative_test/abc-supply-plan-3.0.0/abc-suppply-plan-extraneous-property.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://json.schemastore.org/abc-supply-plan-3.0.0.json",
2+
"$schema": "https://www.schemastore.org/abc-supply-plan-3.0.0.json",
33
"abcMaterialsMap": {},
44
"planDate": "2020-03-01",
55
"planNotes": "{\"blocks\":[{\"key\":\"8o58p\",\"text\":\"Plan for March 2020\",\"type\":\"unstyled\",\"depth\":0,\"inlineStyleRanges\":[],\"entityRanges\":[],\"data\":{}}],\"entityMap\":{}}",

src/negative_test/abc-supply-plan-3.0.0/abc-suppply-plan-invalid-fractional-lot-size.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://json.schemastore.org/abc-supply-plan-3.0.0.json",
2+
"$schema": "https://www.schemastore.org/abc-supply-plan-3.0.0.json",
33
"abcMaterialsMap": {
44
"1": {
55
"abcMaterialName": "FDP",

src/negative_test/abc-supply-plan-3.0.0/abc-suppply-plan-invalid-planDate.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://json.schemastore.org/abc-supply-plan-3.0.0.json",
2+
"$schema": "https://www.schemastore.org/abc-supply-plan-3.0.0.json",
33
"abcMaterialsMap": {},
44
"planDate": 1715443874,
55
"planNotes": "{\"blocks\":[{\"key\":\"d4m4a\",\"text\":\"`July 2020 base plan`\",\"type\":\"unstyled\",\"depth\":0,\"inlineStyleRanges\":[],\"entityRanges\":[],\"data\":{}}],\"entityMap\":{}}",

src/negative_test/abc-supply-plan-3.0.0/abc-suppply-plan-invalid-strings-as-numbers.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://json.schemastore.org/abc-supply-plan-3.0.0.json",
2+
"$schema": "https://www.schemastore.org/abc-supply-plan-3.0.0.json",
33
"abcMaterialsMap": {
44
"1": {
55
"abcMaterialName": 1,

0 commit comments

Comments
 (0)