wesleylima / django-rest-framework-firebase

Use Firebase to authenticate requests to your Django Rest Framework project
32 stars 14 forks source link

AttributeError 'Firebaseuthentication' object has no attribute 'has_permission' #3

Closed AdrienLemaire closed 6 years ago

AdrienLemaire commented 6 years ago

Hi, and thank you for making this plugin. Unfortunately, it doesn't seem to be working at all for me. Is it not supposed to work with viewsets ? I'm using ModelViewSet and ReadOnlyModelViewSet.

Django==2.0.6 djangorestframework==3.8.2 djangorestframework-firebase==0.1.2 python-firebase==1.2

pm990320 commented 6 years ago

I ran into a similar issue - make sure you are definitely setting DEFAULT_AUTHENTICATION_CLASSES and not DEFAULT_PERMISSION_CLASSES (which is what's on http://www.django-rest-framework.org/#example)

AdrienLemaire commented 6 years ago

I went for a custom authentication class, so not using this package anymore. Anyways, I was probably misusing DEFAULT_PERMISSION_CLASSES at the time as you suggested. Closing.