Skip to content

Duplicate Transactions Blocked When Using Identical Parameters from wallet/getblock Within the Same Block #639

@web3bon

Description

@web3bon

When constructing transactions locally using TronWeb, the block parameters (e.g., block number, block timestamp, etc.) are fetched via the wallet/getblock endpoint. These parameters remain constant within the same block. As a result, if multiple transactions are constructed with identical parameters within the same block (e.g., within the same second), the second transaction is considered a duplicate and cannot be broadcast.

Expected Behavior:
Multiple transactions constructed in quick succession should be assigned unique or sufficiently differentiated parameters to allow them to be submitted within the same block.

Actual Behavior:
Transactions constructed with the same block reference and identical input are treated as duplicates, preventing the second transaction from being accepted or broadcasted.

Steps to Reproduce:

Use TronWeb to construct a transaction using parameters from wallet/getblock.

Immediately construct a second transaction with the same inputs and parameters.

Attempt to broadcast both transactions.

Observe that the second transaction is rejected or ignored.

Suggestion:
Introduce a mechanism in TronWeb to:

Fetch fresh block references if needed.

Allow setting custom or updated transaction parameters.

Include a nonce-like mechanism or unique salt to differentiate transactions created within the same block.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions