Search code examples
pythonwindowspyenchant

PyEnchant raises WinError 193 on import, using Python 3.3.4


PyEnchant throws an error when I try to import it. I've installed and uninstalled it using both pip and the exe they provide on their site.

Just an example using Python through Command Prompt:

    >>> import enchant
    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      File "C:\Python33\lib\site-packages\enchant\__init__.py", line 92, in <module>

        from enchant import _enchant as _e
      File "C:\Python33\lib\site-packages\enchant\_enchant.py", line 102, in <module>
        raise WinError()
    OSError: [WinError 193] <no description>

Solution

  • The reason for this is that the PyEnchant package includes a library which is complied for the 32-bit version of Python. When run under the 64-bit version of python it throws the above error.

    I switched to using Python 32-bit and had no problem.

    Source: https://groups.google.com/forum/#!topic/pyenchant-users/5cCFthWE9ZM