<commit_before>from django.conf.urls import patterns, include, url
from django.views.generic.base import RedirectView

'''
@author: <NAME>
@date: Mar 21, 2013

Datahub URL Router
'''

urlpatterns = patterns('',

    ########################################################################################
    ######## ------------------------------ DataHub Core ------------------------- #########
    ########################################################################################

    #### Home Page ####
    url(r'^$', 'browser.views.home'),
    url(r'^about$', 'browser.views.about'),  # for backward compatibility
    url(r'^favicon\.ico$', RedirectView.as_view(url='/static/images/favicon.ico', permanent=True)),
    #### End Home ####

    #### WWW Pages ####
    url(r'^www/', include('www.urls')),
    #### End WWW Pages ####

    #### Account Related ####
    url(r'^account/', include('account.urls')),
    url(r'^oidc/', include('oidc.urls')),
    #### End Account Related ####


    #### Thrift Services ####
    url(r'^service$', 'browser.views.service_core_binary'),
    url(r'^service/account$', 'browser.views.service_account_binary'),
    url(r'^service/json$', 'browser.views.service_core_json'),
    #### End Thrift Services ####


    #### Create ####
    url(r'^create/(\w+)/repo/?$', 'browser.views.repo_create'),

    url(r'^create/(\w+)/(\w+)/card/?$', 'browser.views.card_create'),

    url(r'^create/annotation/?$', 'browser.views.create_annotation'),
    #### End Create ####


    #### Browse ####
    url(r'^browse/(\w+)/(\w+)/table/(\w+)/?$', 'browser.views.table'),

    url(r'^browse/(\w+)/(\w+)/query/?$', 'browser.views.query'),

    url(r'^browse/(\w+)/(\w+)/card/(.+)/?$', 'browser.views.card'),

    url(r'^browse/(\w+)/(\w+)/?$', 'browser.views.repo'),

    url(r'^browse/(\w+)/(\w+)/tables/?$', 'browser.views.repo_tables'),

    url(r'^browse/(\w+)/(\w+)/files/?$', 'browser.views.repo_files'),

    url(r'^browse/(\w+)/(\w+)/cards/?$', 'browser.views.repo_cards'),

    url(r'^browse/(\w+)/?$', 'browser.views.user'),
    #### End Browse ####


    ### Delete ####
    url(r'^delete/(\w+)/(\w+)/?$', 'browser.views.repo_delete'),

    url(r'^delete/(\w+)/(\w+)/table/(\w+)/?$', 'browser.views.table_delete'),

    url(r'^delete/(\w+)/(\w+)/card/(\w+)/?$', 'browser.views.card_delete'),

    url(r'^delete/(\w+)/(\w+)/file/([\w\d\-\.]+)/?$', 'browser.views.file_delete'),
    ### End Delete ####


    ### Export ###
    url(r'^export/(\w+)/(\w+)/table/(\w+)/?$', 'browser.views.table_export'),

    ### End Export ####


    ### Special File Operations ####
    url(r'^upload/(\w+)/(\w+)/file/?$', 'browser.views.file_upload'),
    url(r'^import/(\w+)/(\w+)/file/([\w\d\-\.]+)', 'browser.views.file_import'),
    url(r'^download/(\w+)/(\w+)/file/([\w\d\-\.]+)', 'browser.views.file_download'),
    ### End Special File Operations ####


    #### Settings ####
    url(r'^settings/(\w+)/(\w+)/?$', 'browser.views.repo_settings'),

    #### End Settings ####


    ### Collaborators ###
    url(r'^collaborator/repo/(\w+)/(\w+)/add/?$', 'browser.views.repo_collaborators_add'),

    url(r'^collaborator/repo/(\w+)/(\w+)/remove/(\w+)/?$', 'browser.views.repo_collaborators_remove'),
    ### End Collaborators ###

    ### Developer Apps ###
    url(r'^developer/apps/?$', 'browser.views.apps'),

    url(r'^developer/apps/register/?$', 'browser.views.app_register'),

    url(r'^developer/apps/remove/(\w+)/?$', 'browser.views.app_remove'),
    ### End Apps ###

    ### Permissions ###
    url(r'^permissions/apps/allow_access/(\w+)/(\w+)$', 'browser.views.app_allow_access'),

    url(r'^api/rest/', include('api.rest.urls')), # REST APIs

    ########################################################################################
    ######## ------------------------------ END DataHub Core --------------------- #########
    ########################################################################################


    #### Apps ####
    url(r'^apps/console/', include('console.urls')), # console app
    url(r'^apps/refiner/', include('refiner.urls')), # refiner app
    url(r'^apps/dbwipes/', include('dbwipes.urls')), # dbwipes app
    url(r'^apps/viz/', include('viz2.urls')), # viz app
    url(r'^apps/sentiment/', include('sentiment.urls')), # sentiment app
    url(r'^apps/dataq/', include('dataq.urls')), # dataq app
    url(r'^apps/datatables/', include('datatables.urls')), # datatables app
    #### End Apps ####
)<commit_msg>Disable REST APIs for now.<commit_after>from django.conf.urls import patterns, include, url
from django.views.generic.base import RedirectView

'''
@author: <NAME>
@date: Mar 21, 2013

Datahub URL Router
'''

urlpatterns = patterns('',

    ########################################################################################
    ######## ------------------------------ DataHub Core ------------------------- #########
    ########################################################################################

    #### Home Page ####
    url(r'^$', 'browser.views.home'),
    url(r'^about$', 'browser.views.about'),  # for backward compatibility
    url(r'^favicon\.ico$', RedirectView.as_view(url='/static/images/favicon.ico', permanent=True)),
    #### End Home ####

    #### WWW Pages ####
    url(r'^www/', include('www.urls')),
    #### End WWW Pages ####

    #### Account Related ####
    url(r'^account/', include('account.urls')),
    url(r'^oidc/', include('oidc.urls')),
    #### End Account Related ####


    #### Thrift Services ####
    url(r'^service$', 'browser.views.service_core_binary'),
    url(r'^service/account$', 'browser.views.service_account_binary'),
    url(r'^service/json$', 'browser.views.service_core_json'),
    #### End Thrift Services ####


    #### Create ####
    url(r'^create/(\w+)/repo/?$', 'browser.views.repo_create'),

    url(r'^create/(\w+)/(\w+)/card/?$', 'browser.views.card_create'),

    url(r'^create/annotation/?$', 'browser.views.create_annotation'),
    #### End Create ####


    #### Browse ####
    url(r'^browse/(\w+)/(\w+)/table/(\w+)/?$', 'browser.views.table'),

    url(r'^browse/(\w+)/(\w+)/query/?$', 'browser.views.query'),

    url(r'^browse/(\w+)/(\w+)/card/(.+)/?$', 'browser.views.card'),

    url(r'^browse/(\w+)/(\w+)/?$', 'browser.views.repo'),

    url(r'^browse/(\w+)/(\w+)/tables/?$', 'browser.views.repo_tables'),

    url(r'^browse/(\w+)/(\w+)/files/?$', 'browser.views.repo_files'),

    url(r'^browse/(\w+)/(\w+)/cards/?$', 'browser.views.repo_cards'),

    url(r'^browse/(\w+)/?$', 'browser.views.user'),
    #### End Browse ####


    ### Delete ####
    url(r'^delete/(\w+)/(\w+)/?$', 'browser.views.repo_delete'),

    url(r'^delete/(\w+)/(\w+)/table/(\w+)/?$', 'browser.views.table_delete'),

    url(r'^delete/(\w+)/(\w+)/card/(\w+)/?$', 'browser.views.card_delete'),

    url(r'^delete/(\w+)/(\w+)/file/([\w\d\-\.]+)/?$', 'browser.views.file_delete'),
    ### End Delete ####


    ### Export ###
    url(r'^export/(\w+)/(\w+)/table/(\w+)/?$', 'browser.views.table_export'),

    ### End Export ####


    ### Special File Operations ####
    url(r'^upload/(\w+)/(\w+)/file/?$', 'browser.views.file_upload'),
    url(r'^import/(\w+)/(\w+)/file/([\w\d\-\.]+)', 'browser.views.file_import'),
    url(r'^download/(\w+)/(\w+)/file/([\w\d\-\.]+)', 'browser.views.file_download'),
    ### End Special File Operations ####


    #### Settings ####
    url(r'^settings/(\w+)/(\w+)/?$', 'browser.views.repo_settings'),

    #### End Settings ####


    ### Collaborators ###
    url(r'^collaborator/repo/(\w+)/(\w+)/add/?$', 'browser.views.repo_collaborators_add'),

    url(r'^collaborator/repo/(\w+)/(\w+)/remove/(\w+)/?$', 'browser.views.repo_collaborators_remove'),
    ### End Collaborators ###

    ### Developer Apps ###
    url(r'^developer/apps/?$', 'browser.views.apps'),

    url(r'^developer/apps/register/?$', 'browser.views.app_register'),

    url(r'^developer/apps/remove/(\w+)/?$', 'browser.views.app_remove'),
    ### End Apps ###

    ### Permissions ###
    url(r'^permissions/apps/allow_access/(\w+)/(\w+)$', 'browser.views.app_allow_access'),

    # url(r'^api/rest/', include('api.rest.urls')), # REST APIs

    ########################################################################################
    ######## ------------------------------ END DataHub Core --------------------- #########
    ########################################################################################


    #### Apps ####
    url(r'^apps/console/', include('console.urls')), # console app
    url(r'^apps/refiner/', include('refiner.urls')), # refiner app
    url(r'^apps/dbwipes/', include('dbwipes.urls')), # dbwipes app
    url(r'^apps/viz/', include('viz2.urls')), # viz app
    url(r'^apps/sentiment/', include('sentiment.urls')), # sentiment app
    url(r'^apps/dataq/', include('dataq.urls')), # dataq app
    url(r'^apps/datatables/', include('datatables.urls')), # datatables app
    #### End Apps ####
)
{'fraction_non_alphanumeric': 0.3621819797800244, 'fraction_numerical': 0.0015553827352516388, 'mean_word_length': 3.5077616424636955, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1506081', 'n_tokens_mistral': 3228, 'n_tokens_neox': 2990, 'n_words': 372}