<commit_before>import os
from urlparse import urljoin

from redis import Redis
#from rq import Queue
from flask import Flask, request, redirect, abort, make_response
from boto.s3.connection import S3Connection

from zinc.catalog import ZincCatalogPathHelper
from zinc.services import ZincCatalog
from zinc.coordinators.redis import RedisCatalogCoordinator
from zinc.storages.aws import S3StorageBackend

# TODO: temp
from config import CONFIG

API_VERSION = '1.0'
REDIS_URL = os.environ.get('REDISTOGO_URL', 'redis://localhost:6379')
REDIS = Redis.from_url(REDIS_URL)
S3 = S3Connection(CONFIG['aws_key'], CONFIG['aws_secret'])

coordinator = RedisCatalogCoordinator(redis=REDIS)

app = Flask(__name__) # todo <commit_msg>Import cleanups<commit_after>import os

from redis import Redis
#from rq import Queue
from flask import Flask, request, abort, make_response
from boto.s3.connection import S3Connection

from zinc.catalog import ZincCatalogPathHelper
from zinc.services import ZincCatalog
from zinc.coordinators.redis import RedisCatalogCoordinator
from zinc.storages.aws import S3StorageBackend

# TODO: temp
from config import CONFIG

API_VERSION = '1.0'
REDIS_URL = os.environ.get('REDISTOGO_URL', 'redis://localhost:6379')
REDIS = Redis.from_url(REDIS_URL)
S3 = S3Connection(CONFIG['aws_key'], CONFIG['aws_secret'])

coordinator = RedisCatalogCoordinator(redis=REDIS)

app = Flask(__name__) # todo 
{'fraction_non_alphanumeric': 0.08469750889679716, 'fraction_numerical': 0.015658362989323844, 'mean_word_length': 6.854748603351955, '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': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7636664', 'n_tokens_mistral': 463, 'n_tokens_neox': 460, 'n_words': 122}