
import os
from django.conf import settings
from .celery import app as celery_app

__all__ = ("celery_app",)

if settings.FILE_DIR is None: raise Exception('settings "FILE_DIR" kosong!');
if os.path.isdir(settings.FILE_DIR) == False: raise Exception('settings "FILE_DIR" bukan folder!');
if os.path.exists(settings.FILE_DIR) == False: raise Exception('settings "FILE_DIR" tidak ketemu!');

if os.access(settings.FILE_DIR, os.R_OK) == False or os.access(settings.FILE_DIR, os.W_OK) == False:
	raise Exception('settings "FILE_DIR" tidak readable &/ writable!');

