I am still really busy, but I poked at the shadow nodes today while setting
up a new project. I think the cloning is caused be a user mistake, but it is
still odd behavior that should be warned about. In this case I could cause
the problem when I purposely set the @path of two trees to the same
directory. I then copied an @shadow file from one tree to the other (imagine
you want to test a module without messing with sys.path). No errors or
warnings are printed when saving, but the tree has strange clones when it is
closed and reopened (causing @shadow read?).

There are two problems here, a strange behavior without warning, and a bug
in shadow read/write. It is fairly obviously pathological to write the same
file to the same place twice, but it is easy to miss if you use relative
@path directives or are forgetful. The second problem is that Leo handles
this error silently and either writes bad data into the .shadow directory,
or makes an error while reading the shadow data into the outline. I've
attached a picture to show the problem - Leo creates a cloned @shadow node
below the old @shadow.

I don't know if it is necessarily wrong to try and automatically transform
duplicate objects into clones? I think if Leo would issue warnings it would
become a non-issue though.

Ed Blake
On Wed, Nov 12, 2008 at 2:08 PM, Edward K. Ream <[EMAIL PROTECTED]> wrote:

>
> On Wed, Nov 12, 2008 at 10:48 AM, Ed Blake <[EMAIL PROTECTED]> wrote:
>
> > Any more info on the magical cloning? That problem is the primary reason
> I  stopped using @shadow.
>
> Are you the only one who has reported this problem?
>
> Can you isolate the problem to small files and/or easily repeatable steps?
>
> Edward
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

<<inline: screenshot.jpg>>

Reply via email to