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

Implement a wrapper for getblock with verbosity value 2 #329

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

danielost
Copy link

Changes

  • Add get_block_txs method that calls getblock with verbosity value 2
  • Add GetBlockTxResult struct to json
  • Utilize composition in GetBlockResult and GetBlockTxResult to get rid of duplicate fields

@danielost danielost changed the title Implement getblock with verbosity value 2 Implement a wrapper for getblock with verbosity value 2 Feb 13, 2024
@0xB10C
Copy link
Contributor

0xB10C commented Apr 18, 2024

I was excited to see this when looking for a way to call getblock <hash> 2 to get the transaction fee of transactions it that block. However, the proposed implementation only deserializes the the hex field of each transaction. This is essentially the same as calling get_block_info() (if information about e.g. the next block or the number of confirmations are wanted) and get_block() for the raw transactions without any metadata.

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.

None yet

2 participants