-
Notifications
You must be signed in to change notification settings - Fork 80
Open
Labels
bugSomething isn't workingSomething isn't workingdaemonIssues pertaining the the pet dæmon 🐈⬛Issues pertaining the the pet dæmon 🐈⬛
Description
Describe the bug
As of the current endo feature branch (#2073), endo cancel does not propagate as expected under some circumstances. A common factor seems to be that neither direct nor indirect cancellation works for values running "in" guests. See reproduction steps below.
We may not want to bother solving this until we are threading cancellation through messages and, perhaps, until messages are persisted across restarts.
Steps to reproduce & expected behavior
This transcript uses the
diffformat. The removed (-/ red) lines are the expected behavior, and the added (+/ green) lines are the observed behavior.
endo purge -f
endo make counter.js --name counter
Object [Alleged: Counter] {}
endo mkguest doubler-agent
Object [Alleged: EndoGuest] {}
endo make doubler.js -n doubler -p doubler-agent
Object [Alleged: Doubler] {}
endo resolve 0 counter
endo eval 'E(doubler).incr()' doubler
2
endo eval 'E(doubler).incr()' doubler
4
endo eval 'E(doubler).incr()' doubler
6
// This cancels the counter, which should also cancel the doubler
endo cancel counter
endo eval 'E(doubler).incr()' doubler
- 2
+ 8
endo eval 'E(counter).incr()' counter
- 2
+ 1
endo eval 'E(counter).incr()' counter
- 3
+ 2
endo eval 'E(doubler).incr()' doubler
- 8
+ 10
// This should, naturally, cause the doubler to be cancelled
endo cancel doubler
endo eval 'E(doubler).incr()' doubler
- 10
+ 12
endo cancel doubler-agent
// Here the doubler is finally cancelled.
// The return value is correct given the incorrect state of the counter
endo eval 'E(doubler).incr()' doubler
- 12
+ 6Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingdaemonIssues pertaining the the pet dæmon 🐈⬛Issues pertaining the the pet dæmon 🐈⬛