erpnext
erpnext copied to clipboard
Error while submitting internal sales invoice
Information about bug
Steps =
- Create Customer - Is Internal Customer = true, address = GST State Delhi
- Create an Item with a Batch number
- Create a sales order for an internal customer with a Delhi Address and Company & Dispatch of any other GST State (Maharashtra)
- Update Stock Check box = True and Source Warehouse = Maharashtra , Target Warehouse = Goods in Transit.
- Submit the invoice and below error is appearing
When I am trying to submit a sales invoice of an internal customer the system is not allowing it and throws an exception of "Account is Required".
Module
accounts
Version
ERPNext: v14.20.3 (version-14) Frappe Framework: v14.31.0 (version-14) Frappe HR: v1.0.0 (develop) India Compliance: v14.5.2 (version-14)
Installation method
manual install
Relevant log output / Stack trace / Full Error Message.
Traceback (most recent call last):
File "apps/frappe/frappe/app.py", line 66, in application
response = frappe.api.handle()
File "apps/frappe/frappe/api.py", line 54, in handle
return frappe.handler.handle()
File "apps/frappe/frappe/handler.py", line 45, in handle
data = execute_cmd(cmd)
File "apps/frappe/frappe/handler.py", line 83, in execute_cmd
return frappe.call(method, **frappe.form_dict)
File "apps/frappe/frappe/__init__.py", line 1607, in call
return fn(*args, **newargs)
File "apps/frappe/frappe/desk/form/save.py", line 26, in savedocs
doc.save()
File "apps/frappe/frappe/model/document.py", line 305, in save
return self._save(*args, **kwargs)
File "apps/frappe/frappe/model/document.py", line 356, in _save
self.run_post_save_methods()
File "apps/frappe/frappe/model/document.py", line 1085, in run_post_save_methods
self.run_method("on_submit")
File "apps/frappe/frappe/model/document.py", line 914, in run_method
out = Document.hook(fn)(self, *args, **kwargs)
File "apps/frappe/frappe/model/document.py", line 1264, in composer
return composed(self, method, *args, **kwargs)
File "apps/frappe/frappe/model/document.py", line 1246, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File "apps/frappe/frappe/model/document.py", line 911, in fn
return method_object(*args, **kwargs)
File "apps/erpnext/erpnext/accounts/doctype/sales_invoice/sales_invoice.py", line 269, in on_submit
self.make_gl_entries()
File "apps/erpnext/erpnext/accounts/doctype/sales_invoice/sales_invoice.py", line 1037, in make_gl_entries
make_gl_entries(
File "apps/erpnext/erpnext/accounts/general_ledger.py", line 45, in make_gl_entries
save_entries(gl_map, adv_adj, update_outstanding, from_repost)
File "apps/erpnext/erpnext/accounts/general_ledger.py", line 305, in save_entries
make_entry(entry, adv_adj, update_outstanding, from_repost)
File "apps/erpnext/erpnext/accounts/general_ledger.py", line 316, in make_entry
gle.submit()
File "apps/frappe/frappe/model/document.py", line 1005, in submit
return self._submit()
File "apps/frappe/frappe/model/document.py", line 984, in _submit
return self.save()
File "apps/frappe/frappe/model/document.py", line 305, in save
return self._save(*args, **kwargs)
File "apps/frappe/frappe/model/document.py", line 327, in _save
return self.insert()
File "apps/frappe/frappe/model/document.py", line 259, in insert
self.run_before_save_methods()
File "apps/frappe/frappe/model/document.py", line 1048, in run_before_save_methods
self.run_method("validate")
File "apps/frappe/frappe/model/document.py", line 914, in run_method
out = Document.hook(fn)(self, *args, **kwargs)
File "apps/frappe/frappe/model/document.py", line 1264, in composer
return composed(self, method, *args, **kwargs)
File "apps/frappe/frappe/model/document.py", line 1246, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File "apps/frappe/frappe/model/document.py", line 911, in fn
return method_object(*args, **kwargs)
File "apps/erpnext/erpnext/accounts/doctype/gl_entry/gl_entry.py", line 46, in validate
self.check_mandatory()
File "apps/erpnext/erpnext/accounts/doctype/gl_entry/gl_entry.py", line 80, in check_mandatory
frappe.throw(_("{0} is required").format(_(self.meta.get_label(k))))
File "apps/frappe/frappe/__init__.py", line 525, in throw
msgprint(
File "apps/frappe/frappe/__init__.py", line 493, in msgprint
_raise_exception()
File "apps/frappe/frappe/__init__.py", line 442, in _raise_exception
raise raise_exception(msg)
frappe.exceptions.ValidationError: Account is required
This issue is appearing at Delivery Note also.
@umairsy is anyone working on this issue o/w i would like to work on this.
@adityanarayanm095 if the issue still persists, please feel free to work on it
@umairsy If this issue is still open , can I work on it ?