Git Product home page Git Product logo

flydelabs / flyde Goto Github PK

View Code? Open in Web Editor NEW
1.6K 16.0 30.0 133.88 MB

⚡️⚡️⚡️ Open-source, visual programming for developers. Includes a VS Code extension, integrates with existing TypeScript code, browser and Node.js.

Home Page: http://www.flyde.dev/

License: Other

TypeScript 86.58% JavaScript 6.77% EJS 0.10% SCSS 3.97% CSS 0.88% HTML 1.11% Shell 0.03% MDX 0.55%
flow-based flow-based-programming reactive-programming visual visual-programming visual-studio-code vscode visual-programming-editor visual-programming-language vscode-extension

flyde's People

Contributors

avshalom-mogos avatar gabigrin avatar jacobra19 avatar seveibar avatar sychris avatar tokyros avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

flyde's Issues

mongoDB connect node fails silently without an object in options

The options parameter doesn't reflect that an empty {} is required. I would expect that if it is not given an input if would either supply an empty object to it self or otherwise say that the object is required.

The same applies to the update one node and probably others as well.

Waiting for data indication on main inputs

I noticed when nodes inside a flow are waiting for data, they have a purple indication. But when the main inputs are waiting for data, there is no indication. This makes it hard to understand what's going on in the flow...

I think there should be a similar indication on the main inputs as well 🙏

🐛 Bug Report: cannot remove connections

Hey, I'm trying to remove a connection between 2 nodes but can't select the connection to remove it.
Tryting to "hook" the wire with my mouse (click) always unsuccessfully.
Please have a look at the enclosed witnessing movie

2024-03-13.15-13-28.1.mp4

flow New input, output

flow New input does not eject a value box meaning you cant pull a connection off of them. and must use the input or output of another node. this also has a side effect of not being able to make a "passthrough" flow there implementation details get filled out later.
Untitled

Discussion: how EmbeddedFlyde run the flow?

website/src/components/EmbeddedFlyde/EmbeddedFlyde.tsx

How did it run the flow, and load the deps? The code is a bit roundabout, I can see it load JS object from @flyde/stdlib/dist/all-browser, but can't find where they are used, and I can't find where the flow is executed.

BTW, Maybe you should enable Discussion in this repo.

Changelog & better release process

Better infrastructure around releasing is needed. Right now Flyde has no change log, which sucks. Also, all packages' patch versions are bumped on each push to main, even when they (or a dependency) did not change.

I've tried semantic-release, but it seemed over complicated and lacked mono-repo support.
https://github.com/changesets/changesets is a good next candidate, and if that does work, evolving the existing GH actions script should cut it

Missing versions @flyde/remote-debugger@^1.0.6

I got these error

 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/flow-editor/-/flow-editor-1.0.2.tgz error (ERR_PNPM_FETCH_404). Will retry in 10 seconds. 2 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/runtime/-/runtime-1.0.7.tgz error (ERR_PNPM_FETCH_404). Will retry in 10 seconds. 2 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/stdlib/-/stdlib-1.0.6.tgz error (ERR_PNPM_FETCH_404). Will retry in 10 seconds. 2 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/core/-/core-1.0.12.tgz error (ERR_PNPM_FETCH_404). Will retry in 10 seconds. 2 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/resolver/-/resolver-1.0.0.tgz error (ERR_PNPM_FETCH_404). Will retry in 10 seconds. 2 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/remote-debugger/-/remote-debugger-1.0.0.tgz error (ERR_PNPM_FETCH_404). Will retry in 10 seconds. 2 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/dev-server/-/dev-server-1.0.15.tgz error (ERR_PNPM_FETCH_404). Will retry in 10 seconds. 2 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/flow-editor/-/flow-editor-1.0.2.tgz error (ERR_PNPM_FETCH_404). Will retry in 1 minute. 1 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/stdlib/-/stdlib-1.0.6.tgz error (ERR_PNPM_FETCH_404). Will retry in 1 minute. 1 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/runtime/-/runtime-1.0.7.tgz error (ERR_PNPM_FETCH_404). Will retry in 1 minute. 1 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/resolver/-/resolver-1.0.0.tgz error (ERR_PNPM_FETCH_404). Will retry in 1 minute. 1 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/core/-/core-1.0.12.tgz error (ERR_PNPM_FETCH_404). Will retry in 1 minute. 1 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/remote-debugger/-/remote-debugger-1.0.0.tgz error (ERR_PNPM_FETCH_404). Will retry in 1 minute. 1 retries left.
 WARN  GET https://mirrors.cloud.tencent.com/npm/@flyde/dev-server/-/dev-server-1.0.15.tgz error (ERR_PNPM_FETCH_404). Will retry in 1 minute. 1 retries left.

https://mirrors.cloud.tencent.com/npm/@flyde/flow-editor/-/flow-editor-1.0.2.tgz: Not Found - 404
 ERR_PNPM_NO_MATCHING_VERSION  No matching version found for @flyde/remote-debugger@^1.0.6

This error happened while installing the dependencies of @flyde/[email protected]

The latest release of @flyde/remote-debugger is "1.0.0".

when installing
pnpm i @flyde/core @flyde/resolver @flyde/runtime @flyde/stdlib @flyde/flow-editor

Seems you have some wrong version numbers in the package?

not sure why vscode npm intellisense show there is 1.0.x version

图片

Type safety for "loadFlow" function when using the extension

loadFlow receives a string that isn't type-safe, leading to possible annoying errors such as typos or loadFlow not failing when .flyde files were moved around (#112 ?)

Also, adding type safety to the inputs and outputs of a flow is very valuable.

For any future contributor who wants to take a look:
There's already some attempt I've made to do this - see https://github.com/flydelabs/flyde/blob/main/dev-server/src/service/generate-typings.ts (dev-server is the module used by the vs-code extension)

Why these deps in Editor example

I'm learning the usage from the code, here are something not clear:

Why is

      extraContext: {
        PubSub,
      },

https://github.com/FlydeHQ/flyde/blob/a3da13b5d25d6bbb2356ff6c0d04d593b2f35767/website/src/components/EmbeddedFlyde/EmbeddedFlyde.tsx#L2

this seem to not use elsewhere?

Answer: used in Publish node

But why not let nodes come with their own dependency, instead of let runtime provide for them?


and why is import { fakeVm } from "@site/src/fake-vm";, seems

import {
  execute,
} from '@flyde/core';

can already do the code execution?

Broken imports after moving files

Hey! Great job on the extension. I created a simple code flow and imported it into my flow, and it worked great. However, when I moved the imported file to a different folder, the import broke. I think it would be great if the extension could handle this case. Thanks

CLI Runner

Hey
I'm thinking of running Flyde flows from a Python codebase and was wondering if there's any quick way to run a flow via CLI

log and error nodes

This is likely vscode extension specific however the log and error nodes only output to flyde (debug) and do not output to standard Flyde output. which is flooded with far less debug like output. if one was developing a cli project this would be a pain to sort threw to get your output messages

running web browser graph

browser: chrome: Version 116.0.5845.141 (Official Build) (64-bit)
os: windows 10 pro
issue: clicking the start button or pressing r does not run graph however pressing the green Run! button does run the graph.

Browser runtime

How to run a graph in the browser?

The doc in https://www.flyde.dev/docs/StdLib/ might be misleading, it implies that flyde can only run in the nodejs side, because StdLib includes filesystem node.

Also, how to load nodes lib in the browser? I would like to use esm to load a node lib on the fly, and "register" the node in to the runtime, the load a graph.

flow node id

you can right click to set a description but there's no way to set a node: id (which is the default name of the node after its imported) this leads to a few different bugs 1, the default name can't be changed without editing it in text, 2. if 2 flows are made from say hello world example and one is placed in the other you get a fun infinite loop, 3 when you update the inner flow it doesn't reload making it seam like the nodes are frozen.

also manually renaming a node ID after its been placed on another flow breaks that flow resulting in a

Errors: Flyde editor error: Failed to resolve flow's dependencies: Error: HelloWorld2 in d:\coding_projects\flyde\helloflow.flyde is using referenced node with id old_id that is not imported

Liscense Clarification Question

Making the editor agpl, not only means that fixes are sent upstream. but if you embedd it in a site , that site has to also be agpl compatible, was this part done intentionaly? Or am I interperating it wrong somehow.

Error creating flow when VSCode is not set to a specific folder

Error creating flow: Error: EPERM: operation not permitted, open '\helloflow.flyde'

created a new folder to test this out
OS Name Microsoft Windows 10 Pro
vs code extension v0.43.0
vs code version 1.81.1
tryed both new file from the file explorer vindow and file/new file

odd restarting and trying a few more times now its working...

Plan an auto-layout feature for the editor

One of the major problems with visual tools is the need to constantly move nodes around to make everything readable.

Although I believe manual tweaks might be needed, Flyde should have an auto-layout feature, using existing open-source libraries.

Design is cluttered and random

The current design of Flyde is borderline random and holds no justification for many choices, such as the gradient on the background, shadows on nodes, and more.

A more minimalistic, clear, and clean design is needed to make it more aesthetically appealing, enable dark mode, and enable further feature enhancements.

no apparent way to drag the graph around vscode

you can use the scroll wheel to scroll up and down but i would expect the middle mouse key or right click drag to move the canvas.
as a work around you can create a new value node throw it to the direction you would move the canvas and click center before deleting the node to move the canvas :)

make monaco optional in editor

I found when install the editor, it tries to install the monaco editor which has the size of 10 MB.

But I'm Trying to make this as a plugging for the tiddlywiki, which is very sensitive to the size. (It's a single file HTML wiki, portable with its small size)

I hope I can replace it with a simple textarea, or inject a codemirror to it.

And from the playground, I notice that monaco is within a popup, which might be outside of the flow editor, so it is truely optional?

Missing "getting started" as oss dev (not user)

  • easy entry point for new contributors to get up and running with the project
  • design diagrams of the general architecture might be helpful to understand what's is going on

how?

  • contribution guide
    • setup locally: prerequisite, yarn, yarn build, cd editor, yarn start, and so on...
    • How to contribute to the project?
  • high level overview of the packages and the project structure

Separate logic and representation in saved file

(as discussed in discord )

Why both noflo and flyde not use .fbp file anymore?
noflo it use json for saved graph https://github.com/flowhub/the-graph/blob/master/examples/assets/photobooth.json.js
and flyde use yaml https://github.com/FlydeHQ/flyde/blob/main/website/src/pages/playground/_flows/fibonacci.flyde
This mixes the graph functionality with the node position, make it harder for AI to auto generate a graph
I hope we can separate the node position metadata from functionality, so positions saved in a JSON, and logic store in a .fbp file.

But this can be solved by writing a .fbp to yml or json transformer, and use https://github.com/noflo/klayjs-noflo to auto-assign position to nodes

VSCode extension editor's "Test Flow" conflicted with existing tsconfig

Problem

When I click the "Test Flow" button, an error will appear

Unexpected error while handling message from webview: 
Could not find Custom Add in {absolute path to project}/add.flyde.ts. 
The following errors were thrown, and might be the reason the node is not properly resolved. 
Errors: Error loading module "{absolute path to project}/add.flyde.ts": Unexpected token 'export'

Possible Cause

After some fiddling around, I found out that changing the module to NodeNext and moduleResolution to NodeNext seems to make it work

Steps to Reproduce

  1. Init a regular npm project
  2. Install @flyde/core using package manager
  3. Create a Flyde flow
  4. Add a custom code node (the add in the tutorial will do)
  5. Import the custom code node
  6. Click "Test Flow" (it should work)
  7. Create a tsconfig.json
  8. Change module to ESNext and moduleResolution to ESNext
  9. Click "Test Flow" (expected to fail)

Request

monorepo doesn't work either

using a namespace in user created nodes incorrect sorting

If namespace is designated in a .flyde.ts file and the namespace exists in the stdlib it places your node with the stdlib files like so:
2023-09-07 06_05_06-saveAgentToDB flyde - flyde - Visual Studio Code

If you place them in a namespace that does not exist than they are not categorized at all

I would rather expect something like this:
expected node list
where namespaces are created under current project

Suggestion

Python Loops and Conditionals Tutorial

Loops

Loops are one of the most fundamental control structures in programming. They allow a block of code to be repeated multiple times. Python has two types of loops: for and while.

For Loop

The for loop is used to iterate over a sequence (list, tuple, dictionary, set, string) or any other iterable object.

Iterating over a list

for i in [1, 2, 3, 4, 5]:
    print(i)  # Prints numbers from 1 to 5

While Loop

The while loop allows the execution of a group of instructions as long as a condition is met (i.e., as long as the condition evaluates to True).

# Example of using the while loop
i = 1
while i <= 5:
    print(i)  # Prints numbers from 1 to 5
    i += 1

Conditionals

Conditionals allow us to check conditions and make our program behave one way or another, according to the results of these conditions.

If, Elif, Else

In Python, the syntax for conditionals is through the reserved words if, elif (else if), and else.

age = 20
if age < 18:
    print("You are underage.")
elif age >= 18 and age < 65:
    print("You are an adult.")
else:
    print("You are a senior.")

This is a very basic rundown of loops and conditionals in Python. There is much more you can do with them, including nesting loops and conditionals, using break and continue in loops, among other things. However, I hope this gives you a solid foundation upon which you can build.

I18N

With react-i18n-next , and i18n-ally vscode plugin.

reorder trigger Node input

on the Write File node the inputs contents and path are offered if you show the Trigger Node input and attempt to reorder nodes the trigger node is prefilled as __trigger atempting to place it in any other position but las fails. you can reorder the default pins though.
__trigger,contents,path results in
2023-09-06 20_50_11-● zxcv flyde - flyde - Visual Studio Code

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.