I am getting the following error while installing insights on the site. Frappe Version-14:
Installing insights...
An error occurred while installing insights: Module import failed for Insights Workbook, the DocType you're trying to open might be deleted.<br> Error: cannot import name 'bulk_insert' from 'frappe.model.document' (/home/paavaninfotech/frappe-bench/apps/frappe/frappe/model/document.py)
Traceback (most recent call last):
File "apps/frappe/frappe/modules/utils.py", line 241, in load_doctype_module
doctype_python_modules[key] = frappe.get_module(module_name)
File "apps/frappe/frappe/__init__.py", line 1335, in get_module
return importlib.import_module(modulename)
File "/usr/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "apps/insights/insights/insights/doctype/insights_workbook/insights_workbook.py", line 14, in <module>
from insights.api.workbooks import fetch_query_results
File "apps/insights/insights/api/__init__.py", line 10, in <module>
from insights.decorators import insights_whitelist, validate_type
File "apps/insights/insights/decorators.py", line 10, in <module>
from insights.insights.doctype.insights_team.insights_team import is_admin
File "apps/insights/insights/insights/doctype/insights_team/insights_team.py", line 10, in <module>
from insights.insights.doctype.insights_data_source_v3.ibis_utils import (
File "apps/insights/insights/insights/doctype/insights_data_source_v3/ibis_utils.py", line 17, in <module>
from insights.insights.doctype.insights_table_v3.insights_table_v3 import (
File "apps/insights/insights/insights/doctype/insights_table_v3/insights_table_v3.py", line 8, in <module>
from frappe.model.document import Document, bulk_insert
ImportError: cannot import name 'bulk_insert' from 'frappe.model.document' (apps/frappe/frappe/model/document.py)
Thanks,
Divyesh Mangroliya