OMG: Leo's reload-settings machinery can be greatly simplified!

19 views
Skip to first unread message

Edward K. Ream

unread,
Apr 2, 2026, 9:37:05 AM (5 days ago) Apr 2
to leo-editor
PR #4582 adds an entry in a table in the c.reloadConfigurable method. This table is evil: it must somehow stay in sync with all classes in Leo's codebase.

I created #4583 to address the ugliness and went to bed :-)

But before I went to sleep, I realized that none of Leo's existing reload-settings machinery is necessary. Leo's two configuration classes can do all the work!

See  #4583 for the details. Hurray!

Edward

Edward K. Ream

unread,
Apr 2, 2026, 11:30:08 AM (5 days ago) Apr 2
to leo-editor
On Thursday, April 2, 2026 at 8:37:05 AM UTC-5 Edward K. Ream wrote:

> [None] of Leo's existing reload-settings machinery is necessary...See  #4583 for the details.

Alas not. The existing per-class reloadSettings/reload_settings methods always update their per-class ivars.

But g.app.config.getX and c.config.getX can't possibly tell their respective config classes how to update those ivars later.

I have just closed  #4583 as a misguided idea. Boo hoo.

Edward

jkn

unread,
Apr 2, 2026, 2:16:53 PM (4 days ago) Apr 2
to leo-editor
I do appreciate the way you post your 'dead ends' here, as well as triumphs etc ;-)

    J^n

Edward K. Ream

unread,
Apr 2, 2026, 2:20:55 PM (4 days ago) Apr 2
to leo-e...@googlegroups.com
On Thu, Apr 2, 2026 at 1:16 PM jkn <jkn...@nicorp.co.uk> wrote:

I do appreciate the way you post your 'dead ends' here, as well as triumphs etc ;-)

You're welcome. Only fools never change their mind or admit their mistakes.

Edward
Reply all
Reply to author
Forward
0 new messages