-
Notifications
You must be signed in to change notification settings - Fork 443
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Need a system for managing external node libraries #124
Comments
Thanks a lot for sharing your thoughts. Some comments from my side:
good point, totally agree, shouldn't be too hard to add
Yes, the readme also states: I would like to open a repository for maintaining particularly useful (frameworks of) nodes, and I would really like to have a central place / repository for all easily accessible node packages, which automatically tests them and tracks their versions. There are just many design choices here, and so far I didn't feel like there was really a need for it, but I'd like to see that happening.
I am not sure about that, but this is a very important point, so let me elaborate in more detail: I think the system loses its purpose quickly when mapping python library functions 1:1 to visual nodes. I think the power of the paradigm lies in much stronger abstraction, as opposed to just wrapping something that's already simple into something much more complex in an attempt to make it a tiny bit more accessible, but inevitably making it much harder to scale and maintain at the same time (which is a more general issue imo). That being said, this is just what I'd expect and these points are very much up for discussion. A package system might give more insight into which types of packages work well in practice, and which don't. But I'm also afraid of packages suggesting usage of the visual paradigm in a way that doesn't scale. So far I tried to impose as little contraints and design suggestions on node packages as possible, to let the users decide what kinds of node packages are most useful for them. Comments on this are highly appreciated.
true, the
yes! One could also write a dynamic (randomized) tester that tries to squeeze any unhandled exceptions out of the packages. We could enforce for example any of the package to be stable under any valid sequence of ryvencore api actions on them, such as
which could be streamlined with CI. Of course this should be extended by the package author by some deterministic semantic tests verifying that the outputs are actually correct. |
My bad. I end up skipping some parts thinking I know them from the last time I looked at Ryven. :)
Interesting. I understand abstraction in general, and I understand what the 1 to 1 version would look like. But I do not understand which types of abstraction the "stronger" ryven-only abstractions would be. Can you give a example description of a abstracted version that could replace a 1 to 1 pip package mapping to help me understand in what ways they would differ? (and then presumably, I'd be able to see how the rest of your argument follows)
I fully understand your intentions here. You want people with lots of Ryven packaging experience to debate the various points, while not influencing the discussion with your own assumptions in order to come up with the best answer. Of course the problem is that no one will have the experience to have those opinions until after you have some kind of packaging system for them to try (and discover what they don't want). Actually the fastest way to start would probably be to say something like, "after you write your node package, please contribute it by forking https://github.com/leon-thomm/ryven-contributed-node-libraries , create your own subdirectory, then put your package in a subdirectory of that, then send a pull request." While I'm on the topic: (Also probably mention that if they create ryven example programs, where they should put them)
Note: I am not qualified to talk about Also note that I am not confident that I fully understand the Ryven flow yet (but I understand more of it this time around then when I investigated it previously)
Agreed. I imagine that many package authors will not have semantic tests verifying the outputs, especially at first, so a way of the end user detecting if those tests are part of the package before they attempt to use a package could be helpful. |
Sorry, I phrased it poorly; I totally agree with packages being wrappers for specific Python libraries (say, a 1:n library:ryven-package mapping), but I'm not sure about the automatic conversion part (which suggests a 1:1 interface mapping); The developer of a nodes package should put some thought into how to make the targeted library's functionality available in the framework of flow-based programming, which IMO is quite different from almost one-dimensional, text-based code. I meant stronger abstraction just in terms of doing more - as in declarative vs. explicit. Of course, when using libraries, functions like
true
good point
Interesting!
I would probably reserve the hijacking part for the "second approach", and just use a git repository initially. I am not sure if a full-blown package manager is necessary initially, one could also literally stick to git itself being the VCS. the other points regarding the repo are noted, thanks. |
I took another look and you seem to have made substantial progress since the last time I looked at Ryven (I.E. since #74 ). Hopefully the following comments will be helpful.
This is going to talk about multiple related issues relating to node library management
Finding Node packages:
Trying to figure out which node package to import can be a issue.
(example workflow: person doesn't remember what package has the "print" node, import a node package, search, import another, search, import another, search find it and use it")
(obviously we could just grep through all the node.py files)
So a way to browse the node libraries before doing File->Add Nodes would be a good thing
Should encourage contributions to the node libraries:
(or alternatively, if peoples node packages are getting contributed & redistributed, its not obvious where those packages are.)
The README mentions that people can help by creating node packages, and example programs, but does not mention what to do once they write them.
Perhaps add a comment on where to upload node packages?
also:
The readme includes: "Now let's check out the small example projects: open a new Ryven window and load one of them. Take a closer look and understand what they do."
Perhaps add something like "User contributed example programs can be found at {location}"
Need a way to track the quality of node packages
Most node packages will be wrappers for specific python pip packages. For those types of node packages, I see the following information would be useful to track:
The installed versions of the pip packages are relevant, because for example, doing:
However doing File->Import Node on the generated files does not work ( meaning they do not show up in the pick list on the left) if using version 1.5.1 of pandas (I.E. if you did "pip3 install pandas" instead of "pip3 install pandas==1.1.5")
(i realize that 1.5.1 vs 1.1.5 is confusing)
Solution:
Unfortunately I don't have the solution thought out, I'm just highlighting the issue, and now I'll just give some some random thoughts on it.
** one possible way might be to add something like a ryven.NENV.register_node_package(author, pip_package_name, pip_package_version?...
In general I'm trying to think of simple solutions short of making a full blown "rypip" node package manager. :)
There is also the issue of what to do with the packages that are not wrappers for python pip packages.
Sorry for making this so long, but as I said, I don't have the solution for it, but hopefully this can get ideas started.
The text was updated successfully, but these errors were encountered: