Re: Client/server: second status report

2021-02-08 Thread tbp1...@gmail.com
Just for fun, here is a very lightweight test runner I have used sometimes. First, I define a decorator that prints the name of each test function and its docstring when the test is called: def self_printer(f): def new_f(*args): print() print ('Test:', f.__name__) if

Re: Client/server: second status report

2021-02-08 Thread Edward K. Ream
On Monday, February 8, 2021 at 8:48:01 AM UTC-6 Edward K. Ream wrote: > Aha: unit testing is easy. Indeed yes! leoserver.py now contains the TestLeoServer class: - setUpClass starts the bridge and begins coverage testing if coverage can be imported. - tearDownClass ensures that the shut_down c

Re: Import statements in Python scripts in LEO

2021-02-08 Thread tbp1...@gmail.com
It works for me :) Most likely thing I can think of: You installed markdown with a different Python installation than the one that launches Leo. For example, on some Linux systems (and on my own Windows one), *python* runs Python 2.7 while *python3* runs Python 3.8. On Monday, February 8, 202

Re: Client/server: second status report

2021-02-08 Thread Edward K. Ream
On Monday, February 8, 2021 at 8:48:01 AM UTC-6 Edward K. Ream wrote: > The communication between client and server is complete. I ran the client and server in separate Windows consoles (processes) with the following Leonine script: g.cls() import time if c.changed: c.save() g.execute_shell

Import statements in Python scripts in LEO

2021-02-08 Thread 'Shlomo Shizgal' via leo-editor
Sorry about this newbie question on scripts within LEO. I was generating html for an outline using the *rst3* command, but then decided I'd rather go through the nodes and generate my own html. I want to allow markdown in the body of the nodes, so I installed the *Python-Markdown* library. Whe

Client/server: second status report

2021-02-08 Thread Edward K. Ream
This Engineering Notebook post reports spectacular progress: - FĂ©lix and I have corrected each others misunderstandings. - The communication between client and server is complete. - Interaction between vs-code and Leo is much simpler than I imagined. The "language" of that interaction consists p