cardinalby / schema-validator-action

JSON Schema validator Action
MIT License
11 stars 2 forks source link

Cannot validate https://docs.renovatebot.com/renovate-schema.json #12

Open MPV opened 1 month ago

MPV commented 1 month ago

I experience:

Run cardinalby/schema-validator-action@2166123eb256fa40baef7e22ab1379708425efc7
  with:
    schema: https://docs.renovatebot.com/renovate-schema.json
    file: renovate.json
    mode: lax
    fileParser: auto
    fixSchemas: false
Schema loaded from https://docs.renovatebot.com/renovate-schema.json has undefined type:
Contents of 'https://docs.renovatebot.com/renovate-schema.json' has been parsed as json object
Error: Error: Contents of 'renovate.json' aren't a valid json: json: SyntaxError: Bad escaped character in JSON at position 946
Error: Failed because of file error

Am I missing something I shouldn't?

It seems to me that JQ indicates the file would be valid JSON.

This is line 946:

$ cat renovate-schema.json|awk 'NR==946'
    "docker-compose": {

And here's an excerpt of the lines around 946:

 939       "default": {
 940         "branchTopic": "{{{depNameSanitized}}}-digest",
 941         "commitMessageExtra": "to {{newDigestShort}}",
 942         "commitMessageTopic": "{{{depName}}} digest"
 943       },
 944       "$ref": "#"
 945     },
 946     "docker-compose": {
 947       "description": "Configuration object for the docker-compose manager",
 948       "type": "object",
 949       "default": {
 950         "fileMatch": [
 951           "(^|/)(?:docker-)?compose[^/]*\\.ya?ml$"
 952         ]
 953       },
 954       "$ref": "#"
 955     },
 956     "dockerChildPrefix": {
 957       "description": "Chang
cardinalby commented 1 month ago

Hi! The error says about 'renovate.json' I believe, not about renovate-schema.json