py2app和pyEnchant怎么了?

2024-03-28 17:58:40 发布

您现在位置:Python中文网/ 问答频道 /正文

PyEnchant包含在站点中-软件包.zip捆绑,但它不能加载任何dict!为什么不?我总是遇到“dict not found”错误。但字典在现场-packages.zip/enchant/share/enchant/myspell/.. 怎么回事?在

    2012-03-01 14:24:42,469     EXCEPTION:
    2012-03-01 14:24:42,469         EXCEPTION TYPE: <class 'enchant.errors.DictNotFoundError'> EXCEPTION VALUE: Dictionary for language 'ru_RU' could not be found
    2012-03-01 14:24:42,469              TRACEBACK: ('/Users/dima/dev/up/up/consultant/client/dist/main.app/Contents/Resources/__boot__.py', 39, '<module>', None)
    2012-03-01 14:24:42,469              TRACEBACK: ('/Users/dima/dev/up/up/consultant/client/dist/main.app/Contents/Resources/__boot__.py', 36, '_run', None)
    2012-03-01 14:24:42,469              TRACEBACK: ('/Users/dima/dev/up/up/consultant/client/dist/main.app/Contents/Resources/main.py', 26, '<module>', None)
    2012-03-01 14:24:42,469              TRACEBACK: ('spell_check_text_edit.pyc', 21, '__init__', None)
    2012-03-01 14:24:42,470              TRACEBACK: ('enchant/__init__.pyc', 502, '__init__', None)
    2012-03-01 14:24:42,470              TRACEBACK: ('enchant/__init__.pyc', 264, '_request_dict_data', None)
    2012-03-01 14:24:42,470              TRACEBACK: ('enchant/__init__.pyc', 218, '_raise_error', None)

Tags: devclientnoneinitmaindistexceptionusers
2条回答

您是否尝试从ftp://ftp.gnu.org/gnu/aspell/dict/0index.html安装Aspell和dictionary?
要安装dict,只需下载ftp://ftp.gnu.org/gnu/aspell/dict/ru/aspell6-ru-0.99f7-1.tar.bz2,解压它并

./configure && make && make install

pyEnchant是zip文件时不起作用,请尝试:

$ python setup.py py2app packages=enchant

这将告诉py2app在站点之外包含附魔包-软件包.zip. 在

相关问题 更多 >