Discussion:
Pyenchant does *not* work for Windows 64-bit systems
Edward K. Ream
2018-02-05 12:40:26 UTC
Permalink
Contrary to a recent assertion, there seems to be no way to get pyenchant
working on Windows 64-bit systems.

See pyenchant issue 42, <https://github.com/rfk/pyenchant/issues/42> and a related
conda issue <https://github.com/conda-forge/staged-recipes/pull/3853>. It
looks like lots of people are unhappy about this, including me.

At present, I am using a 64-bit Anaconda3 system, with python2 and python3
environments. This complicates Leo's distribution problems considerably,
for several reasons:

1. I have no way of spell checking LeoDocs.leo! I suppose I could do the
checking on Linux...

2. I don't see any way of getting pyinstaller to create a distro that
includes pyenchant.

I suppose I could install an Anaconda/miniconda 32-bit system to solve #1.
That might also solve #2, but I'm thinking it may cause further problems
for Matt.

Any thoughts?

Edward
--
You received this message because you are subscribed to the Google Groups "leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+***@googlegroups.com.
To post to this group, send email to leo-***@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
Edward K. Ream
2018-02-05 13:19:55 UTC
Permalink
Post by Edward K. Ream
Contrary to a recent assertion, there seems to be no way to get pyenchant
working on Windows 64-bit systems.
I think it may be time to look at nltk <http://www.nltk.org/>, a natural
language tool kit for python.

This stack overflow question
<https://stackoverflow.com/questions/13928155/spell-checker-for-python>
asks how to create a spell checker based on nltk. The answer references this
page <http://norvig.com/spell-correct.html>. I think it may be time to
abandon pyenchant.

Edward
--
You received this message because you are subscribed to the Google Groups "leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+***@googlegroups.com.
To post to this group, send email to leo-***@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
Edward K. Ream
2018-02-05 13:27:25 UTC
Permalink
it may be time to look at nltk <http://www.nltk.org/>, a natural language
tool kit for python.

I have just created #700: create a spell checker based on nitk
<https://github.com/leo-editor/leo-editor/issues/700>. It has a 5.8
milestone, but it may happen for 5.7b2.

Edward
--
You received this message because you are subscribed to the Google Groups "leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+***@googlegroups.com.
To post to this group, send email to leo-***@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
lewis
2018-02-05 21:28:54 UTC
Permalink
Maybe that was me? I may have assumed the Win64 problems only affected
pyenchant 2.0

Lewis
Post by Edward K. Ream
Contrary to a recent assertion, there seems to be no way to get pyenchant
working on Windows 64-bit systems.
See pyenchant issue 42, <https://github.com/rfk/pyenchant/issues/42> and
a related conda issue
<https://github.com/conda-forge/staged-recipes/pull/3853>. It looks like
lots of people are unhappy about this, including me.
--
You received this message because you are subscribed to the Google Groups "leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+***@googlegroups.com.
To post to this group, send email to leo-***@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
Edward K. Ream
2018-02-05 22:46:39 UTC
Permalink
Post by lewis
Maybe that was me? I may have assumed the Win64 problems only affected
pyenchant
2.0
​Well, I really don't remember, and it doesn't matter :-)

Edward
--
You received this message because you are subscribed to the Google Groups "leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+***@googlegroups.com.
To post to this group, send email to leo-***@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
lewis
2018-02-08 00:18:16 UTC
Permalink
I had pyenchant 1.6.8 installed. I uninstalled it.

Leo fails to load with this error, when pyenchant is not installed:

N:\git\leo-editor>launchleo.py

reading settings in N:\git\leo-editor\leo\config\leoSettings.leo
reading settings in C:\Users\lewis\.leo\myLeoSettings.leo
Empty setting name in False
set parent @settings

Leo 5.7b1, build 20180205170654, Mon Feb 5 17:06:54 CST 2018
Git repo info: branch = master, commit = c8e13c3bccdc
Python 3.6.4, PyQt version 5.10.0
Windows 10 AMD64 (build 10.0.16299) SP0
** isPython3: True
** caching enabled

reading settings in C:\Users\lewis\.leo\workbook.leo
Traceback (most recent call last):
File "N:\git\leo-editor\launchLeo.py", line 8, in <module>
leo.core.runLeo.run()
File "N:\git\leo-editor\leo\core\runLeo.py", line 74, in run
g.app.loadManager.load(fileName, pymacs)
File "N:\git\leo-editor\leo\core\leoApp.py", line 2204, in load
ok = lm.doPostPluginsInit()
File "N:\git\leo-editor\leo\core\leoApp.py", line 2836, in
doPostPluginsInit
c1 = lm.openEmptyWorkBook()
File "N:\git\leo-editor\leo\core\leoApp.py", line 2897, in
openEmptyWorkBook
c = lm.loadLocalFile(fn, gui=g.app.gui, old_c=None)
File "N:\git\leo-editor\leo\core\leoApp.py", line 3062, in loadLocalFile
c = lm.openFileByName(fn, gui, old_c, previousSettings)
File "N:\git\leo-editor\leo\core\leoApp.py", line 3086, in openFileByName
previousSettings=previousSettings)
File "N:\git\leo-editor\leo\core\leoApp.py", line 1543, in newCommander
return leoCommands.Commands(fileName, relativeFileName, gui,
previousSettings)
File "N:\git\leo-editor\leo\core\leoCommands.py", line 82, in __init__
c.finishCreate()
File "N:\git\leo-editor\leo\core\leoCommands.py", line 415, in
finishCreate
c.frame.log.finishCreate()
File "N:\git\leo-editor\leo\plugins\qt_frame.py", line 3146, in
finishCreate
c.spellCommands.openSpellTab()
File "N:\git\leo-editor\leo\commands\spellCommands.py", line 173, in
openSpellTab
self.handler = SpellTabHandler(c, tabName)
File "N:\git\leo-editor\leo\commands\spellCommands.py", line 414, in
__init__
self.spellController = EnchantClass(c)
File "N:\git\leo-editor\leo\commands\spellCommands.py", line 32, in
__init__
if language and not enchant.dict_exists(language):
AttributeError: module 'enchant' has no attribute 'dict_exists'

I changed to default leoSettings.leo to eliminate any personal settings,
but Leo still did not load unless pyenchant was installed.

Regards
Lewis
--
You received this message because you are subscribed to the Google Groups "leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+***@googlegroups.com.
To post to this group, send email to leo-***@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
Edward K. Ream
2018-02-08 09:46:19 UTC
Permalink
Post by lewis
I had pyenchant 1.6.8 installed. I uninstalled it.
​Thanks for this report. I have created #707
<https://github.com/leo-editor/leo-editor/issues/707> for this.​

​I'll fix it immediately.

Imo you did right by reporting this issue in leo-editor. Everyone should
know about it.

Edward
--
You received this message because you are subscribed to the Google Groups "leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+***@googlegroups.com.
To post to this group, send email to leo-***@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
lewis
2018-02-09 22:15:06 UTC
Permalink
Latest commit is not loading Leo for me. It's not a complete crash; I have
a Leo splash screen but nothing after that


Leo 5.7b1, build 20180209145139, Fri Feb 9 14:51:39 CST 2018
Git repo info: branch = master, commit = ddb87d916eb3
Python 3.6.4, PyQt version 5.10.0
Windows 10 AMD64 (build 10.0.16299) SP0
** isPython3: True
** caching enabled

reading settings in C:\Users\lewis\.leo\workbook.leo
created: C:\Users\lewis\.leo\spellpyx.txt
Traceback (most recent call last):
File "N:\git\leo-editor\launchLeo.py", line 8, in <module>
leo.core.runLeo.run()
File "N:\git\leo-editor\leo\core\runLeo.py", line 74, in run
g.app.loadManager.load(fileName, pymacs)
File "N:\git\leo-editor\leo\core\leoApp.py", line 2206, in load
ok = lm.doPostPluginsInit()
File "N:\git\leo-editor\leo\core\leoApp.py", line 2838, in
doPostPluginsInit
c1 = lm.openEmptyWorkBook()
File "N:\git\leo-editor\leo\core\leoApp.py", line 2899, in
openEmptyWorkBook
c = lm.loadLocalFile(fn, gui=g.app.gui, old_c=None)
File "N:\git\leo-editor\leo\core\leoApp.py", line 3064, in loadLocalFile
c = lm.openFileByName(fn, gui, old_c, previousSettings)
File "N:\git\leo-editor\leo\core\leoApp.py", line 3088, in openFileByName
previousSettings=previousSettings)
File "N:\git\leo-editor\leo\core\leoApp.py", line 1545, in newCommander
return leoCommands.Commands(fileName, relativeFileName, gui,
previousSettings)
File "N:\git\leo-editor\leo\core\leoCommands.py", line 82, in __init__
c.finishCreate()
File "N:\git\leo-editor\leo\core\leoCommands.py", line 415, in
finishCreate
c.frame.log.finishCreate()
File "N:\git\leo-editor\leo\plugins\qt_frame.py", line 3146, in
finishCreate
c.spellCommands.openSpellTab()
File "N:\git\leo-editor\leo\commands\spellCommands.py", line 463, in
openSpellTab
self.handler = SpellTabHandler(c, tabName)
File "N:\git\leo-editor\leo\commands\spellCommands.py", line 707, in
__init__
self.spellController = DefaultWrapper(c)
File "N:\git\leo-editor\leo\commands\spellCommands.py", line 238, in
__init__
words = self.read_words(kind, fn)
File "N:\git\leo-editor\leo\commands\spellCommands.py", line 251, in
read_words
with open(fn, 'rb') as f:
TypeError: expected str, bytes or os.PathLike object, not NoneType

Regards
Lewis
--
You received this message because you are subscribed to the Google Groups "leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+***@googlegroups.com.
To post to this group, send email to leo-***@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
Edward K. Ream
2018-02-09 22:49:05 UTC
Permalink
Post by lewis
Latest commit is not loading Leo for me.
File "N:\git\leo-editor\leo\commands\spellCommands.py", line 251, in
read_words
with open(fn, 'rb') as f:
TypeError: expected str, bytes or os.PathLike object, not NoneType

​Try fc5567a. The new code catches all exceptions when trying to load ​a
dict.

Edward
Post by lewis
Regards
Lewis
--
You received this message because you are subscribed to the Google Groups
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
--
------------------------------------------------------------------------------------------
Edward K. Ream: ***@gmail.com Leo: http://leoeditor.com/
------------------------------------------------------------------------------------------
--
You received this message because you are subscribed to the Google Groups "leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+***@googlegroups.com.
To post to this group, send email to leo-***@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.
Loading...