我正在尝试在我的数据库中添加一个新模块。我遇到了这个我无法解决的问题。我的init .py 的代码是:
from trytond.pool import Pool
from grh.Employe import *
def register():
Pool.register(
Employe,
module='grh', type_='model')
尝试后的问题是:
File "/usr/local/bin/trytond", line 5, in <module>
pkg_resources.run_script('trytond==3.2.2', 'trytond')
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 528, in run_script
self.require(requires)[0].run_script(script_name, ns)
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1394, in run_script
execfile(script_filename, namespace, namespace)
File "/usr/local/lib/python2.7/dist-packages/trytond-3.2.2-py2.7.egg/EGG-INFO/scripts/trytond", line 113, in <module>
trytond.server.TrytonServer(options).run()
File "/usr/local/lib/python2.7/dist-packages/trytond-3.2.2-py2.7.egg/trytond/server.py", line 123, in run
Pool(db_name).init(update=update, lang=lang)
File "/usr/local/lib/python2.7/dist-packages/trytond-3.2.2-py2.7.egg/trytond/pool.py", line 151, in init
lang=lang)
File "/usr/local/lib/python2.7/dist-packages/trytond-3.2.2-py2.7.egg/trytond/modules/__init__.py", line 428, in load_modules
_load_modules()
File "/usr/local/lib/python2.7/dist-packages/trytond-3.2.2-py2.7.egg/trytond/modules/__init__.py", line 393, in _load_modules
graph = create_graph(module_list)[0]
File "/usr/local/lib/python2.7/dist-packages/trytond-3.2.2-py2.7.egg/trytond/modules/__init__.py", line 159, in create_graph
raise Exception('Module %s not found' % module)
请帮帮我