We're porting our API from Django - Piston to Django-TastyPie. Everything went smoothly, 'till we got to this:
urls.py of the app
url(r'^upload/', Resource(UploadHandler, authentication=KeyAuthentication()), name="api-upload"),
url(r'^result/(?P<uuid>[^//]+)/', Resource(ResultsHandler, authentication=KeyAuthentication()), name="api-result")
This uses piston, so we want to change it into something for tastyPie
url(r'^upload/', include(upload_handler.urls), name="api-upload"),
url(r'^result/(?P<uuid>[^//]+)/', include(results_handler.urls), name="api-result")
But we're stuck on this fault
Reverse for 'api-result' with arguments '()' and keyword arguments '{'uuid': 'fbe7f421-b911-11e0-b721-001f5bf19720'}' not found.
And the Debugpage of result:
Using the URLconf defined in MelodyService.urls, Django tried these URL patterns, in this order:
^melotranscript/ ^upload/ ^melotranscript/ ^result/(?P[^//]+)/ ^(?Presultshandler)/$ [name='api_dispatch_list'] ^melotranscript/ ^result/(?P[^//]+)/ ^(?Presultshandler)/schema/$ [name='api_get_schema'] ^melotranscript/ ^result/(?P[^//]+)/ ^(?Presultshandler)/set/(?P\w[\w/;-]*)/$ [name='api_get_multiple'] ^melotranscript/ ^result/(?P[^//]+)/ ^(?Presultshandler)/(?P\w[\w/-]*)/$ [name='api_dispatch_detail'] ^melotranscript/ ^processed/(?P.)$ ^admin/doc/ ^TOU/$ [name='TOU'] ^$ [name='index'] ^admin/ ^doc/(?P.)$ The current URL, melotranscript/result/fbe7f421-b911-11e0-b721-001f5bf19720/, didn't match any of these.
Someone who knows the problem? It's maybe a really silly/noobish question...
{% ... %}
instead of python code? – Elmerelmina