<commit_before>from django.conf.urls.defaults import url, patterns

from urls import urlpatterns as main_patterns

urlpatterns = patterns('',
    url(r'^projects/(?P<project_slug>[\w.-]+)/(?P<lang_slug>\w{2})/(?P<version_slug>[\w.-]+)/(?P<filename>.*)$',
        'core.views.subproject_serve_docs',
        name='subproject_docs_detail'
    ),
    url(r'^projects/(?P<project_slug>[\w.-]+)',
        'core.views.subproject_serve_docs',
        name='subproject_docs_detail'
    ),
    url(r'^(?P<lang_slug>\w{2})/(?P<version_slug>[\w.-]+)/(?P<filename>.*)$',
        'core.views.serve_docs',
        name='docs_detail'
    ),
    url(r'^(?P<lang_slug>\w{2})/(?P<version_slug>.*)/$',
        'core.views.serve_docs',
        {'filename': 'index.html'},
        name='docs_detail'
    ),
    url(r'^$', 'core.views.subdomain_handler'),
)

urlpatterns += main_patterns<commit_msg>Add verison_slug redirection back in for now.<commit_after>from django.conf.urls.defaults import url, patterns

from urls import urlpatterns as main_patterns

urlpatterns = patterns('',
    url(r'^projects/(?P<project_slug>[\w.-]+)/(?P<lang_slug>\w{2})/(?P<version_slug>[\w.-]+)/(?P<filename>.*)$',
        'core.views.subproject_serve_docs',
        name='subproject_docs_detail'
    ),
    url(r'^projects/(?P<project_slug>[\w.-]+)',
        'core.views.subproject_serve_docs',
        name='subproject_docs_detail'
    ),
    url(r'^(?P<lang_slug>\w{2})/(?P<version_slug>[\w.-]+)/(?P<filename>.*)$',
        'core.views.serve_docs',
        name='docs_detail'
    ),
    url(r'^(?P<lang_slug>\w{2})/(?P<version_slug>.*)/$',
        'core.views.serve_docs',
        {'filename': 'index.html'},
        name='docs_detail'
    ),
    url(r'^(?P<version_slug>.*)/$',
        'core.views.subdomain_handler',
        name='version_subdomain_handler'
    ),
    url(r'^$', 'core.views.subdomain_handler'),
)

urlpatterns += main_patterns
{'fraction_non_alphanumeric': 0.2193717277486911, 'fraction_numerical': 0.0031413612565445027, 'mean_word_length': 3.5717703349282295, 'pattern_counts': {'":': 0, '<': 24, '<?xml version=': 0, '>': 24, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1989591', 'n_tokens_mistral': 717, 'n_tokens_neox': 722, 'n_words': 70}