-
Notifications
You must be signed in to change notification settings - Fork 734
Return the error cases in runTxSubmit #1226
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
Conversation
cbf015e
to
0651ee5
Compare
TxSubmitFailureShelley err -> liftIO $ print err | ||
TxSubmitSuccess -> return () | ||
TxSubmitFailureShelley _ -> left (ShelleyTxSubmitError result) | ||
TxSubmitFailureByron _ -> left (ShelleyTxSubmitError result) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it not odd that we're able to submit Byron transactions from this command?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should get sorted out as we flesh out the typed API
@@ -69,6 +70,8 @@ renderShelleyTxCmdError err = | |||
"Error while writing signed shelley tx: " <> renderApiError apiError | |||
ShelleyTxWriteUnsignedTxError apiError -> | |||
"Error while writing unsigned shelley tx: " <> renderApiError apiError | |||
ShelleyTxSubmitError txSubmitRes -> | |||
"Error while submitting Shelley tx: " <> textShow txSubmitRes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should write a renderTxSubmitError
function here to provide more context with the errors vs just showing them.
bors merge |
1223: CAD-1135: Max Mempool size. r=dcoutts a=denisshevchenko Now maximum value of mempool (both txs size + txs number) aren't fixed, but it's based on real maximum values received from tracers. 1226: Return the error cases in runTxSubmit r=dcoutts a=intricate Closes #1118 1227: Yet more additions to the typed API r=dcoutts a=dcoutts Representations and serialisation for TxId, TxBody and Tx. Does not yet include round trip tests. 1229: Remove class HasTxMaxSize r=dcoutts a=dcoutts getMaxTxSize is no longer used as it has been replaced by maxTxSize from the LedgerSupportsMempool class. Co-authored-by: Denis Shevchenko <denis.shevchenko@iohk.io> Co-authored-by: Luke Nadur <19835357+intricate@users.noreply.github.com> Co-authored-by: Duncan Coutts <duncan@well-typed.com>
This PR was included in a batch that was canceled, it will be automatically retried |
bors merge |
Already running a review |
Build succeeded |
Closes #1118