Skip to content

Commit ff157d2

Browse files
authored
[core] Dynamically import oozie_setup for /install_esamples API to avoid oozie INSTALLED_APPS runtime error (#4050)
1 parent 6457491 commit ff157d2

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

desktop/core/src/desktop/api2.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@
9393
from metadata.conf import has_catalog
9494
from notebook.connectors.base import Notebook, get_interpreter
9595
from notebook.management.commands import notebook_setup
96-
from oozie.management.commands import oozie_setup
9796
from pig.management.commands import pig_setup
9897
from search.management.commands import search_setup
9998
from useradmin.models import Group, User
@@ -1447,6 +1446,9 @@ def _setup_pig_examples(request):
14471446

14481447

14491448
def _setup_oozie_examples(request):
1449+
# Import dynamically to avoid oozie INSTALLED_APPS error
1450+
from oozie.management.commands import oozie_setup
1451+
14501452
oozie_setup.Command().handle()
14511453

14521454

0 commit comments

Comments
 (0)