Fiscal year error

While making fiscal year 2017-18 as default financial year, I am getting following error. Can anyone help me what this error is for.

Traceback (innermost last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/app.py”, line 57, in application
response = frappe.handler.handle()
File “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”, line 19, in handle
execute_cmd(cmd)
File “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”, line 36, in execute_cmd
ret = frappe.call(method, **frappe.form_dict)
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 805, in call
return fn(*args, **newargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”, line 67, in runserverobj
frappe.desk.form.run_method.runserverobj(method, docs=docs, dt=dt, dn=dn, arg=arg, args=args)
File “/home/frappe/frappe-bench/apps/frappe/frappe/desk/form/run_method.py”, line 35, in runserverobj
r = doc.run_method(method)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 579, in run_method
return Document.hook(fn)(self, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 735, in composer
return composed(self, method, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 718, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 573, in
fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/accounts/doctype/fiscal_year/fiscal_year.py”, line 15, in set_as_default
frappe.get_doc(“Global Defaults”).on_update()
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/setup/doctype/global_defaults/global_defaults.py”, line 47, in on_update
self.toggle_rounded_total()
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/setup/doctype/global_defaults/global_defaults.py”, line 61, in toggle_rounded_total
make_property_setter(doctype, “base_rounded_total”, “hidden”, self.disable_rounded_total, “Check”)
File “/home/frappe/frappe-bench/apps/frappe/frappe/custom/doctype/property_setter/property_setter.py”, line 66, in make_property_setter
“property_type”: property_type
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 533, in get_doc
return frappe.model.document.get_doc(arg1, arg2)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 44, in get_doc
controller = get_controller(doctype)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/base_document.py”, line 30, in get_controller
module = load_doctype_module(doctype, module_name)
File “/home/frappe/frappe-bench/apps/frappe/frappe/modules/init.py”, line 64, in load_doctype_module
doctype_python_modules[key] = frappe.get_module(get_module_name(doctype, module, prefix))
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 598, in get_module
return importlib.import_module(modulename)
File “/usr/lib/python2.7/importlib/init.py”, line 37, in import_module
import(name)
ImportError: No module named property_setter.property_setter

Can’t replicate the issue.

To debug, you can try following:

  1. Go to bench console
  2. Try to import property_setter module using import frappe.custom.doctype.property_setter.property_setter
  3. Let us know the output
1 Like

Thanks Nabin,
It gives following error:
“import.im6: unable to open X server `’@ error/import.c/importimagecommad/368”

Provide full traceback.

As u said to import property_setter, I have tried the same and got got the above error.

Are you importing from python console?

Not sure, I just login to the server then i go to frappe bench directory and run the command.
Is there anything that i have to do?

Yes, first you to go to frappe-bench directory. Then run the command bench --site <your-site-name> console to open the python console, you need to pass your own site name here.
Then run import frappe.custom.doctype.property_setter.property_setter