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

Feat/unified invoices #6421

Merged
merged 11 commits into from
Oct 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
69 changes: 69 additions & 0 deletions .msggen.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
"DecodepayFallbacksType": {
"P2PKH": 0,
"P2SH": 1,
"P2TR": 4,
"P2WPKH": 2,
"P2WSH": 3
},
Expand Down Expand Up @@ -387,6 +388,10 @@
"Connect.features": 2,
"Connect.id": 1
},
"CreateinvoicePaid_outpoint": {
"CreateInvoice.paid_outpoint.outnum": 2,
"CreateInvoice.paid_outpoint.txid": 1
},
"CreateinvoiceRequest": {
"CreateInvoice.invstring": 1,
"CreateInvoice.label": 2,
Expand All @@ -404,6 +409,7 @@
"CreateInvoice.label": 1,
"CreateInvoice.local_offer_id": 13,
"CreateInvoice.paid_at": 11,
"CreateInvoice.paid_outpoint": 17,
"CreateInvoice.pay_index": 9,
"CreateInvoice.payer_note": 14,
"CreateInvoice.payment_hash": 4,
Expand Down Expand Up @@ -988,13 +994,18 @@
"ListInvoices.invoices[].label": 1,
"ListInvoices.invoices[].local_offer_id": 9,
"ListInvoices.invoices[].paid_at": 13,
"ListInvoices.invoices[].paid_outpoint": 18,
"ListInvoices.invoices[].pay_index": 11,
"ListInvoices.invoices[].payer_note": 10,
"ListInvoices.invoices[].payment_hash": 3,
"ListInvoices.invoices[].payment_preimage": 14,
"ListInvoices.invoices[].status": 4,
"ListInvoices.invoices[].updated_index": 17
},
"ListinvoicesInvoicesPaid_outpoint": {
"ListInvoices.invoices[].paid_outpoint.outnum": 2,
"ListInvoices.invoices[].paid_outpoint.txid": 1
},
"ListinvoicesRequest": {
"ListInvoices.index": 5,
"ListInvoices.invstring": 2,
Expand Down Expand Up @@ -1566,6 +1577,10 @@
"UtxoPsbt.psbt": 1,
"UtxoPsbt.reservations[]": 6
},
"WaitanyinvoicePaid_outpoint": {
"WaitAnyInvoice.paid_outpoint.outnum": 2,
"WaitAnyInvoice.paid_outpoint.txid": 1
},
"WaitanyinvoiceRequest": {
"WaitAnyInvoice.lastpay_index": 1,
"WaitAnyInvoice.timeout": 2
Expand All @@ -1580,6 +1595,7 @@
"WaitAnyInvoice.expires_at": 5,
"WaitAnyInvoice.label": 1,
"WaitAnyInvoice.paid_at": 11,
"WaitAnyInvoice.paid_outpoint": 15,
"WaitAnyInvoice.pay_index": 9,
"WaitAnyInvoice.payment_hash": 3,
"WaitAnyInvoice.payment_preimage": 12,
Expand All @@ -1593,6 +1609,10 @@
"WaitblockheightResponse": {
"WaitBlockHeight.blockheight": 1
},
"WaitinvoicePaid_outpoint": {
"WaitInvoice.paid_outpoint.outnum": 2,
"WaitInvoice.paid_outpoint.txid": 1
},
"WaitinvoiceRequest": {
"WaitInvoice.label": 1
},
Expand All @@ -1606,6 +1626,7 @@
"WaitInvoice.expires_at": 5,
"WaitInvoice.label": 1,
"WaitInvoice.paid_at": 11,
"WaitInvoice.paid_outpoint": 15,
"WaitInvoice.pay_index": 9,
"WaitInvoice.payment_hash": 3,
"WaitInvoice.payment_preimage": 12,
Expand Down Expand Up @@ -1832,6 +1853,18 @@
"added": "pre-v0.10.1",
"deprecated": false
},
"CreateInvoice.paid_outpoint": {
"added": "v23.11",
"deprecated": false
},
"CreateInvoice.paid_outpoint.outnum": {
"added": "v23.11",
"deprecated": false
},
"CreateInvoice.paid_outpoint.txid": {
"added": "v23.11",
"deprecated": false
},
"CreateInvoice.pay_index": {
"added": "pre-v0.10.1",
"deprecated": false
Expand Down Expand Up @@ -3752,6 +3785,18 @@
"added": "pre-v0.10.1",
"deprecated": false
},
"ListInvoices.invoices[].paid_outpoint": {
"added": "v23.11",
"deprecated": false
},
"ListInvoices.invoices[].paid_outpoint.outnum": {
"added": "v23.11",
"deprecated": false
},
"ListInvoices.invoices[].paid_outpoint.txid": {
"added": "v23.11",
"deprecated": false
},
"ListInvoices.invoices[].pay_index": {
"added": "pre-v0.10.1",
"deprecated": false
Expand Down Expand Up @@ -5524,6 +5569,18 @@
"added": "pre-v0.10.1",
"deprecated": false
},
"WaitAnyInvoice.paid_outpoint": {
"added": "v23.11",
"deprecated": false
},
"WaitAnyInvoice.paid_outpoint.outnum": {
"added": "v23.11",
"deprecated": false
},
"WaitAnyInvoice.paid_outpoint.txid": {
"added": "v23.11",
"deprecated": false
},
"WaitAnyInvoice.pay_index": {
"added": "pre-v0.10.1",
"deprecated": false
Expand Down Expand Up @@ -5600,6 +5657,18 @@
"added": "pre-v0.10.1",
"deprecated": false
},
"WaitInvoice.paid_outpoint": {
"added": "v23.11",
"deprecated": false
},
"WaitInvoice.paid_outpoint.outnum": {
"added": "v23.11",
"deprecated": false
},
"WaitInvoice.paid_outpoint.txid": {
"added": "v23.11",
"deprecated": false
},
"WaitInvoice.pay_index": {
"added": "pre-v0.10.1",
"deprecated": false
Expand Down
2 changes: 1 addition & 1 deletion bitcoin/tx.c
Original file line number Diff line number Diff line change
Expand Up @@ -742,7 +742,7 @@ char *fmt_bitcoin_tx(const tal_t *ctx, const struct bitcoin_tx *tx)
return s;
}

static char *fmt_bitcoin_txid(const tal_t *ctx, const struct bitcoin_txid *txid)
char *fmt_bitcoin_txid(const tal_t *ctx, const struct bitcoin_txid *txid)
{
char *hexstr = tal_arr(ctx, char, hex_str_size(sizeof(*txid)));

Expand Down
1 change: 1 addition & 0 deletions bitcoin/tx.h
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,7 @@ void towire_bitcoin_outpoint(u8 **pptr, const struct bitcoin_outpoint *outp);
void fromwire_bitcoin_outpoint(const u8 **cursor, size_t *max,
struct bitcoin_outpoint *outp);
char *fmt_bitcoin_tx(const tal_t *ctx, const struct bitcoin_tx *tx);
char *fmt_bitcoin_txid(const tal_t *ctx, const struct bitcoin_txid *txid);

/* Various weights of transaction parts. */
size_t bitcoin_tx_core_weight(size_t num_inputs, size_t num_outputs);
Expand Down
25 changes: 25 additions & 0 deletions cln-grpc/proto/node.proto

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

44 changes: 44 additions & 0 deletions cln-grpc/src/convert.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading