hindley-milner-systems / dapp-ertp-airdrop

0 stars 2 forks source link

contract shutdown operations #41

Closed tgrecojs closed 1 month ago

tgrecojs commented 7 months ago

in order to properly shut down the contract, we first need to:

  1. burn any tokens that still remain with the conract's airdropPurse
  2. write any metrics to vstorage that need recording
  3. zcf.shutdown('insert any last words...')
linear[bot] commented 7 months ago

LAR-97 contract shutdown operations

dckc commented 6 months ago

when (under what conditions) does the contract shut down?

tgrecojs commented 6 months ago

working on getting the fine print on this.

here are some possible scenarios:

  1. a predetermined time range during which users can claim tokens has elapsed.
  2. the number of tokens minted has reached the contracts predetermined maximum supply cap.

note: I'm not sure if these scenarios warrant a complete contract shutdown, or if there is a better approach to take (at some point in time when contract must cease to make certain operations available).

dckc commented 6 months ago

Having the contract shut down is desirable, since it frees up resources.

tgrecojs commented 3 months ago

I've recently added this in one of the timer-based methods. The gist of it is - it ensures that the contract shuts down once the clock has struck midnight for the final epoch in an airdrop. @dckc

https://github.com/hindley-milner-systems/dapp-ertp-airdrop/blob/2e6ed388628ad782cc483a3d5fb8742221e74b7f/contract/src/airdrop/airdropKitCreator.js#L203-L205

dckc commented 3 months ago

nifty.

I'm curious why this is still open. Did you mean to close it? Or is there more to do? a test or something?

tgrecojs commented 1 month ago

oversight - closing