Skip to content

conformance test 010 and 009#45

Merged
niklaslong merged 5 commits intomasterfrom
conf_010
May 17, 2021
Merged

conformance test 010 and 009#45
niklaslong merged 5 commits intomasterfrom
conf_010

Conversation

@Mirko-von-Leipzig
Copy link
Contributor

@Mirko-von-Leipzig Mirko-von-Leipzig commented May 14, 2021

Note that this includes the missing test messages for case 009.

@niklaslong niklaslong changed the title conformance test 010 and 090 conformance test 010 and 009 May 14, 2021
Copy link
Collaborator

@niklaslong niklaslong left a comment

Choose a reason for hiding this comment

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

Looks great with a few comments, the main thing being the message kind change.

//
// Current behaviour:
//
// zcashd: Ignores the following messages
Copy link
Collaborator

Choose a reason for hiding this comment

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

Somewhat expected as the node isn't seeded with any data?

Copy link
Contributor Author

@Mirko-von-Leipzig Mirko-von-Leipzig May 14, 2021

Choose a reason for hiding this comment

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

Its.. inconsistent. I did initially seed it with blocks, and then GetBlocks, and GetData(block) work as expected.

Then one has GetData(tx) which actually returns NotFound despite not having data.

I would actually hope that all of these queries should result in an {empty} style response, or NotFound for the GetData.

Essentially I think the node never sends an empty response except for GetData(tx) - because the bitcoin protocol lists it as an example:

notfound is a response to a getdata, sent if any requested data items could not be relayed, for example, because the requested transaction was not in the memory pool or relay set. 

In the end I opted to not seed anything until we can decide what is expected and correct. Happy to add the seeding back.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Might be good to have both cases? This would also serve as documentation for the current behaviour in each case and make it easier for ECC/ZF to evaluate what the spec should be.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll split up the test case into seeded and unseeded

@Mirko-von-Leipzig Mirko-von-Leipzig force-pushed the conf_010 branch 5 times, most recently from 555c2d3 to 661d138 Compare May 17, 2021 08:43
@Mirko-von-Leipzig Mirko-von-Leipzig marked this pull request as ready for review May 17, 2021 08:54
@Mirko-von-Leipzig
Copy link
Contributor Author

I've changed to using a macro for the enum asserts. Let me know what you think.

Copy link
Collaborator

@niklaslong niklaslong left a comment

Choose a reason for hiding this comment

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

Looking good other than a few small things, love the macro 🎉

@niklaslong niklaslong merged commit 5957afa into master May 17, 2021
@niklaslong niklaslong deleted the conf_010 branch May 17, 2021 11:57
zeapoz pushed a commit to zeapoz/zcash that referenced this pull request Apr 13, 2023
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

Successfully merging this pull request may close these issues.

2 participants

Comments