Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

fixed incorrect decoding of header seal_fields. added tests. #1090 #1094

Merged
merged 2 commits into from
May 17, 2016

Conversation

debris
Copy link
Collaborator

@debris debris commented May 17, 2016

No description provided.

@debris debris added the A0-pleasereview 🤓 Pull request needs code review. label May 17, 2016
@gavofyork
Copy link
Contributor

what makes you think this is incorrect?

unless something (everything) changed since i wrote this code, it is correct.

@gavofyork gavofyork added A4-gotissues 💥 Pull request is reviewed and has significant issues which must be addressed. and removed A0-pleasereview 🤓 Pull request needs code review. labels May 17, 2016
@debris
Copy link
Collaborator Author

debris commented May 17, 2016

please see this comment https://github.com/ethcore/parity/issues/1090#issuecomment-219620535 and tests attached to pr

@@ -219,8 +219,8 @@ impl Header {
s.append(&self.timestamp);
s.append(&self.extra_data);
if let Seal::With = with_seal {
for b in &self.seal {
s.append_raw(&b, 1);
for b in &self.seal {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

self.seal is a vector of post-RLP-encoded fields. It is not pre-RLP-encoded data. The reason for this is to allow for complex fields as part of the seal without having meta-RLP within the header.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see... than we have inconsistency in HeaderView struct, cause it returns pre-RLP-encoded data. I will update the pr.

@debris debris added A0-pleasereview 🤓 Pull request needs code review. and removed A4-gotissues 💥 Pull request is reviewed and has significant issues which must be addressed. labels May 17, 2016
@debris
Copy link
Collaborator Author

debris commented May 17, 2016

updated the pr

@gavofyork gavofyork added A8-looksgood 🦄 Pull request is reviewed well. and removed A0-pleasereview 🤓 Pull request needs code review. labels May 17, 2016
@debris debris merged commit dcc695d into master May 17, 2016
@debris debris deleted the seal_fields_fix branch May 17, 2016 09:47
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A8-looksgood 🦄 Pull request is reviewed well.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants