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

Validation error with swagger-express-mw 0.6.0 #11

Open
carbonrider opened this issue Apr 18, 2016 · 2 comments
Open

Validation error with swagger-express-mw 0.6.0 #11

carbonrider opened this issue Apr 18, 2016 · 2 comments

Comments

@carbonrider
Copy link

I have a swagger project which uses swagger-express-mw 0.1.0. The path definitions for swagger.yaml file has been externalized into another file. When I start the project using swagger project start, everything works fine.

I tried upgrading to swagger-express-mw version to 0.6.0 and the error just pops out while starting project.

Error in callback! Tossing to global error handler. Error: Swagger validation errors:

Is there any bug fixes applied recently which has caused schema resolution to fail? Please help.

@theganyo
Copy link
Contributor

Hey Yogesh,

Most likely you just need to update your config for the latest version. Please see this: https://github.com/theganyo/swagger-node-runner/releases/tag/v0.6.0.

Let me know if you have any more issues!
Scott

@carbonrider
Copy link
Author

Thanks Scott, for your quick response. I tried updating the default.yaml file with the swagger_params_parser, but it didn't work. I am still getting the schema validation error while starting project using swagger project start. The surprising factor is swagger project verify, indicates that there are 0 errors.
Here are some more details about the directory structure for swagger configuration
image

The swagger.yaml file has following code to refer visitorSearchUsingMobile.yaml
image

Note that, I tried changing the path definition to relative as well like ./paths/visitorSearchUsingMobile.yaml but that didn't work too. Also making it relative fails with swagger project verify command. Relative references from swagger.yaml file are failing, and hence I have to specify complete path from root directory of the project (this is another problem, I am seeing from 0.1.0). Relative references are only working with files other than swagger.yaml

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

2 participants