A serious dilemma has been on my mind recently with regard to using pyzo's
code. Neither importing nor copying pyzo's code is free from serious
problems. Either way, changes to pyzo will ultimately affect Leo.
This morning I saw a sideways resolution of this dilemma. Regardless of
how Leo uses pyzo's code:
*Aha: Leo's devs become responsible for pyzo's code.*
Leo's devs will have to fix any bugs found by Leo's users, and probably
will want to fix bugs found by pyzo's users.
Furthermore, significant problems will arise in adapting pyzo's code,
regardless of whether Leo imports or copies pyzo's code. There is no
question about this: pyzo and Leo are two different worlds.
*Strategy*
The simplest way forward will be to copy relevant parts of pyzo into
leo/plugins/pyzo_support.py. This will give me complete control of the
code. It will be essential to mark (with comments) all changes made to the
pyzo code.
Notice I said "simplest" in the previous paragraph. Significant changes
may be required. For example, imports may have to be changed when copying
code from pyzo to pyzo_support.py. The code must not pull in the "real"
pyzo code by mistake.
*Summary*
This Aha is good news. There can be no clever way forward that somehow I
might have missed.
My first pyzoic project will be #1149
<https://github.com/leo-editor/leo-editor/issues/1149>: dired browser.
This will be a good prototype for the much larger #1158
<https://github.com/leo-editor/leo-editor/issues/1158>: pyzo shell.
Edward
--
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 view this discussion on the web visit
https://groups.google.com/d/msgid/leo-editor/433e0e56-7267-453e-8fd2-74657a122a2b%40googlegroups.com.