Agoric / agoric-sdk

monorepo for the Agoric Javascript smart contract platform
Apache License 2.0
303 stars 191 forks source link

Make `UserSeat`, `ZCFSeat`, into ownables #9606

Open erights opened 3 days ago

erights commented 3 days ago

https://github.com/Agoric/agoric-sdk/pull/8745 defined Ownables, implemented at https://github.com/Agoric/agoric-sdk/blob/master/packages/zoe/src/contractSupport/prepare-ownable.js with expository example at https://github.com/Agoric/agoric-sdk/blob/master/packages/zoe/test/unitTests/contracts/ownable-counter.js . This is designed so that we can often retrofit existing exos to be ownables.

See #8745 PR comment for best current explanation. In general, if holding an object confers valuable rights to do things, making those objects into ownables may usefully make that value ownable and thereby exclusively tradable, if

https://github.com/Agoric/agoric-sdk/pull/4080 explains a plan to refactor the essence of Zoe to have a separable escrow service into a new Zoe2 design. As applied to current Zoe, we can think of the result of making an offer as creating two distinct bundles of rights:

It is interesting to compare this with "intents", which also try to provide offer-safety constrained order-routing, but without the expressiveness of interacting with behavioral contracts along the way. Hopefully, we can bridge between these two worlds, giving each a window into the other.