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
Yesterday I update DRF version from from 3.3.3 to 3.4 and setup restframework-swagger.
It returns me: AttributeError " DriverVehiclesViewSet' object has no attribute 'request' "
.../python3.5/site-packages/rest_framework/schemas.py in get_api_endpoints prefix=path_regex ...
.../python3.5/site-packages/rest_framework/schemas.py in get_api_endpoints prefix=path_regex ...
.../python3.5/site-packages/rest_framework/schemas.py in get_api_endpoints prefix=path_regex ...
.../python3.5/site-packages/rest_framework/schemas.py in get_api_endpoints link = self.get_link(path, method, callback) ...
.../python3.5/site-packages/rest_framework/schemas.py in get_link fields += self.get_serializer_fields(path, method, callback, view) ...
.../python3.5/site-packages/rest_framework/schemas.py in get_serializer_fields serializer_class = view.get_serializer_class() ...
.../src/taxiback/api/v1/views/driver.py in get_serializer_class if self.request.method in drf_permissions.SAFE_METHODS: ...
Can somebody explain me why I got it.
The text was updated successfully, but these errors were encountered:
I use
get_queryset()
andget_serializer_class()
across almost all my apps.Usually I follow a way from DRF documentation:
Yesterday I update DRF version from from 3.3.3 to 3.4 and setup restframework-swagger.
It returns me:
AttributeError " DriverVehiclesViewSet' object has no attribute 'request' "
.../python3.5/site-packages/rest_framework/schemas.py in get_api_endpoints
prefix=path_regex ...
.../python3.5/site-packages/rest_framework/schemas.py in get_api_endpoints
prefix=path_regex ...
.../python3.5/site-packages/rest_framework/schemas.py in get_api_endpoints
prefix=path_regex ...
.../python3.5/site-packages/rest_framework/schemas.py in get_api_endpoints
link = self.get_link(path, method, callback) ...
.../python3.5/site-packages/rest_framework/schemas.py in get_link
fields += self.get_serializer_fields(path, method, callback, view) ...
.../python3.5/site-packages/rest_framework/schemas.py in get_serializer_fields
serializer_class = view.get_serializer_class() ...
.../src/taxiback/api/v1/views/driver.py in get_serializer_class
if self.request.method in drf_permissions.SAFE_METHODS: ...
Can somebody explain me why I got it.
The text was updated successfully, but these errors were encountered: