On Error Snapshot shows No module Desk

Dear All,
I have been having this error and don’t know what the couse … this has been repeating on the Error Snapshot (23xxxx times) which i believe is making the system slower.

Error Report

Python 2.7.6: /home/frappe/frappe-bench/env/bin/python (prefix: /home/frappe/frappe-bench/env)

Timestamp:
2017-01-16 13:43:45.377789
Relapsed
24126
Exception

args (‘No module named desk’,)
message ‘No module named desk’
Locals

name u’frappe.templates.pages.desk’
package None
Traceback

/home/frappe/frappe-bench/apps/frappe/frappe/app.py: 60

58 if frappe.local.form_dict.data is None:
59 frappe.local.form_dict.data = request.get_data()
60 response = frappe.api.handle()
61
62 elif frappe.request.path.startswith(’/backups’):
Locals
/home/frappe/frappe-bench/apps/frappe/frappe/api.py: 54

52 if call==“method”:
53 frappe.local.form_dict.cmd = doctype
54 return frappe.handler.handle()
55
56 elif call==“resource”:
Locals
/home/frappe/frappe-bench/apps/frappe/frappe/handler.py: 19

17
18 if cmd!=‘login’:
19 execute_cmd(cmd)
20
21 return build_response(“json”)
Locals
/home/frappe/frappe-bench/apps/frappe/frappe/handler.py: 30

28 break
29
30 method = get_attr(cmd)
31 if from_async:
32 method = method.queue
Locals
/home/frappe/frappe-bench/apps/frappe/frappe/handler.py: 114

112 “”“get method object from cmd”""
113 if ‘.’ in cmd:
114 method = frappe.get_attr(cmd)
115 else:
116 method = globals()[cmd]
Locals
/home/frappe/frappe-bench/apps/frappe/frappe/init.py: 870

868 modulename = ‘.’.join(method_string.split(’.’)[:-1])
869 methodname = method_string.split(’.’)[-1]
870 return getattr(get_module(modulename), methodname)
871
872 def call(fn, *args, **kwargs):
Locals
/home/frappe/frappe-bench/apps/frappe/frappe/init.py: 654

652 def get_module(modulename):
653 “”“Returns a module object for given Python module name using importlib.import_module.”""
654 return importlib.import_module(modulename)
655
656 def scrub(txt):
Locals
/usr/lib/python2.7/importlib/init.py: 37

34 break
35 level += 1
36 name = _resolve_name(name[level:], package, level)
37 import(name)
38 return sys.modules[name]

Can you please provide steps to replicate this error?

Unfortunately i cannot replicate as this is shown under Setting on the
Error Snapshot and the only thing i can send is this log from the DB it
self.

| 00002661b1 | 2017-01-25 21:17:43.327597 | 2017-01-25 21:17:43.327597 |
Administrator | Administrator | 0 | NULL | NULL | NULL
| 0 | {
“args”: “(‘No module named desk’,)”,
“message”: “‘No module named desk’”
} | NULL | 2017-01-03 23:34:13.716561 | ImportError(‘No module named
desk’,) | Traceback (most recent call last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/app.py”, line 60, in
application
response = frappe.api.handle()
File “/home/frappe/frappe-bench/apps/frappe/frappe/api.py”, line 54, in
handle
return 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 30,
in execute_cmd
method = get_attr(cmd)
File “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”, line 114,
in get_attr
method = frappe.get_attr(cmd)
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line
870, in get_attr
return getattr(get_module(modulename), methodname)
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line
654, 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 desk
| 186c04bb3a | Python 2.7.6:
/home/frappe/frappe-bench/env/bin/python (prefix:
/home/frappe/frappe-bench/env) | NULL | NULL | <type
‘exceptions.importerror’=""> | [
{
“call”: “(request=<Request ’
http://41.205.61.168/api/method/frappe...t_desk_assets?build_version=1480979219.84
[GET]>)”,
“dump”: {
“frappe. api”: “<module ‘frappe.api’ from
‘/home/frappe/frappe-bench/apps/frappe/frappe/api.pyc’>”,
“frappe.api. handle”: “”,
“global frappe”: “<module ‘frappe’ from
‘/home/frappe/frappe-bench/apps/frappe/frappe/init.pyc’>”,
“response”: “None”
},
“file”: “/home/frappe/frappe-bench/apps/frappe/frappe/app.py”,
“func”: “application”,
“lines”: {
“58”: " \tif frappe.local.form_dict.data is None:",
“59”: " \tfrappe.local.form_dict.data =
request.get_data()",
“60”: “\t\t\tresponse = frappe.api.handle()”,
“61”: “”,
“62”: “\t\telif frappe.request.path.startswith(’/backups’):”
},
“lnum”: 60
},
{
“call”: “()”,
“dump”: {
“frappe. handler”: “<module ‘frappe.handler’ from
‘/home/frappe/frappe-bench/apps/frappe/frappe/handler.pyc’>”,
“frappe.handler. handle”: “”,
“global frappe”: “<module ‘frappe’ from
‘/home/frappe/frappe-bench/apps/frappe/frappe/init.pyc’>”
},
“file”: “/home/frappe/frappe-bench/apps/frappe/frappe/api.py”,
“func”: “handle”,
“lines”: {
“52”: “\tif call==“method”:”,
“53”: “\t\tfrappe.local.form_dict.cmd = doctype”,
“54”: “\t\treturn frappe.handler.handle()”,
“55”: “”,
“56”: “\telif call==“resource”:”
},
“lnum”: 54
},
{
“call”: “()”,
“dump”: {
“cmd”: “u’frappe.templates.pages.desk.get_desk_assets’”,
“global execute_cmd”: “”
},
“file”: “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”,
“func”: “handle”,
“lines”: {
“17”: “”,
“18”: “\tif cmd!=‘login’:”,
“19”: “\t\texecute_cmd(cmd)”,
“20”: “”,
“21”: “\treturn build_response(“json”)”
},
“lnum”: 19
},
{
“call”: “(cmd=u’frappe.templates.pages.desk.get_desk_assets’,
from_async=False)”,
“dump”: {
“cmd”: “u’frappe.templates.pages.desk.get_desk_assets’”,
“global get_attr”: “”,
“method”: “undefined”
},
“file”: “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”,
“func”: “execute_cmd”,
“lines”: {
“28”: “\t\tbreak”,
“29”: “”,
“30”: “\tmethod = get_attr(cmd)”,
“31”: “\tif from_async:”,
“32”: “\t\tmethod = method.queue”
},
“lnum”: 30
},
{
“call”: “(cmd=u’frappe.templates.pages.desk.get_desk_assets’)”,
“dump”: {
“cmd”: “u’frappe.templates.pages.desk.get_desk_assets’”,
“frappe. get_attr”: “”,
“global frappe”: “<module ‘frappe’ from
‘/home/frappe/frappe-bench/apps/frappe/frappe/init.pyc’>”,
“method”: “undefined”
},
“file”: “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”,
“func”: “get_attr”,
“lines”: {
“112”: “\t”"“get method object from cmd”""",
“113”: “\tif ‘.’ in cmd:”,
“114”: “\t\tmethod = frappe.get_attr(cmd)”,
“115”: “\telse:”,
“116”: “\t\tmethod = globals()[cmd]”
},
“lnum”: 114
},
{
“call”: “(method_string=u’frappe.templates.pages.desk.get_desk_assets’)”,
“dump”: {
“builtin getattr”: “”,
“global get_module”: “”,
“methodname”: “u’get_desk_assets’”,
“modulename”: “u’frappe.templates.pages.desk’”
},
“file”: “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”,
“func”: “get_attr”,
“lines”: {
“868”: “\tmodulename = ‘.’.join(method_string.split(’.’)[:-1])”,
“869”: “\tmethodname = method_string.split(’.’)[-1]”,
“870”: “\treturn getattr(get_module(modulename), methodname)”,
“871”: “”,
“872”: “def call(fn, *args, **kwargs):”
},
“lnum”: 870
},
{
“call”: “(modulename=u’frappe.templates.pages.desk’)”,
“dump”: {
“global importlib”: “<module ‘importlib’ from
‘/usr/lib/python2.7/importlib/init.pyc’>”,
“importlib. import_module”: “”,
“modulename”: “u’frappe.templates.pages.desk’”
},
“file”: “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”,
“func”: “get_module”,
“lines”: {
“652”: “def get_module(modulename):”,
“653”: “\t”"“Returns a module object for given Python module name
using importlib.import_module.”""",
“654”: “\treturn importlib.import_module(modulename)”,
“655”: “”,
“656”: “def scrub(txt):”
},
“lnum”: 654
},
{
“call”: “(name=u’frappe.templates.pages.desk’, package=None)”,
“dump”: {
“builtin import”: “”,
“name”: “u’frappe.templates.pages.desk’”
},
“file”: “/usr/lib/python2.7/importlib/init.py”,
“func”: “import_module”,
“lines”: {
“34”: " break",
“35”: " level += 1",
“36”: " name = _resolve_name(name[level:], package, level)",
“37”: " import(name)",
“38”: " return sys.modules[name]"
},
“lnum”: 37
}
] | 0 | NULL | 1 | {
“name”: “u’frappe.templates.pages.desk’”,
“package”: “None”