def get_app_config():
    from django.utils.crypto import get_random_string
    from google.appengine.ext import ndb

    class Config(ndb.Model):
        """A simple key-value store for application configuration settings."""
        secret_key = ndb.StringProperty()

    # Create a random SECRET_KEY
    chars = 'abcdefghijklmnopqrstuvwxyz0123456789!@#$%^&*(-_=+)'

    @ndb.transactional()
    def txn():
        # Get or create the Config in a transaction, so that if it doesn't exist we don't get 2
        # threads creating a Config object and one overwriting the other
        key = ndb.Key(Config, 'config')
        entity = key.get()
        if not entity:
            entity = Config(key=key)
            entity.secret_key = get_random_string(50, chars)
            entity.put()
        return entity
    return txn()
Return True if the event loop is currently processing, or False
dataset/ETHPy150Open potatolondon/djangae-scaffold/scaffold/boot.py/get_app_config--crossover with--dataset/ETHPy150Open ardekantur/pyglet/pyglet/app/base.py/PlatformEventLoop.is_running