Skip to content
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

Get block information for transaction #146

Open
SebastienGllmt opened this issue Mar 16, 2025 · 0 comments
Open

Get block information for transaction #146

SebastienGllmt opened this issue Mar 16, 2025 · 0 comments

Comments

@SebastienGllmt
Copy link

SebastienGllmt commented Mar 16, 2025

All the watch endpoints all return type TxEvent which has no information about the block the tx is included in

Probably for a lot of use-cases, these need to at least contain some minimal info about the block so that you can query the block later (ex: ChainPoint). This is what Ethereum does

For example, the proposed ReadTxs query (#143) also returns the ChainPoint. If we don't add the ChainPoint to the watch* return types, the flow will end up being

  1. Watch for txs and receive cardano.Tx
  2. Call ReadTxs on the cardano.Tx received in (1)
  3. Call fetchBlock on the ChainPoint received in (2)

It would be nice if I could go directly (1)→(3) without needing step (2), but if having step (2) as an intermediate step is the agreed-upon solution then let's get #143 merged and the process documented

I think something like this is required for #135 anyway

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

No branches or pull requests

1 participant