Closed tnull closed 1 year ago
LDKLite should just expose PaymentClaimed
, ie that we have received and claimed a payment, not PaymentReceived
, which it should just handle by calling claim_payment.
Yes, this is also what I'm leaning towards, only issue being that I find PaymentReceived
a much more intuitive name to use for this event in LDK Lite, which however would shadow the upstream event with different meaning, i.e., would be pretty confusing if someone is aware of LDK Events already. I'll have to think about whether there is a good alternative naming for it.
For the record, I'd find using something along the lines of PaymentIncoming
/ PaymentReceived
also more intuitive than PaymentReceived
/PaymentClaimed
upstream, since PaymentReceived
sounds pretty final by itself, even though it's actually not.
For the record, I'd find using something along the lines of PaymentIncoming / PaymentReceived also more intuitive than PaymentReceived/PaymentClaimed upstream, since PaymentReceived sounds pretty final by itself, even though it's actually not.
+1, I've gotten similar feedback about PaymentReceived
being a confusing name
+1, I've gotten similar feedback about
PaymentReceived
being a confusing name
Thanks, good to know, then maybe the solution could indeed be renaming the upstream event..
Any suggestions for a better one? We should totally rename it upstream if it makes sense.
Any suggestions for a better one? We should totally rename it upstream if it makes sense.
As mentioned above (in an edit), maybe something along the lines of
PaymentReceived
-> PaymentIncoming
/ PaymentInbound
PaymentClaimed
-> PaymentReceived
?
PaymentClaimable
? But I'm fine with all the above too^
Any of those SGTM, feel free to PR :)
PaymentClaimable
? But I'm fine with all the above too^
Ah, that's even better! Now the only thing is that the migration PaymentClaimed
->PaymentReceived
might be a pitfall for users as their code for the former PaymentReceived
event might just keep on working for the wrong event without them noticing.
Maybe after #1886 tho.
Any of those SGTM, feel free to PR :)
Alright, will open a PR tomorrow/in the next days!
Closing as clarified, will update after upstream event has been merged.
Having
PaymentReceived
andPaymentClaimed
in LDK Lite might be a bit verbose for the 'simplified' API.If we only want to have one, i.e.,
PaymentReceived
event, it raises the question when we should emit it: on receivingPaymentReceived
orPaymentClaimed
?Or do we want to mirror both events here after all?