Q: Cannot use extra_option with path django I don't understand why I cannot use the path() method as documented here: https://docs.djangoproject.com/en/2.0/topics/http/urls/#passing-extra-options-to-view-functions in my apps urls.py.
Here is the code I have:
from django.conf.urls import url, include
from django.contrib import admin
from django.urls import path
from . import views as AliasViews
from permissions import views as PermissionsViews

    urlpatterns = [
    ...
        path(r'^user/(?P<alias_id>\d{1,})/members/?$', 
             AliasViews.UserAliasMember.as_view(), 
             name='useralias_member', {'alias_type':'UserAlias'}),
    ...    
    ]

I get this error: SyntaxError: non-keyword arg after keyword arg.

A: This has nothing to do with the path function. As the error says, Python syntax does not allow keyword arguments - eg name='useralias_member' - before non-keyword arguments. Your extra dictionary should be before that name argument.
Note however that you're also confusing path with url. The new path function doesn't use regexes, it uses the special <arg:type> format. If you want to use regexes, switch back to url.
