-
Notifications
You must be signed in to change notification settings - Fork 8
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
Attach signer information to tx(s) endpoints #152
Conversation
This will allow us to join from transactions to their signers
@@ -0,0 +1,2 @@ | |||
ALTER TABLE signers DROP CONSTRAINT signers_pkey; |
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 also change the primary key in haskell-src/lib/ChainwebDb/Types/Signer.hs
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.
Nice catch!
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.
Funny enough, the Haskell code already looks like it's declaring the first column of the primary key to be requestkey
:
primaryKey = SignerId <$> _signer_requestkey <*> _signer_idx |
Seems like beam
is being very haphazard here.
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.
LGTM
This PR adds the signers list to the `TxDetail` type in order to support kadena-io/chainweb-data#152 which is a requirement for adding the signers information to the `txdetail` view of the block explorer. * Add Signers list to TxDetail * Add signatures to TxDetail
This PR is an amendment to #152, where we omitted the `sigs` field by oversight. * Add sigs field to tx detail responses * Bump CWA pin after merging API changes
This PR adds the "Signers" and "Signatures" fields to the `txdetail` view. These new fields display the new `TxDetails` fields of the `chainweb-data` API added by kadena-io/chainweb-data#152 and kadena-io/chainweb-data#153. We used to have this information in the block transactions view before we redesigned that view to be a table of brief information about each transaction, each row linking to the corresponding `txdetail` page, losing the Signers and Signatures information in the process. This PR recovers these fields for the `block-explorer`. * Add Signers and Signatures fields to txdetail view * Remove Account and Scheme fields if they're empty * Rename Account field to Address * Separate the args of sig capabilities * Let txDetailPage accept a NonEmpty list * Rename txDetails * Add separators to signatures
This PR adds the
_txDetail_signers :: [Signer]
field to theTxDetail
served by theGET /txs/tx
andGET /txs/txs
endpoints.Additionally:
ToSchema
types for the OAS3 spec.signers
table so that the primary key index supports efficient signer lookups.