npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@vporton/safe-bequest-module

v0.0.1

Published

Bequest module for the Gnosis Safe

Downloads

70

Readme

Bequest module

WARNING: The module was almost fully tested, but not audited. Use at your own risk.

This contract allows to bequest all funds on the wallet to be withdrawn after a given time. Moreover, after the given time the heir can execute any transaction on the inherited wallet.

Setting up bequests

The contract is designed as a single point registry. This way not every Safe needs to deploy their own module and it is possible that this module is shared between different Safes.

To set an bequest for a Safe it is first required that the Safe adds a delegate. For this a Safe transaction needs to be executed that calls addDelegate. This method will add the specified delegate for msg.sender, which is the Safe in case of a Safe transaction. The addDelegate method can be called multiple times with the same address for a delegate without failure.

To set a bequest need to call setBequest method with the heir address and the date at which the bequest becomes effective. The bequest date (the number of seconds after the epoch) and heir can be changed at any time by calling setBequest again. To cancel a bequest, call it with heir set to 0x0.

After the bequest date becomes effecive, the heir account (a simple wallet or a smart contract) can call any method on the bequested wallet using execute or executeReturnData methods.

Note: It can also be used to bequest DeFi profits: The heir can withdraw not only DeFi tokens available from the bequested wallet but also the DeFi profits gained by the wallet. So, it is a good way to bequest both money and shares.

The inheritance is probably most effective if it can be used together with "money transfer from the future" system that can be used to pay science and free software salaries and other common goods, because it allows to gain some profit from a bequest before the bequest time comes:

  • [https://vporton.github.io/future-salary/#/](the Future Salaries dApp) (as of 13 Jan 2021 it is a demo version - somebody please pay for audit of smart contracts to release it.)
  • [https://github.com/vporton/donations](the source code of Future Salaries)

Running tests

TODO: Add tests.

yarn
yarn test

Compiling contracts

yarn
yarn compile

Contract addresses

Rinkeby

BequestModule at 0x44a41A0C37E4869C6e23a2d4A1fAB61ed8B78e2a