You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
lockCaller: let a leaf pin its caller onto a deferred callback #489
A leaf that stores work to run later on behalf of whoever called it (a scheduler or registry leaf) cannot make that work run as the caller. self.slothlet.lockCaller(fn) always pins the leaf that is currently running, which is the registry leaf itself.
Real case
rummage's deadline extension builds a reminder engine per consumer through self.deadline.engine(...) and ticks them all from one scheduled job. The ticks run as the deadline extension, not as each owning consumer. Owner attribution is currently carried as a payload field (owner, taken from metadata.caller()) instead of by the caller identity the rest of the system uses.
Proposal
self.slothlet.lockCaller(fn, { as: "caller" }) pins the current leaf's caller (the identity metadata.caller() would report) onto fn instead of the leaf.
Same capability as #477 (a leaf pinning its caller, not itself, onto a deferred callback). I've copied the permission gate, the principals composition, the immutability guarantee and the deadline-engine case into #477 so nothing is lost. Closing in favor of #477.
Activity
Shinrai commentedon Sep 28, 2026
Same capability as #477 (a leaf pinning its caller, not itself, onto a deferred callback). I've copied the permission gate, the principals composition, the immutability guarantee and the deadline-engine case into #477 so nothing is lost. Closing in favor of #477.