-
Notifications
You must be signed in to change notification settings - Fork 3
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
detect unconsumed/unsent messages, introduce generated dummy messages #15
Conversation
Note, currently one integration test errors due to exactly that fact:
|
06b1f43
to
c4a164e
Compare
LGTM, but I think we should add a test for this extra check and fix the failing one. |
Just tried with polkadot, and it needs to also address the case where a subsystem only actually sends messages (i.e. I am thinking of allowing an |
So the impl details are as follows:
To use this in polkadot, delete the two unused messages paritytech/polkadot#6413 |
e1c222b
to
ac6db47
Compare
I'll sign all commits, one sec, I missed that before. |
If a message type is never sent or never received, this leads to From<$ty> implementations being missing. The implementation here adds a check and throws and error pointint to the messages. Closes #13 Signed-off-by: Bernhard Schuster <bernhard@ahoi.io>
Signed-off-by: Bernhard Schuster <bernhard@ahoi.io>
Signed-off-by: Bernhard Schuster <bernhard@ahoi.io>
They need to publicly accessible after all, for the Context and Subsystem trait bounds. Signed-off-by: Bernhard Schuster <bernhard@ahoi.io>
Signed-off-by: Bernhard Schuster <bernhard@ahoi.io>
da5c278
to
8e5adf1
Compare
…#15) Error out if a message is not sent that is consumed and vice versa If a message type is never sent or never received, this leads to From<$ty> implementations being missing. The implementation here adds a check and throws and error pointing to the messages in question. It also allows to skip the consuming message without a placeholder and generated a dummy message of the form "{$ty}Message" which have to be imported for those subsystems. Closes #13 Signed-off-by: Bernhard Schuster <bernhard@ahoi.io>
If a message type is never sent or never received, this leads to From<$ty> implementations being missing.
The implementation here adds a check and throws and error pointint to the messages.
Closes #13