Moved import os.path to the begining of settings.py