Newer
Older
"""
Module for code that should run during LMS startup
"""
from django.conf import settings
# Force settings to run so that the python path is modified
settings.INSTALLED_APPS # pylint: disable=W0104
from django_startup import autostartup
Chris Dodge
committed
from xmodule.modulestore.django import modulestore
def run():
"""
Executed during django startup
"""
autostartup()
Chris Dodge
committed
# trigger a forced initialization of our modulestores since this can take a while to complete
# and we want this done before HTTP requests are accepted
for store_name in settings.MODULESTORE:
modulestore(store_name)