Seems spoolio piece registration was never documented in this repo
@r-marques @diminator I remember that one day we switched from registring only editions to registering the piece first and then optionally the editions.
Correct?
Then am I right in assuming that this specification currently doesn't mention the piece registration. If so, I'm happy to dive into spoolio to find out how it was done. If you have memories where that code resides, it'd be helpful.
Edit: looks like we have a bingo: https://github.com/ascribe/pyspool/blob/f8b10df1e7d2ea7950dde433c1cb6d5225112f4f/spool/spool.py#L99
I'm not sure if the the SPEC was ever updated but all the verbs we were using are here https://github.com/ascribe/pyspool/blob/f8b10df1e7d2ea7950dde433c1cb6d5225112f4f/spool/spoolverb.py
From what I remember the flow was:
- write the piece on chain Piece ->
ASCRIBESPOOL01PIECE - write the number of editions on chain ->
ASCRIBESPOOL01EDITIONS10
and that was it to register a new piece
When transfering:
- first regist the edition to transfer on chain ->
ASCRIBESPOOL01REGISTER1(lazy editions to protect ascribe wallet) - then transfer the newly registered edition ->
ASCRIBESPOOL01TRANSFER1