Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creating an SBD supply for testnet #1803

Open
theoreticalbts opened this issue Nov 27, 2017 · 4 comments
Open

Creating an SBD supply for testnet #1803

theoreticalbts opened this issue Nov 27, 2017 · 4 comments

Comments

@theoreticalbts
Copy link
Contributor

In #1802, @mvandeberg suggests brainstorming ways to create SBD for the testnet. Here are some options:

  • (a) Create SBD on a particular account at genesis
  • (b) Implement a testnet-only operation to create SBD
  • (c) Do the same things to create testnet SBD as the main network (posting, voting, claiming rewards)

Personally, I am in favor of option (c) for the following reasons:

  • Exercise more code paths on testnet
  • Minimize the amount of testnet-only code
  • Make testnet as similar as possible to the main network

Since the testnet initialization scripts are already designed to create simulated activity arbitrarily far in the past, it shouldn't be too hard to figure out how to SBD creation. This will also help create content for the testnet even immediately at launch.

@mvandeberg
Copy link
Contributor

I am in favor of (a) and (c).

We already create the init miner with a STEEM supply. Creating an amount of SBD is easy enough. The trick is that once SBD exists, we need a price feed, which requires yet more testnet only code. This brings up the interesting scenarios of what happens if all witnesses stop publishing a price feed on the main net? If that occurs, Steem is likely already dead, so it may not matter, but I am not sure if we have thought through that scenario.

The problem with relying on just (c) is that for an account to test creating an SMT on the testnet with SBD, they need to create a post, vote on it, and wait for the payout. If there are multiple rounds of testnets, that becomes quite burdensome.

We can have the default witnesses publish an extremely high price feed to allow printing of many SBD for a single post, but this seems like as much of a testnet hack as (a).

@theoreticalbts
Copy link
Contributor Author

for an account to test creating an SMT on the testnet with SBD, they need to create a post, vote on it, and wait for the payout. If there are multiple rounds of testnets, that becomes quite burdensome.

The testnet initialization scripts already fully support creating blocks with timestamps in the past containing transactions that initialize some state. Creating a post, voting on it, and waiting for payout can be done in the past using that architecture, once the code is written it will be done automatically by the setup script. The workflow for setting up a new testnet will be just run the script, wait a bit for it to create blocks, and you have a particular account that has a bunch of TBD you can do whatever you want with.

With the way the testnet setup script architecture is designed, (c) is just as convenient as option (a), but the code to implement it lives outside Steemd in a Python script.

@mvandeberg
Copy link
Contributor

But what if I am a potential SMT creator that has not used Steem before, but want to test SMT integration on the testnet? Then there is no history to import and once the test net is live there is no easy way of acquiring SBD other than asking for some. I think creating an initial supply is the best way of handling this.

@dnotestein
Copy link

We've implemented an initial supply as part of the steem proposal work (for our testing purposes).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants