Comments (7)
Also have iteration of
let tempTask=new D3NE.Task(inputs,(inps)=>{})
var task = new D3NE.Task(inputs, async(inps) => {
console.log("Resolve");
await resolveAfter2Seconds()
console.log("Should Pass");
return [tempTask.option(0)]
})
outputs[0] = task.output(0);
}
});
from rete.
async Tasks are not supported at present time. The action function you pass to Task is calling without await . Therefore a following nodes are executed without waiting for the current one to done.
I'll take care of this at evening.
One more thing, why are you passing on tempTask.option(0)
inside another task ? Worker should have one task.
from rete.
This is what i originally had but the issue was it would immediately pass even before promise had resolved
var componentDelayEvent = new D3NE.Component("Delay Event", {
builder(node) {
let act = new D3NE.Output("Action", actSocket),
inp1 = new D3NE.Input("Action", actSocket)
return node.addOutput(act).addInput(inp1);
},
worker(node, inputs, outputs) {
var task = new D3NE.Task(inputs, async(inps) => {
console.log("Resolve");
await resolveAfter2Seconds()
console.log("Should Send");
})
outputs[0] = task.option(0);
}
});
from rete.
@CheweyZ new version v0.6.8 has been released with async Tasks
Example of use
from rete.
Thanks so much for fast fix and reply
from rete.
Another thing should maybe open another issue but the link https://github.com/Ni55aN/d3-node-editor/wiki/Tasks/#tasks found on https://github.com/Ni55aN/d3-node-editor/wiki/Engine Just takes you back to base wiki url is this intended?
from rete.
I have not filled out the page on wiki for this object yet. I'll deal with it a little later
from rete.
Related Issues (20)
- Options/Checkboxes in plain javascript HOT 3
- how to use vue3 plugin for Node HOT 3
- Missing Example for using V2 with node js HOT 2
- How to use the ELK radial algorithm? HOT 6
- How to combine different Sockets HOT 1
- Button inside input/output not working in vue HOT 3
- CSS/Javascript Selecting Certain nodes/connections? HOT 6
- Disable zoom on dblclick in v2 HOT 2
- Angular: Add control / custom element in a connection. HOT 12
- Simple Nodes Order breaks click event handlers HOT 2
- Define node id HOT 1
- Adding nodes dynamically - what is going on here? HOT 2
- Warning spam: flushSync was called from inside a lifecycle method. React cannot flush when React is already rendering HOT 7
- Tablet device support HOT 9
- Node Socket position override HOT 2
- Validate magnetic connections HOT 4
- Add socket by dropping connection on Node HOT 2
- Custom data to psuedo connection HOT 8
- Custom Context menu HOT 2
- Will this project be open source in the future? HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rete.