From 8269e8dd4701b1e2385caafae37532e83c9633fb Mon Sep 17 00:00:00 2001 From: Ankush Menat Date: Wed, 13 Apr 2022 13:03:09 +0530 Subject: [PATCH 1/2] fix: ignore duplicate modules during install --- frappe/installer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frappe/installer.py b/frappe/installer.py index 3ce2bdf293..b3a8bad589 100644 --- a/frappe/installer.py +++ b/frappe/installer.py @@ -579,7 +579,7 @@ def add_module_defs(app): d = frappe.new_doc("Module Def") d.app_name = app d.module_name = module - d.save(ignore_permissions=True) + d.insert(ignore_permissions=True, ignore_if_duplicate=True) def remove_missing_apps(): From dad19e2c3f4d28832b9fefc9c076ed88c28125a9 Mon Sep 17 00:00:00 2001 From: Ankush Menat Date: Wed, 13 Apr 2022 13:51:51 +0530 Subject: [PATCH 2/2] fix: `required_apps` blocks app install --- frappe/installer.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frappe/installer.py b/frappe/installer.py index b3a8bad589..634d6287f8 100644 --- a/frappe/installer.py +++ b/frappe/installer.py @@ -242,8 +242,8 @@ def install_app(name, verbose=False, set_as_patched=True): # install pre-requisites if app_hooks.required_apps: for app in app_hooks.required_apps: - name = parse_app_name(app) - install_app(name, verbose=verbose) + required_app = parse_app_name(app) + install_app(required_app, verbose=verbose) frappe.flags.in_install = name frappe.clear_cache()