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

Annotate payments initiated using sendonion with the amount at the destination #3881

Merged
merged 5 commits into from
Jul 28, 2020

Commits on Jul 28, 2020

  1. pytest: Replicate the missing amount_msat in listpays

    Since we started using `sendonion` in the `pay` plugin we no longer
    automatically have the `amount` annotation on (partial) payments. This
    replicates the issue so we can fix it.
    
    Reported-by: Rusty Russell <@rustyrussell>
    cdecker authored and rustyrussell committed Jul 28, 2020
    Configuration menu
    Copy the full SHA
    afc3a7c View commit details
    Browse the repository at this point in the history
  2. db: Guard against accessing NULL partid and total_msat

    These were spamming my logs and could result in misleading results being
    returned on `listpays` and `listsendpays`.
    cdecker authored and rustyrussell committed Jul 28, 2020
    Configuration menu
    Copy the full SHA
    2ea5cbe View commit details
    Browse the repository at this point in the history
  3. jsonrpc: Add msatoshi argument to sendonion to annotate

    While not directly necessary, it still feeds the `listpays` result, and so we
    should pass it along if we can, so we don't have to rely solely on the
    `amount_sent` field, which includes the fees.
    
    Reported-by: Rusty Russell <@rustyrussell>
    cdecker authored and rustyrussell committed Jul 28, 2020
    Configuration menu
    Copy the full SHA
    8b59ff2 View commit details
    Browse the repository at this point in the history
  4. jsonrpc: Add amount received by recipient to listpays result

    We sum up the amounts just like we do with `amount_sent`, however we may have
    parts that don't have that annotation, so make it optional.
    
    Suggested-by: Rusty Russell <@rustyrussell>
    cdecker authored and rustyrussell committed Jul 28, 2020
    Configuration menu
    Copy the full SHA
    e007feb View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    315f1d3 View commit details
    Browse the repository at this point in the history