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
So our auto schema class is very specifically written for the old DRF schema class, and then takes it and does swagger stuff. There's a new class which already does swagger stuff. We should switch to that one, rewriting our custom class so that we have to maintain less of the logic ourselves.
Exactly how much we need to do is unclear.
The text was updated successfully, but these errors were encountered:
ISSUE TYPE
SUMMARY
In #5407 we are updating Django REST framework.
But in doing that, we are setting this to a old / deprecated kind of class
awx/awx/api/swagger.py
Line 10 in e70c7ab
We actually have our own
AutoSchema
class, which we conditionally inject into our views.awx/awx/api/swagger.py
Lines 27 to 58 in e70c7ab
Compare...
DRF now wants to use
rest_framework.schemas.openapi.AutoSchema
by default:https://www.django-rest-framework.org/api-guide/schemas/
https://github.com/encode/django-rest-framework/blob/7c3477dcdae558b40acfa116ed08eeb5700818eb/rest_framework/schemas/coreapi.py#L336
So our auto schema class is very specifically written for the old DRF schema class, and then takes it and does swagger stuff. There's a new class which already does swagger stuff. We should switch to that one, rewriting our custom class so that we have to maintain less of the logic ourselves.
Exactly how much we need to do is unclear.
The text was updated successfully, but these errors were encountered: