sanic-org / sanic-openapi

Easily document your Sanic API with a UI
https://sanic-openapi.readthedocs.io/
MIT License
505 stars 108 forks source link

[Bug] Even after excluding an endpoint from doc, it still shows the route on swagger, although not the contents of it. #240

Closed amit-d-bahir closed 3 years ago

amit-d-bahir commented 3 years ago

Describe the bug After doing, @doc.exclud(True) for an endpoint, it still shows the route on swagger. The contents of the endpoint are not accessible though

Screenshots The screenshots of Swagger UI if this bug is related to it. https://drive.google.com/file/d/1stDXlRAYL97GfhApTtfBqi1C8W4qjt3i/view?usp=sharing

To Reproduce from sanic import response, Blueprint from sanic.request import Request from sanic.response import HTTPResponse from sanic_openapi import doc bp = Blueprint('send_product_update') @bp.route('/send_product_update', methods=['POST']) @doc.exclude(True)

Expected behavior I expected that it will be completely excluded from the swagger.

Environment (please complete the following information):