Hi Todd,
I received all 3 of your messages, so, coming through loud and clear. :)
I think there are one or more files in your project structure which Leo's
parser is stumbling on, after creating the outline hierarchy and before
populating the contents. Try drag'n'drop files from your file manager into
Leo's outline pane in groups of 10 (or whatever) until you localise which
one(s) are problematic.
I get the same results: the structure is created but the @auto nodes are
empty.
I then ran "File > Read/Write > Read @auto nodes", and got errors of type
"not found: @auto
B:\apps\leo-editor\leo\core\AliasFeatureclassConversion.py" for every file.
These weren't reported before, and the path is wrong. They should be "@auto
b:\code\maphew\gis\...".
I changed back to full path, `theDir = r'b:\code\maphew\gis'`, then re-ran
the script, got the same empty nodes, then "Read @auto nodes". This time
the first 7 files were read, the node structure and body contents populated
as expected, and then it stopped with an error:
{{{
reading: @auto gdal_vrtmerge.py
Error: intermixed blanks and tabs
exception executing command
Traceback (most recent call last):
File "B:\apps\leo-editor\leo\core\leoCommands.py", line 561, in doCommand
val = command(event)
File "B:\apps\leo-editor\leo\core\leoCommands.py", line 1930, in
readAtAutoNodes
c.importCommands.readAtAutoNodes()
File "B:\apps\leo-editor\leo\core\leoImport.py", line 934, in
readAtAutoNodes
c.atFileCommands.readOneAtAutoNode(fileName,p)
File "B:\apps\leo-editor\leo\core\leoAtFile.py", line 857, in
readOneAtAutoNode
ic.createOutline(fileName,parent=p.copy(),atAuto=True)
File "B:\apps\leo-editor\leo\core\leoImport.py", line 904, in
createOutline
func(s,p,atAuto=atAuto)
File "B:\apps\leo-editor\leo\core\leoImport.py", line 1565, in
scanPythonText
scanner.run(s,parent)
File "B:\apps\leo-editor\leo\core\leoImport.py", line 3364, in run
if self.strict: s = self.regularizeWhitespace(s)
File "B:\apps\leo-editor\leo\core\leoImport.py", line 3427, in
regularizeWhitespace
self.report(message)
File "B:\apps\leo-editor\leo\core\leoImport.py", line 2681, in report
if self.strict: self.error(message)
File "B:\apps\leo-editor\leo\core\leoImport.py", line 2675, in error
g.error('Error:',s)
File "B:\apps\leo-editor\leo\core\leoGlobals.py", line 2636, in error
g.es_print(color=g.actualColor('red'),*args,**keys)
File "B:\apps\leo-editor\leo\core\leoGlobals.py", line 2714, in es_print
g.pr(*args,**keys)
File "B:\apps\leo-editor\leo\core\leoGlobals.py", line 2850, in pr
sys.stdout.write(s2)
IOError: [Errno 9] Bad file descriptor
}}}
There might be more going on with this file, because Leo normally says
something like "Error: intermixed blanks and tabs. Inserting @ignore" and
carries on. In any case I fixed that file and then "Read @auto nodes" on
the "import fies" tree worked (albeit complaining about mixed tabs and
spaces in other files too).
These files are also at
http://code.google.com/p/maphew/source/browse/gis/for anyone who wants
to dig further. I'll leave them unchanged for awhile.
cheers,
-matt
--
You received this message because you are subscribed to the Google Groups
"leo-editor" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/leo-editor?hl=en.