<commit_before>from django.conf.urls import patterns, include, url
from django.conf.urls.i18n import i18n_patterns
from django.utils.translation import ugettext_lazy as _
from django.contrib import admin
from django.views.generic import TemplateView
from base.views import IndexView
from django.conf import settings
from django.conf.urls.static import static

from wiki.urls import get_pattern as get_wiki_pattern
from django_notify.urls import get_pattern as get_notify_pattern

admin.autodiscover()

# Add basic non-localized patterns
urlpatterns = patterns('',
    url(r'^$', IndexView.as_view(), name='roots_index'),
    url(r'^i18n/', include('django.conf.urls.i18n')),
) + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)

urlpatterns += i18n_patterns('',
    # Examples:
    # url(r'^$', 'roots.views.home', name='home'),
    # url(r'^roots/', include('roots.foo.urls')),

    # Uncomment the admin/doc line below to enable admin documentation:
    # url(r'^admin/doc/', include('django.contrib.admindocs.urls')),

    # Uncomment the next line to enable the admin:
    url(r'^$', IndexView.as_view(), name='roots_index'),
    url(_(r'^admin/doc/'), include('django.contrib.admindocs.urls')),
    url(_(r'^admin/'), include(admin.site.urls)),
    url(_(r'^grappelli/'), include('grappelli.urls')),
    url(_(r'^accounts/'), include('allauth.urls')),
    url(_(r'^accounts/profile/'), TemplateView.as_view(
                               template_name='profile.html')),
    url(_(r'^competitions/'), include('competitions.urls')),
    url(_(r'^comments/'), include('fluent_comments.urls')),
    url(_(r'^events/'), include('events.urls')),
    url(_(r'^leaflets/'), include('leaflets.urls')),
    url(_(r'^problems/'), include('problems.urls')),
    url(_(r'^posts/'), include('posts.urls')),
    url(_(r'^photos/'), include('photos.urls')),
    url(_(r'^photos/'), include('photologue.urls')),
    url(_(r'^profiles/'), include('profiles.urls')),
    url(_(r'^media/protected/'), include('downloads.urls'))
)

# Add django-wiki related patterns
urlpatterns += i18n_patterns('',
    (_(r'^wiki/notify/'), get_notify_pattern()),
    (_(r'^wiki/'), get_wiki_pattern())
)


if settings.DEBUG:
    import debug_toolbar
    urlpatterns += i18n_patterns('',
        url(r'^__debug__/', include(debug_toolbar.urls)),
    )
<commit_msg>urls: Give a name to the accounts/profile.html view<commit_after>from django.conf.urls import patterns, include, url
from django.conf.urls.i18n import i18n_patterns
from django.utils.translation import ugettext_lazy as _
from django.contrib import admin
from django.views.generic import TemplateView
from base.views import IndexView
from django.conf import settings
from django.conf.urls.static import static

from wiki.urls import get_pattern as get_wiki_pattern
from django_notify.urls import get_pattern as get_notify_pattern

admin.autodiscover()

# Add basic non-localized patterns
urlpatterns = patterns('',
    url(r'^$', IndexView.as_view(), name='roots_index'),
    url(r'^i18n/', include('django.conf.urls.i18n')),
) + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)

urlpatterns += i18n_patterns('',
    # Examples:
    # url(r'^$', 'roots.views.home', name='home'),
    # url(r'^roots/', include('roots.foo.urls')),

    # Uncomment the admin/doc line below to enable admin documentation:
    # url(r'^admin/doc/', include('django.contrib.admindocs.urls')),

    # Uncomment the next line to enable the admin:
    url(r'^$', IndexView.as_view(), name='roots_index'),
    url(_(r'^admin/doc/'), include('django.contrib.admindocs.urls')),
    url(_(r'^admin/'), include(admin.site.urls)),
    url(_(r'^grappelli/'), include('grappelli.urls')),
    url(_(r'^accounts/'), include('allauth.urls')),
    url(_(r'^accounts/profile/'), TemplateView.as_view(
                               template_name='profile.html'),
                               name='roots_profile'),
    url(_(r'^competitions/'), include('competitions.urls')),
    url(_(r'^comments/'), include('fluent_comments.urls')),
    url(_(r'^events/'), include('events.urls')),
    url(_(r'^leaflets/'), include('leaflets.urls')),
    url(_(r'^problems/'), include('problems.urls')),
    url(_(r'^posts/'), include('posts.urls')),
    url(_(r'^photos/'), include('photos.urls')),
    url(_(r'^photos/'), include('photologue.urls')),
    url(_(r'^profiles/'), include('profiles.urls')),
    url(_(r'^media/protected/'), include('downloads.urls'))
)

# Add django-wiki related patterns
urlpatterns += i18n_patterns('',
    (_(r'^wiki/notify/'), get_notify_pattern()),
    (_(r'^wiki/'), get_wiki_pattern())
)


if settings.DEBUG:
    import debug_toolbar
    urlpatterns += i18n_patterns('',
        url(r'^__debug__/', include(debug_toolbar.urls)),
    )

{'fraction_non_alphanumeric': 0.18160919540229886, 'fraction_numerical': 0.005851619644723093, 'mean_word_length': 4.630588235294118, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4065975', 'n_tokens_mistral': 1650, 'n_tokens_neox': 1595, 'n_words': 288}