Closed Miskerest closed 5 years ago
We should probably not try to push shard.tree
. Instead, we should implement the getPutblicRecord
function from the JS client. It pulls the parts of the tree that should be sent to the Bridge, and we can have it handle serialization if necessary.
👋 Hey! Thanks for this contribution. Apologies for the delay in responding!
We've decided to rearchitect Storj, so that we can scale better. You can read more about this decision here. This means that we are entirely focused on v3 at the moment, in the storj/storj repository. Our white paper for v3 is coming very, very soon - follow along on the blog and in our Rocketchat.
As this repository is part of the v2 network, we're no longer maintaining this repository. I am going to close this for now. If you have any questions, I encourage you to jump on Rocketchat and ask them there. Thanks!
shard.tree
is a MerkleTree object that is pushed to the bridge inframe_add_shard
. This throws an exception every time, because MerkleTree objects are not serializable.eg:
I'll try to resolve this, it looks like it should be fixable by changing the encoding, perhaps. The pertinent line is here: https://github.com/Storj/storj-python-sdk/blob/master/storj/http.py#L348
as well as Line 354, where
data
is assigned tojson
and then passed to the request function.I think changing L348 to
'tree': shard.tree.leaves,
might fix the issue, but then the server returns a bad response.I haven't had much time to look at it, but it looks like the encoding of
json
is incorrect when sent to the bridge, as this is the server response: