Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

PyEnchant

Programming languages, Coding, Executables, Package Creation, and Scripting.
Post Reply
Message
Author
Lavene
Site admin
Site admin
Posts: 4958
Joined: 2006-01-04 04:26
Location: Oslo, Norway

PyEnchant

#1 Post by Lavene »

I'm trying to use the Enchant spellchecker library for Python (python2.4-enchant). But I can only make it work together with 'aspell', but I really would like to use 'myspell' instead. Any idea how to do that?

My testcode:

Code: Select all

import enchant

dictionary = enchant.Dict('en')
word = (raw_input("Please enter word to check: "))

if dictionary.check(word):
    print "Correct"
else:
    print dictionary.suggest(word)
Thanks
Tina :)

User avatar
osmo
Posts: 55
Joined: 2006-03-15 14:40
Location: Finland

#2 Post by osmo »

The "Provider Ordering" section of the PyEnchant tutorial is quite helpful and clear. However, it doesn't seem to work; maybe there's a bug?

Lavene
Site admin
Site admin
Posts: 4958
Joined: 2006-01-04 04:26
Location: Oslo, Norway

#3 Post by Lavene »

osmo wrote:The "Provider Ordering" section of the PyEnchant tutorial is quite helpful and clear. However, it doesn't seem to work; maybe there's a bug?
Yes, it seems like I've hit a bug in the 2.4 build. Just for the heck of it I tried python2.3/ python2.3-enchant and it works flawlessly with myspell.

There's no open bugs on it though, so I'll investigate it some more and file a bug report if I can't find the problem.

Tina

Post Reply