On Friday, April 22, 2016 at 10:23:57 AM UTC-5, Edward K. Ream wrote:
>
>
> On Tuesday, April 19, 2016 at 9:23:20 AM UTC-5, Terry Brown wrote:
>
> > there's a bug in c.db, when you create and save a new file, c.db in that 
> file gives a key error 
>
> When does that happen? I doesn't happen on save, or when using the 
> Easter-egg interface. 
>

Attempting to answer my own question, I did a cff on ".db".

The only code that didn't use db.get (and thus could raise a KeyError) was 
this, in  free_layout_load:

layout = g.app.db['ns_layouts'][name]

Probably should be this instead:

layouts = g.app.db.get('ns_layouts', {})
layout = layouts.get(name)
if layout:
    c.free_layout.get_top_splitter().load_layout(layout)

What do you think, Terry?

EKR

-- 
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.

Reply via email to