def get_env_setting(setting):
    """ Get the environment setting or return exception """
    try:
        return os.environ[setting]
    except __HOLE__:
        error_msg = "Set the %s env variable" % setting
        raise ImproperlyConfigured(error_msg)


# Your project root
dataset/ETHPy150Open xenith/django-base-template/project_name/settings/base.py/get_env_setting