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
Remove "invalid_reason" from the vote model? #217
Comments
I also like the option of of |
or one could provide a could be:
|
Right now the transaction validation raises an exception at the first invalid condition so we don't have multiple reasons (this also increases performance). I guess that the txid would be enough for other nodes to just run he validator and find out what was wrong with the transaction. |
Since @libscott has been working on simplifying the models and adding schema validation now would be a good time to just remove it. |
BigchainDB 2.0 works differently from BigchainDB 1.3 and earlier. Invalid blocks are no longer a thing in BigchainDB 2.0. There is no need for a reason to be given for a block being invalid, since there is no block being invalid. |
I realy like this option but if you are going to do that why not make it clearer with a tx id/reason keypair instead: |
The
vote
model (documented at http://bigchaindb.readthedocs.org/en/master/models.html#the-vote-model ) for the vote-on-a-block includes an "invalid_reason":but a block may contain several invalid transactions, each one invalid for a different reason, therefore it doesn't make sense to give only one reason for voting that a block is invalid.
A node stops looking at the transactions in a block once it encounters the first invalid transaction, so it doesn't even know if there are other invalid transactions in the block, or why they are invalid.
Alternatives to removing "invalid_reason":
I prefer the latter option: replacing "invalid_reason" with "first_invalid_transaction".
The text was updated successfully, but these errors were encountered: