Open
Description
I have a project level nestor/urls.py
file like this:
urlpatterns = [
url(r'^v1/', include('nestor.v1.urls', namespace='api-v1')),
url(r'^docs/', include('rest_framework_docs.urls', namespace='api-docs')),
]
Then nestor/v1/urls.py
like:
router = rest_framework.routers.DefaultRouter()
router.register('node', Node, base_name='node')
router.register('vm', VirtualMachine, base_name='vm')
router.register('ldev', LDev, base_name='ldev')
# BUG: DRFDocs is not picking up the nesting properly
urlpatterns = [
url(r'^', include(router.urls)),
]
The generated URLs in the doc look like:
/node/
/node/<pk>/
/vm/
/vm/<pk>/
/vm/<pk>/reboot/
/ldev/
/
Clearly, the v1/
prefix is missing. I think the culprit is the recursive part of the endpoint generator:
In that line, the parent_patter
that was carried in the recursive call is replaced and not accumulated.
Also, I have the impression that @manosim has stopped working on the package.
Metadata
Metadata
Assignees
Labels
No labels