Skip to content

Migrate faucet to using a network account #261

Description

@igamigo

Originally discussed here.
The idea is that, to avoid modifying the standard account components, on genesis we can prefund a set of accounts to allow for the different services to work well.

The faucet could be modified to be deployed as a network account which gets operated by a wallet which the UI controls. Basically, in terms of specific changes:

  • The faucet backend now cares about 2 accounts: the network faucet, and the faucet operator (which is a local account)
  • We should make it so that both the network account ID and operator accounts are provided at instantiation time. The main faucet client really only cares about the latter of these, since it will be the one that drives the network account
  • The UI now collects requests with solved PoW challenges, and basically uses the wallet to emit one network note per each request and sends it to the network faucet (the request/network note). It's unclear to me whether a single network note can carry information for minting multiple asset notes (we'd have to look into the faucet standard) but it'd be ideal if it could, to avoid bloating the network with mint requests.

Some points:

  • Since the minting process now really takes 2 transactions, there's more end-to-end latency
  • It's not super clear whether we can easily provide the same flows after having minted the notes. For example, the network faucet will not be able to use the NTL to send private notes. I think we should be able to know all the details from the asset notes beforehand, so after minting we can decide to instantly provide a NoteFile that users/wallets can import. We could also poll the node from the frontend to see when the end asset note gets created
  • Should we provide other operator transactions?

cc @bobbinth

Metadata

Metadata

Assignees

No one assigned

    Labels

    backendRelated to th the backend componentsfrontendRelated to the front end components.

    Fields

    Priority

    High

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions