diff --git a/frappe/desk/form/linked_with.py b/frappe/desk/form/linked_with.py index 4c7220f797..9911acc526 100644 --- a/frappe/desk/form/linked_with.py +++ b/frappe/desk/form/linked_with.py @@ -108,7 +108,11 @@ def _get_linked_doctypes(doctype): ret[dt] = {"get_parent": True} for dt in ret.keys(): - doctype_module = load_doctype_module(dt) + try: + doctype_module = load_doctype_module(dt) + except ImportError: + # in case of Custom DocType + continue if getattr(doctype_module, "exclude_from_linked_with", False): del ret[dt]