From 6bd9f7f5f0d7eb7b703abb7f8614efe750647cdf Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Mon, 8 Feb 2016 12:08:32 +0530 Subject: [PATCH] [minor] catch duplicate entry error in bank account creation --- erpnext/setup/setup_wizard/setup_wizard.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/erpnext/setup/setup_wizard/setup_wizard.py b/erpnext/setup/setup_wizard/setup_wizard.py index b92dcf98a7e..bd2d04d8f02 100644 --- a/erpnext/setup/setup_wizard/setup_wizard.py +++ b/erpnext/setup/setup_wizard/setup_wizard.py @@ -129,6 +129,9 @@ def create_bank_account(args): return bank_account.insert() except RootNotEditable: frappe.throw(_("Bank account cannot be named as {0}").format(args.get("bank_account"))) + except frappe.DuplicateEntryError: + # bank account same as a CoA entry + pass def create_price_lists(args): for pl_type, pl_name in (("Selling", _("Standard Selling")), ("Buying", _("Standard Buying"))):