def test_init_store_no_index_path(self): config = copy.deepcopy(self._config) config['INDEX_DIR'] = None test_app = Flask('TestApp') test_app.config['STORE'] = config test_store = Store() test_store.init_app(test_app) self.assertIsNone(test_store._index)
""" import os import sys import time import logging import docopt from flask import Flask from eventlog.lib.store import Store from eventlog.service.util import init_config BATCH_LEN = 10 store = Store() def init_logging(): handler = logging.StreamHandler() handler.setLevel(logging.INFO) handler.setFormatter( logging.Formatter(('[%(asctime)s.%(msecs)03d]: ' '%(levelname)10s | %(name)20s | %(message)s'), '%H:%M:%S')) l = logging.getLogger() l.addHandler(handler) l.setLevel(logging.INFO)
from eventlog.lib.store import Store store = Store()
import os import re import os.path import sys import time import shutil import logging import docopt from flask import Flask from eventlog.lib.store import Store from eventlog.service.util import init_config store = Store() IGNORE = ['.DS_Store'] def init_logging(): handler = logging.StreamHandler() handler.setLevel(logging.INFO) handler.setFormatter( logging.Formatter(('[%(asctime)s.%(msecs)03d]: ' '%(levelname)10s | %(name)20s | %(message)s'), '%H:%M:%S')) l = logging.getLogger() l.addHandler(handler) l.setLevel(logging.INFO)
-h, --help Show this screen. -j, --dry-run Enable dry run mode, i.e. index changes are not committed. """ import os import sys import time import logging import docopt from flask import Flask from eventlog.lib.store import Store from eventlog.service.util import init_config store = Store() def init_logging(): handler = logging.StreamHandler() handler.setLevel(logging.INFO) handler.setFormatter( logging.Formatter(('[%(asctime)s.%(msecs)03d]: ' '%(levelname)10s | %(name)20s | %(message)s'), '%H:%M:%S')) l = logging.getLogger() l.addHandler(handler) l.setLevel(logging.INFO)