import django.contrib.auth.views as v
from django.conf.urls import include, url

from user.views import self_profile, view_profile, edit_profile

from user.forms import AuthenticationForm, PasswordResetForm, PasswordChangeForm

urlpatterns = [
    url(r'a/login/$', v.login,
        {'authentication_form': AuthenticationForm}, name='login'),

    url(r'a/logout/$', v.logout, name='logout'),

    url(r'a/password_change/$', v.password_change,
        {'post_change_redirect': 'password_change_done',
         'password_change_form': PasswordChangeForm}, name='password_change'),
    url(r'a/password_change/done/$', v.password_change_done, name='password_change_done'),

    url(r'a/password_reset/$', v.password_reset,
        {'post_reset_redirect': 'password_reset_done',
         'password_reset_form': PasswordResetForm}, name='password_reset'),
    url(r'a/password_reset/done/$', v.password_reset_done, name='password_reset_done'),
    url(r'a/password_reset/confirm/(?P<uidb64>[a-zA-Z0-9]+)/(?P<token>.+)/$', v.password_reset_confirm,
        {'post_reset_redirect': 'password_reset_complete'}, name='password_reset_confirm'),
    url(r'a/password_reset/complete/$', v.password_reset_complete, name='password_reset_complete'),
    url(r'a/', include('registration.backends.default.urls')),

    url(r'a/e/(?P<username>[a-zA-Z0-9@.+-_]+)/$', edit_profile, name='edit_profile'),

    url(r'(?P<username>[a-zA-Z0-9@.+-_]+)/$', view_profile, name='view_profile'),

    url(r'$', self_profile, name='view_self_profile'),
]

@@ -243,24 +243,25 @@
 %5B%0A    url(r'
+%5E
 a/login/$', 
@@ -348,16 +348,17 @@
   url(r'
+%5E
 a/logout
@@ -391,32 +391,33 @@
 t'),%0A%0A    url(r'
+%5E
 a/password_chang
@@ -579,32 +579,33 @@
 ge'),%0A    url(r'
+%5E
 a/password_chang
@@ -672,32 +672,33 @@
 e'),%0A%0A    url(r'
+%5E
 a/password_reset
@@ -853,32 +853,33 @@
 et'),%0A    url(r'
+%5E
 a/password_reset
@@ -942,32 +942,33 @@
 ne'),%0A    url(r'
+%5E
 a/password_reset
@@ -1147,16 +1147,17 @@
   url(r'
+%5E
 a/passwo
@@ -1248,16 +1248,17 @@
   url(r'
+%5E
 a/', inc
@@ -1313,16 +1313,17 @@
   url(r'
+%5E
 a/e/(?P%3C
@@ -1401,16 +1401,17 @@
   url(r'
+%5E
 (?P%3Cuser
@@ -1485,16 +1485,17 @@
   url(r'
+%5E
 $', self

Fix wrong regexes in the url routing data