Picolab / devtools

Repository for KRL Developer Tools
MIT License
6 stars 4 forks source link

nano_manager-CreateChild rule has mutating function #68

Closed burdettadam closed 8 years ago

burdettadam commented 8 years ago

we need to change picoFactory function to be a def-action. We also need to change createChild to use the new def-action and not the function.

earlyprogrammer commented 8 years ago

Before this can be done, defactions need to be able to return values. A return is required for wrangler to initialize the child after it is created.

windley commented 8 years ago

Do we have an issue for defaction returns already? If so, please reference it here. If not, let's discuss tomorrow and get some detail.

earlyprogrammer commented 8 years ago

I think that may be this issue https://github.com/kre/Kinetic-Rules-Engine/issues/90

earlyprogrammer commented 8 years ago

If the defaction is able to raise events, it could send the child the self-initializing event rather than needing to send the new eci to the parent. We could probably make things work without returning values this way.

earlyprogrammer commented 8 years ago

Nevermind, needing defactions to return values was an artifact of assuming we would have to track the parent-child relationships, until we realized the system already did that for us. Now we have no need to return the child eci to the parent, so the picoFactory defaction can raise the initializing event to the new child. Fixed.