enabling plugings in myLeoSettings.leo

25 views
Skip to first unread message

The Living Cosmos

unread,
Oct 4, 2019, 1:08:40 PM10/4/19
to leo-editor
Hello, HOME/.leo/myLeoSettings.leo I attempted to enable the OPML plugin as follows:

@enabled-plugins
leoOPML.py

But when starting Leo I get the following errors:
Qt: Untested Windows version 10.0 detected!

reading settings in C:\LEO_5~1.7_F\LeoApp\leo\config\leoSettings.leo
reading settings in C:\Users\terre\.leo\myLeoSettings.leo
error parsing C:\Users\terre\.leo\myLeoSettings.leo
Traceback (most recent call last):

  File "leo\core\leoFileCommands.py", line 1401, in parse_leo_file
    parser.parse(theFile) # expat does not support parseString

  File "xml\sax\expatreader.py", line 111, in parse

  File "xml\sax\xmlreader.py", line 123, in parse

  File "xml\sax\expatreader.py", line 224, in feed

  File "xml\sax\handler.py", line 38, in fatalError

SAXParseException: <unknown>:1:0: not well-formed (invalid token)


Note: sys.stdout.encoding is not UTF-8

Leo 5.7 final, build 20180227091711, Tue Feb 27 09:17:11 CST 2018
Not running from a git repo
Python 2.7.14, PyQt version 4.8.6
Windows 10 AMD64 (build 10.0.18362) SP0

The Living Cosmos

unread,
Oct 4, 2019, 1:15:08 PM10/4/19
to leo-editor
I've handled this. All you need to do is open Leo Editor and navigate to Settings -> myLeoSettings.leo and then uncomment leoOPML.py and save and restart Leo Editor.

Edward K. Ream

unread,
Oct 4, 2019, 1:22:14 PM10/4/19
to leo-editor
On Fri, Oct 4, 2019 at 12:08 PM The Living Cosmos <thequie...@gmail.com> wrote:
Hello, HOME/.leo/myLeoSettings.leo I attempted to enable the OPML plugin as follows:

@enabled-plugins
leoOPML.py

But when starting Leo I get the following errors:
Qt: Untested Windows version 10.0 detected!

reading settings in C:\LEO_5~1.7_F\LeoApp\leo\config\leoSettings.leo
reading settings in C:\Users\terre\.leo\myLeoSettings.leo
error parsing C:\Users\terre\.leo\myLeoSettings.leo
Traceback (most recent call last):

  File "leo\core\leoFileCommands.py", line 1401, in parse_leo_file
    parser.parse(theFile) # expat does not support parseString

  File "xml\sax\expatreader.py", line 111, in parse

  File "xml\sax\xmlreader.py", line 123, in parse

  File "xml\sax\expatreader.py", line 224, in feed

  File "xml\sax\handler.py", line 38, in fatalError

SAXParseException: <unknown>:1:0: not well-formed (invalid token)


Note: sys.stdout.encoding is not UTF-8

I suggest putting the following in python/lib/sitecustomize.py:

import sys
sys.stdout.reconfigure(encoding='utf-8')

HTH.
Edward
Reply all
Reply to author
Forward
0 new messages