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

Refactor of ytsync - part 1 - SDK #71

Open
2 tasks
nikooo777 opened this issue Aug 26, 2020 · 0 comments
Open
2 tasks

Refactor of ytsync - part 1 - SDK #71

nikooo777 opened this issue Aug 26, 2020 · 0 comments

Comments

@nikooo777
Copy link
Contributor

The goal is to create an interface that exposes the main SDK functions so that we can hide all the complicated logic and better organize the code. This way we'll be able to eventually swap out the SDK for a pure GO/lbrycrd implementation.

The identified tasks of the SDK are listed here.

  • sdk
    • download wallet and blockchain.db from s3
    • start/stop sdk
    • wait for slow startup
    • clean up after shutdown
    • what we actually need the sdk for
      • publishing
        • create channel claim, sign it, send it to lbrycrd
        • create the content (aka stream) claim, sign claim with channel key
        • put claim into a transaction, sign it with private key, send the transaction to lbrycrd
        • ensure utxos are available, create utxos, select utxos for transaction (coin chooser)
        • check balance, fund account from ytsync wallet
        • check what channels are in the wallet. ensure that we're using the right wallet for the right channel, and that we have the right utxos for everything
        • don't spend staked utxos
      • transfer
        • transferring claims to creator's wallet
        • abandon tips and supports, and send them to the creator as tips
        • after transfer, retain channel's public and private keys so we can keep publishing to their channel. also retain the address that the channel claim is in, so we can tell if the channel is abandoned and make sure we don't publish duplicate videos (videos we already published) to your channel
      • metadata
        • handle old versions of claim metadata
        • update published metadata if new fields get added (may not be strictly necessary)

Must do:

  • Write an interface for the SDK
  • Move the code into an implementation
@nikooo777 nikooo777 self-assigned this Aug 26, 2020
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

1 participant