【问题标题】:Ubuntu ; Python3 - Textract installation - Codec error with Ebooklib & pocketsphinx乌班图; Python3 - Textract 安装 - Ebooklib 和 pocketsphinx 的编解码器错误
【发布时间】:2018-08-12 11:49:42
【问题描述】:

Ubuntu 16.04 - Python 3.6

收到此错误后:

textract Command "python setup.py egg_info" failed with error code 1 in 
/tmp/pip-build-xxxx/EbookLib/

带有消息:

UnicodeDecodeError: 'charmap' codec can't decode byte 0x8d in position 
1671: character maps to <undefined>

可以使用最新版本的 textract 解决:

pip install git+git://github.com/deanmalmgren/textract.git@master

linkpmahend1第一条评论

我在使用 pocketsphinx 时遇到了同样的问题。

Command "python setup.py egg_info" failed with error code 1 in 
/tmp/pip-build-xxxx/pocketsphinx/

消息编解码器错误指向 setup.py 文件的第 189 行。

有人遇到过同样的问题吗?你是怎么解决的?

【问题讨论】:

    标签: python python-3.x ubuntu-16.04 packages codec


    【解决方案1】:

    我做了以下,它似乎工作:

    下载 Pocketsphinx-0.1.3

    wget "https://files.pythonhosted.org/packages/93/5f/a968e5d53d25e32deb78c3e169fd8612ecf53cc76e32cb40e19be3"
    

    提取 Pocketsphinx-0.1.3

    tar -jxvf pocketsphinx-0.1.3.tar.bz2
    

    更改 Pocketsphinx-0.1.3 setup.py

    cd pocketsphinx-0.1.3
    nano setup.py
    

    => 将第 189 行更改为在 READ.rst 之后添加 , encoding="utf-8")

    安装 Pocketsphinx-0.1.3

    pip3 install .
    sudo python3.6 setup.py install
    

    下载文本

    git clone git://github.com/deanmalmgren/textract.git
    nano textract/requirements/python
    

    评论 pocketsphinx==0.1.3 行

    安装文本

    pip3 install . 
    

    (在包含 setup.py 的文件夹中)

    【讨论】:

      猜你喜欢
      • 2019-03-02
      • 1970-01-01
      • 2017-12-22
      • 2013-07-29
      • 2017-08-23
      • 2014-08-11
      • 1970-01-01
      • 2016-03-01
      • 1970-01-01
      相关资源
      最近更新 更多