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

Fixed missing description in /home API response Swagger docs #176

Merged

Conversation

isabelcosta
Copy link
Member

@isabelcosta isabelcosta commented Jan 4, 2019

Description

I fixed the bug of the Swagger not being generated. namespace.response annotation from flask-restplus was being wrongly used. There was a field missing: description.

Fixes #175

Type of Change:

  • Code

Code/Quality Assurance Only

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

I accessed on a Browser http://localhost:5000/ where Swagger UI is served.
Here's swagger ui for /Home API endpoint:

swagger ui for /Home API endpoint

Checklist:

  • My PR follows the style guidelines of this project
  • I have performed a self-review of my own code or materials

Code/Quality Assurance Only

  • My changes generate no new warnings

@haroldadmin
Copy link
Contributor

haroldadmin commented Jan 4, 2019

@isabelcosta I'm sorry about this regression. I'm new to Python and Flask (#158 was my first ever PR to any such system) and so this issue creeped in. I'll take care to add a description to these Swagger decorators now onwards.

I'm glad that you were able to identify the problem and fix it so quickly.

@isabelcosta
Copy link
Member Author

@haroldadmin please don't feel bad about it! We all can learn from it. You learned something and I remembered something from Flask :) it's all good now! I will create a wiki doc explaining how to export the json file for future PRs. You did a great job with that PR.

@isabelcosta
Copy link
Member Author

Thank you @m-murad for approving this so quickly!

@isabelcosta isabelcosta added the Type: Bug Bug or Bug fixes. label Jan 4, 2019
@isabelcosta isabelcosta merged commit 90278e3 into anitab-org:develop Jan 5, 2019
@isabelcosta isabelcosta deleted the #175-fix-swagger-ui-generation branch January 5, 2019 15:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Bug or Bug fixes.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Swagger UI is not being generated
3 participants