You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.
$ swagger-cli validate spec.yaml
Swagger schema validation failed.
Additional properties not allowed: putty at #/paths//foo/{id}/bar/{bar_id}
JSON_OBJECT_VALIDATION_FAILED
But with pre-commit I get:
$ pre-commit run --all
Trim Trailing Whitespace.................................................Passed
Fix End of Files.........................................................Passed
Check Yaml...............................................................Passed
Check Xml............................................(no files to check)Skipped
Check JSON...........................................(no files to check)Skipped
Check for added large files..............................................Passed
Check for merge conflicts................................................Passed
isort....................................................................Passed
flake8...................................................................Passed
swagger-validation...................................(no files to check)Skipped
The text was updated successfully, but these errors were encountered:
I faced the same issue @MT-Cash . Looks like you would need to rename your spec.yamlto swagger-spec.yaml. It needs swagger in the file name according to the regex specified. That solved the issue for me.
I've added this to my pre-commit config:
When I run it manually, I get:
But with pre-commit I get:
The text was updated successfully, but these errors were encountered: