New version of LeoInteg released: 0.1.9 stable "Proof of concept"

112 views
Skip to first unread message

Félix

unread,
May 29, 2020, 11:44:13 PM5/29/20
to leo-editor
Hi all! 

I just pushed a new version on the master branch of LeoInteg. ...I made sure it runs well under Windows this time! ;) 

(lol honestly feel a bit silly I didnt even made sure my pasts releases even worked outside of ubuntu)

All main issues with the last version have been resolved, many new features have been added,  and as ar-jan puts it, it's now possible to edit a derived file and smoothly keep it in sync with Leo, in both directions.

I've got all that and more on the master branch for you to try at https://github.com/boltex/leointeg 

And if you're so enclined, I've even made a handy "Test-sheet" for you to use when you're trying out LeoInteg: https://docs.google.com/spreadsheets/d/1M7TA3J0hkBpU4BkyChThrhzwKxhTPtQHacXDYRvEQes/edit?usp=sharing

It's just a small grid of yellow checkboxes (from rows E to I) to help keep track of what features can be interacted with.

I hope you like it and also to get some feedback as you try it out! :)

Félix 

Edward K. Ream

unread,
May 31, 2020, 6:39:48 PM5/31/20
to leo-editor
On Friday, May 29, 2020 at 10:44:13 PM UTC-5, Félix wrote:

> I just pushed a new version on the master branch of LeoInteg. ...I made sure it runs well under Windows this time! ;)

Here are my experiences.

1. npm install reported the following:

found 310 vulnerabilities (298 low, 12 high)
  run `npm audit fix` to fix them, or `npm audit` for details

I didn't run npm audit fix, to keep things as they were.

2. Adding the path to the leo-editor folder did not work. Adding this to my sitecustomize.py did work:

import sys
leo_path
= r'C:\leo.repo\leo-editor'
if leo_path not in sys.path:
    sys
.path.append(leo_path)

Finally, running F5 in vs code gave an error previously. Now it asks me for an environment. When I select node.js I get a dialog saying '${file}' can not be resolved. Please open an editor.

What do I do now?

Edward

Félix

unread,
Jun 1, 2020, 1:02:08 AM6/1/20
to leo-e...@googlegroups.com
Thanks for trying it out and sharing your experience! 

1- npm install logs gives exact same warnings for those dependencies for me too. that's normal.

2- I'm not familiar with sitecustomize.py but I just googled it and found out its about customizing python environments for different projects on a machine. I will at some point have to give more friendly details of installation for people using that, and/or anaconda. But everything related to the python side of things can be tested independently of vscode and leointeg, by simply starting the leobridgeserver.py script manually yourself in any way you choose... (terminal, or some shell...)

3- Hmmm ... I've never encountered this dialog asking for an 'environment' nor dialog saying '${file}' can not be resolved... I'll switch to my windows machine and will come back here to report about the current node.js version that is installed on my machine, along with version of any other thing that might not have been taken care of by the 'npm install' step. 

In the meantime, (if you're ok with this), could you please click on the help/about button in vscode's menu? it's got a handy 'copy' button which you could use to then paste the results in here. That would give general info that might be useful. For instance on my linux machine I get this report: 

Version: 1.45.1
Commit: 5763d909d5f12fe19f215cbfdd29a91c0fa9208a
Date: 2020-05-14T08:27:22.494Z
Electron: 7.2.4
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Linux x64 5.5.5-050505-generic

(back to edit this message from windos) and here is the same on my windows machine : 

Version: 1.45.1 (user setup)
Commit: 5763d909d5f12fe19f215cbfdd29a91c0fa9208a
Date: 2020-05-14T08:27:35.169Z
Electron: 7.2.4
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Windows_NT x64 10.0.17763

and if I run "node --version" in a terminal i get: 
v12.16.1

Félix

Félix

unread,
Jun 1, 2020, 1:33:40 AM6/1/20
to leo-e...@googlegroups.com

Also, it just occurred to me that maybe the 'environment' dialog is just the other instance of vscode, with leointeg running, that happened to be opened in a workspace that contains some javascript or typescript files, and its just vscode reacting to the languages of the files happening to be in the workspace its oppened into. (same thing that would have happened if you would have opened that folder with vscode anyhow)

That happened to some people before,  although it might not be whats happening here....  it might help some other people who are new to vscode itself to take note that: 

It is very proactive in detecting what opened folder the explorer view is in, and will suggest interpreters environments, and extensions to install, or pop up dialogs to ask for environments if it detects more than one interpreters available on your machine for a given language, etc. and so on... (those generaly dont come back) those might be mistaken with leointeg or something going wrong, 

just cancel/close those and try to see if the new vscode debug-instance is running and has the leo icon is in the main activity bar - generaly on the left, and try to do what i do in the first animated gif of the readme. if possible.

Thanks for reporting any details about this! It will be concatenated and / or be used to facilitate the installation and running by giving explicit steps to run without those problems in the readme file.

I think I'll just uninstall vscode completely on my windows box and try to install vscode and leointeg in 4 or 5 steps with screen captures to acompany the text in my readme... or maybe another animated gif? hehe, i like animated gifs... but its late and i'm laughing at my own jokes so i'm going to bed now i'll do this tomorrow.

Thanks again!

Félix


On Monday, June 1, 2020 at 1:02:08 AM UTC-4, Félix wrote:
Thanks for trying it out and sharing your experience! 

1- npm install logs gives exact same warnings for those dependencies for me too. that's normal.

2- I'm not familiar with sitecustomize.py but I just googled it and found out its about customizing python environments for different projects on a machine. I will at some point have to give more friendly details of installation for people using that, and/or anaconda. But everything related to the python side of things can be tested independently of vscode and leointeg, by simply starting the leobridgeserver.py script manually yourself in any way you choose... (terminal, or some shell...)

3- Hmmm ... I've never encountered this dialog asking for an 'environment' nor dialog saying '${file}' can not be resolved... I'll switch to my windows machine and will come back here to report about the current node.js version that is installed on my machine, along with version of any other thing that might not have been taken care of by the 'npm install' step. 

In the meantime, (if you're ok with this), could you please click on the help/about button in vscode's menu? it's got a handy 'copy' button which you could use to then paste the results in here. That would give general info that might be useful. For instance on my linux machine I get this report: 

Version: 1.45.1
Commit: 5763d909d5f12fe19f215cbfdd29a91c0fa9208a
Date: 2020-05-14T08:27:22.494Z
Electron: 7.2.4
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Linux x64 5.5.5-050505-generic

(back to edit this message from windos) and here is the same on my windows machine : 

Version: 1.45.1 (user setup)
Commit: 5763d909d5f12fe19f215cbfdd29a91c0fa9208a
Date: 2020-05-14T08:27:35.169Z
Electron: 7.2.4
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Windows_NT x64 10.0.17763

Edward K. Ream

unread,
Jun 3, 2020, 9:28:03 AM6/3/20
to leo-editor
On Mon, Jun 1, 2020 at 12:02 AM Félix <felix...@gmail.com> wrote:

Thanks for trying it out and sharing your experience! 

You're welcome. I'll soon describe the kinds of things that are confusing me :-)

Edward

Edward K. Ream

unread,
Jun 3, 2020, 12:34:28 PM6/3/20
to leo-editor
On Friday, May 29, 2020 at 10:44:13 PM UTC-5, Félix wrote:

> I just pushed a new version on the master branch of LeoInteg. ...I made sure it runs well under Windows this time! ;) 

Here is the list of things that confused me. Remember, I'm still a complete vs-code newbie. Unless otherwise noted, I'm trying to follow the instructions a leointeg/README.md.

Confusion 1

Here is part of the development version installation instruction from README.md:

QQQ
Make sure you have Node.js and Git installed, then:
1. Get this repository: git clone https://github.com/boltex/leointeg.git
2. Right-click it -> open with vscode (or from a vscode window, File-> Open Folder...)
QQQ

In point 2 above, what does "it" refer to? I guessed it meant the leointeg folder itself. Iirc, I opened the folder from inside vs-code.

Confusion 2

This is more generic. I'm never quite sure what's your code, where it resides, and what it supposed to do. In particular, F5 is bound (in vs-code) to "Start debugging". But this is confusing! Debugging "what".

I suppose Leo newbies might be confused in somewhat similar ways. But in Leo, Ctrl-b, execute-script, clearly means execute p.b. What is the equivalent of p.b in the vs-code world.

Confusion 3

I now see three main parts in the left-hand pane: Open Editors, Outline, Timeline and Leo. I'm not sure which parts are due to leointeg. All of them? What do they do?

Confusion 4

My guess is that vs-code remembers lots of state between invocations. No doubt this is great for more experienced users, but it makes it difficult for a newbie to know what a "clean" start would be like.

Summary

I'm pretty sure all these confusions can be cleared up fairly easily.

Feel free to answer in writing, or to set up a zoom meeting if that would be easier for you.

Edward

Félix

unread,
Jun 4, 2020, 4:54:28 PM6/4/20
to leo-editor
Hi Edward,

This conversation is very valuable because I want to make the experience of installing and using LeoInteg easy and straightforward for all long-time (or not) users of Leo, irrespective of their familiarity with vscode. So thanks for putting out your very own thoughts as you experience the process of trying out this extension still in development! 
 
Because of my professional deformation for using vscode/sublime daily for the last 7 years or so, I'm having a hard time presenting the installation and usage methods to people unfamiliar with vscode in a clear and concise way. 

That is to be expected I guess :)

Although most of this will be irrelevant once I deem the project advanced enough to be compiled and distributed as an actual vscode extension (installed and ran seamlessly via the extension/market panel) It's still very much important because I also have to fine-tune what I show in the leoInteg panels, and in the readme, etc. 

Which brings me to what I think is the subtlety that make the whole process of 'testing a vscode extension still in development' a bit confusing: you're not running nor debugging my extension : you're running the whole of vscode's source itself (the second vscode window that opens when you press F5) with leoInteg in it, as if it was installed as a real extension. 

I hope that last paragraph made sense... English is a second language to me, so my sentence structures may be flaky at times. It's referred in the official doc as "compiling and running the extension in a new Extension Development Host window" https://code.visualstudio.com/api/get-started/your-first-extension

To help in clarifying all of this, I'm currently working on https://github.com/boltex/leointeg/issues/44 , so this is changing the appearance of the interface and, hopefully, going to help a lot in the startup, and automation of the server startup and the connection to it, so I'll make video captures right after I'm done with this. Hopefully before the week end. (I'm open to doing zoom sessions: as soon as I finish those changes on the interface)

But in the meantime, I'll address the numbered points you raised :

Point 1: yes, I meant the folder itself as such via the right-click context menu (once vscode is installed with defaults behavior on windows) see this screenshot: 


Point 2: addressed above, when pressing F5, you're running/debugging the whole of vscode, with the addition of leoInteg installed and running in it, as an extension. It's the normal way to try an extension that's still in development.

Point 3: (see pic below for nomenclature) leoInteg adds a (stand-alone) view in the side bar, accessible via the 'lion' icon in the activity bar. It's also 'reflected' (a "clone" in Leo's parlance if you will) by default in the explorer view of the side bar. (both the folder explorer and leo's outline rarely need to take the whole vertical space, and its nice to see them at the same time, that why I added a reflection of Leo's outline in vscode's explorer view)

code basics hero
LeoInteg also provides body pane(s), (as expected), a log pane, (at the bottom with the other output panels), a "Welcome/Settings webview" page similar to the gitLens welcome screen (https://github.com/eamodio/vscode-gitlens) and some dialog windows that popup when external file changes are detected. (can be automated to always refresh for 2 way auto sync, see https://github.com/boltex/leointeg/issues/32#issuecomment-636386336 )

Point 4: you're right, and that's why i intend on making a small video by capturing myself installing and running the whole thing in a straightforward and unambiguous way. 

As it is now, upon activating, leoInteg will try to start the leobridgeserver.py python script itself, and connect to it on localhost. I'm currently changing this to not doing none of those 2 things and instead offer 2 buttons in the outline pane, with a mention that those can be automated in the option settings. 

So that's it for now i guess, i'll go grab a coffee and finish those last points that will clear things up a lot... I'm pretty confident about it... :) 

In the meantime here's a vscode pro tip: ctrl+shift+p is the most useful command: it opens the command palette that lazy -searches to run any command, (equivalent to the minibuffer in leo? i think so)

...And lastly, just a reminder: if you happen to get things running , open your favorite Leo file in leoInteg and try to fill out the checkmarks in the test sheet :) https://docs.google.com/spreadsheets/d/1M7TA3J0hkBpU4BkyChThrhzwKxhTPtQHacXDYRvEQes/edit?usp=sharing

I'll give some more updates and details later - thanks again for trying and reporting ! !

Félix

Edward K. Ream

unread,
Jun 6, 2020, 6:38:32 AM6/6/20
to leo-editor
On Thu, Jun 4, 2020 at 3:54 PM Félix <felix...@gmail.com> wrote:

This conversation is very valuable because I want to make the experience of installing and using LeoInteg easy and straightforward for all long-time (or not) users of Leo, irrespective of their familiarity with vscode. So thanks for putting out your very own thoughts as you experience the process of trying out this extension still in development! 

My pleasure.

 Because of my professional deformation for using vscode/sublime daily for the last 7 years or so, I'm having a hard time presenting the installation and usage methods to people unfamiliar with vscode in a clear and concise way. 

That is to be expected I guess :)

Yes. There is even a term for it: "the curse of knowledge".

Although most of this will be irrelevant once I deem the project advanced enough to be compiled and distributed as an actual vscode extension (installed and ran seamlessly via the extension/market panel) It's still very much important because I also have to fine-tune what I show in the leoInteg panels, and in the readme, etc. 

I'm glad you think so. It will help us all understand what you are trying to do, and how.

Which brings me to what I think is the subtlety that make the whole process of 'testing a vscode extension still in development' a bit confusing: you're not running nor debugging my extension : you're running the whole of vscode's source itself (the second vscode window that opens when you press F5) with leoInteg in it, as if it was installed as a real extension. 

An important clarification.

I hope that last paragraph made sense... English is a second language to me, so my sentence structures may be flaky at times. It's referred in the official doc as "compiling and running the extension in a new Extension Development Host window" https://code.visualstudio.com/api/get-started/your-first-extension

It was perfectly clear.

To help in clarifying all of this, I'm currently working on https://github.com/boltex/leointeg/issues/44 , so this is changing the appearance of the interface and, hopefully, going to help a lot in the startup, and automation of the server startup and the connection to it, so I'll make video captures right after I'm done with this. Hopefully before the week end. (I'm open to doing zoom sessions: as soon as I finish those changes on the interface)

I'll look forward to it.

But in the meantime, I'll address the numbered points you raised :

Point 1: yes, I meant the folder itself as such via the right-click context menu (once vscode is installed with defaults behavior on windows) see this screenshot: 

One thing grammarly keeps reminding me of are unclear antecedents like "this" and "it".

Point 2: addressed above, when pressing F5, you're running/debugging the whole of vscode, with the addition of leoInteg installed and running in it, as an extension. It's the normal way to try an extension that's still in development.

Ok.

Point 3: (see pic below for nomenclature) leoInteg adds a (stand-alone) view in the side bar, accessible via the 'lion' icon in the activity bar. It's also 'reflected' (a "clone" in Leo's parlance if you will) by default in the explorer view of the side bar.

Thanks for the picture. It does clarify the terminology. I don't see any lion icon anywhere, either in your picture or my running copy of vs-code.
Point 4: you're right, and that's why i intend on making a small video by capturing myself installing and running the whole thing in a straightforward and unambiguous way. 

Thanks.

I'll give some more updates and details later - thanks again for trying and reporting !

It's my pleasure to help with this project.

Edward
Reply all
Reply to author
Forward
0 new messages