python - Overwriting urls in from third party lib in Django not working -


i'm trying overwrite urls in django, in django oauth2 toolkit can use own view , mixins.

currently when token created django oauth, routes token created. instead of routing here i'm expecting route method , print out on command line in django logs.

i tried overriding urls:

url(r'^oauth2/token/$', tokenview.as_view(), name="token"), url(r'^oauth2/', include('oauth2_provider.urls', namespace='oauth2_provider')), 

however, can't see showing in custom view:

tokenview

class tokenview(csrfexemptmixin, oauthlibmixin, view):      @method_decorator(sensitive_post_parameters('password'))     def post(self, request, *args, **kwargs):         print 'some on in here!' 

is there i'm missing redirections?


Comments

Popular posts from this blog

java - WARN : org.springframework.web.servlet.PageNotFound - No mapping found for HTTP request with URI [/board/] in DispatcherServlet with name 'appServlet' -

html - Outlook 2010 Anchor (url/address/link) -

android - How to create dynamically Fragment pager adapter -