Skip to content

Delay with confirming transaction due to insufficient fee #71

@thrasher-

Description

@thrasher-

Hey Hank,

As discussed via email, there appears to be an issue with the fee calculation when someone sends an amount to an address, and creates an output which is less then Litecoin Core's dust threshold value (0.001 LTC).

An example of a troublesome transaction can be seen below:
http://ltc.block-explorer.com/tx/6080e37e9eb509e4e732b590993ce91cd5a0fbbc5cb319f1da7ea63c3fa0d947

In this transaction, an output was created with a value of 0.00023934 LTC, thus being flagged as a dust transaction. Litecoin Core expects a 1000 byte penalty for every output below the dust threshold. After this, it also rounds up the transaction to the nearest 1000. Code for the penalty can be seen here:
https://github.com/litecoin-project/litecoin/blob/master-0.10/src/main.cpp#L917

And for the rounding up calculation:
https://github.com/litecoin-project/litecoin/blob/master-0.10/src/amount.cpp#L18

For this transaction, an error message was created when accepting it into the mempool on Litecoin Core:

ERROR: AcceptToMemoryPool : not enough fees 6080e37e9eb509e4e732b590993ce91cd5a0fbbc5cb319f1da7ea63c3fa0d947, 100000 < 200000

I'd imagine a solution to this problem would be:
a) If an output is made with an amount less then the dust threshold, add it to the transaction fee.
b) Add a fee penalty for every transaction output which is below the dust threshold.

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