PROBLEM
I have created the functionality of a data import tracker, which is similar to data import in frappe/erpnext. I have setup an enqueue process to import records. I am importing records through a large CSV file. It has thousands of records and is going through some customized import functions. When I start to import it in a minute or two, it is throwing an error: “Request Time Out”. I have not set up any workers. I tried but could not find any document to set it up for My Enqueue Job.
VERSION INFO:
ERPNext: v14.0.0-dev (version-14-beta-pre-release)
Frappe Framework: v14.0.0-dev (version-14-beta-pre-release)
CSV FILE SIZE :- 9 MB
def start_import(self):
enqueued_jobs = self.create_enqueued_jobs()
if self.name not in enqueued_jobs:
enqueue(
start_import,
queue="default",
timeout=10000,
event="data_import_tracker",
job_name=self.name,
data_import=self.name,
now=frappe.conf.developer_mode or frappe.flags.in_test,
# is_async=True
)
return True
return False
ERROR MESSAGE :
STEP TO RESOLVE
→ I have created batch from this CSV file and divided it in small chunk of 1000 lines at a time.
→ As there are many validations to import single record. So Not able to use default import process.
Any idea how to solve such issue ? Please let me know if required any further information.