<commit_before>import os

HEROKU_DB_USER=""
HEROKU_DB_PASS=""
HEROKU_DB_HOST=""
HEROKU_DB_NAME=""
try:
    from local_db_creds import *
except ImportError:
    pass


class Config(object):
    DEBUG = False
    TESTING = False
    SECRET_KEY = 'secret key'

class ProductionConfig(Config):
    #DATABASE_URI = 'postgres://username:password@localhost:5432/database'
    SQLALCHEMY_DATABASE_URI = 'postgres://{0}:{1}@{2}:5432/{3}'.format(os.environ.get('HEROKU_DB_USER'), os.environ.get('HEROKU_DB_PASS'), os.environ.get('HEROKU_DB_HOST'), os.environ.get('HEROKU_DB_NAME'))
    DATABASE_URI = SQLALCHEMY_DATABASE_URI

class DevelopmentConfig(Config):
    DEBUG = True
    SQLALCHEMY_DATABASE_URI = 'postgres://{0}:{1}@{2}:5432/{3}'.format(HEROKU_DB_USER, HEROKU_DB_PASS, HEROKU_DB_HOST, HEROKU_DB_NAME)
    DATABASE_URI = SQLALCHEMY_DATABASE_URI

#class TestingConfig(DevelopmentConfig):
#    TESTING = True
#    DATABASE_URI = 'postgres://postgres_test_user:pg_tst_pw@localhost:5432/postgres_test_db'<commit_msg>refactoring<commit_after>import os

try:
    from local_db_creds import *
except ImportError:
    pass


class Config(object):
    DEBUG = False
    TESTING = False
    SECRET_KEY = 'secret key'

class ProductionConfig(Config):
    #DATABASE_URI = 'postgres://username:password@localhost:5432/database'
    SQLALCHEMY_DATABASE_URI = 'postgres://{0}:{1}@{2}:5432/{3}'.format(os.environ.get('HEROKU_DB_USER'), os.environ.get('HEROKU_DB_PASS'), os.environ.get('HEROKU_DB_HOST'), os.environ.get('HEROKU_DB_NAME'))
    DATABASE_URI = SQLALCHEMY_DATABASE_URI

if not os.environ.get('HEROKU'):
    class DevelopmentConfig(Config):
        DEBUG = True
        SQLALCHEMY_DATABASE_URI = 'postgres://{0}:{1}@{2}:5432/{3}'.format(HEROKU_DB_USER, HEROKU_DB_PASS, HEROKU_DB_HOST, HEROKU_DB_NAME)
        DATABASE_URI = SQLALCHEMY_DATABASE_URI

#class TestingConfig(DevelopmentConfig):
#    TESTING = True
#    DATABASE_URI = 'postgres://postgres_test_user:pg_tst_pw@localhost:5432/postgres_test_db'
{'fraction_non_alphanumeric': 0.1326990485728593, 'fraction_numerical': 0.024036054081121683, 'mean_word_length': 5.66, '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': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5848469', 'n_tokens_mistral': 811, 'n_tokens_neox': 773, 'n_words': 98}