Open
Description
I try to add an asset invoice with a specific peer that is offline
a2c1cf9c97ec:/$ litcli ln addinvoice --asset_amount 44444 --asset_id 03b01073bef443026d3703511d58463687ecd668b65169bba9deefafa7a11cfd --rfq_peer_pubkey 035da0a856a9531f47efcef053c985cf02352a06eb3275fd3a6ae2fe8a17ca0887
[litcli] error adding invoice: rpc error: code = Unknown desc = error finding asset channel to use: no asset channels found for AssetSpecifier(id=03b01073bef443026d3703511d58463687ecd668b65169bba9deefafa7a11cfd, group_pub_key=) and peer=035da0a856a9531f47efcef053c985cf02352a06eb3275fd3a6ae2fe8a17ca0887
a2c1cf9c97ec:/$
and you can see it says "no asset channels found", but this is very misleading because when I run lncli listchannels
, you can see there is a channel, it is just inactive because the peer is offline:
{
"active": false,
"remote_pubkey": "035da0a856a9531f47efcef053c985cf02352a06eb3275fd3a6ae2fe8a17ca0887",
"channel_point": "beae32c09c67005b7edc175902e81b07afc5a6828093988848b316de63075870:0",
"chan_id": "70580763de16b3488898938082a6c5af071be8025917dc7e5b00679cc032aebe",
"scid": "672901116264448",
"scid_str": "612x1x0",
"capacity": "100000",
"local_balance": "50000",
"remote_balance": "46920",
"commit_fee": "2420",
"commit_weight": "958",
"fee_per_kw": "2500",
"unsettled_balance": "0",
"total_satoshis_sent": "0",
"total_satoshis_received": "0",
"num_updates": "0",
"pending_htlcs": [],
"csv_delay": 144,
"private": true,
"initiator": false,
"chan_status_flags": "ChanStatusDefault",
"local_chan_reserve_sat": "1062",
"remote_chan_reserve_sat": "1000",
"static_remote_key": false,
"commitment_type": "SIMPLE_TAPROOT_OVERLAY",
"lifetime": "1099",
"uptime": "967",
"close_address": "",
"push_amount_sat": "50000",
"thaw_height": 0,
"local_constraints": {
"csv_delay": 144,
"chan_reserve_sat": "1062",
"dust_limit_sat": "354",
"max_pending_amt_msat": "99000000",
"min_htlc_msat": "1",
"max_accepted_htlcs": 83
},
"remote_constraints": {
"csv_delay": 144,
"chan_reserve_sat": "1000",
"dust_limit_sat": "354",
"max_pending_amt_msat": "99000000",
"min_htlc_msat": "1",
"max_accepted_htlcs": 83
},
"alias_scids": [
"17592186044416000003",
"17753318155189551152",
"17789984115439910954",
"17772434811583609595",
"17848012179223763124",
"17674028143836061454",
"17649570934288698346",
"17857899905265065434"
],
"zero_conf": false,
"zero_conf_confirmed_scid": "0",
"peer_alias": "035da0a856a9531f47ef",
"peer_scid_alias": "17592186044416000000",
"memo": "",
"custom_channel_data": {
"funding_assets": [
{
"version": 1,
"asset_genesis": {
"genesis_point": "4f60b00603caf2dc752ed82d821e15dd933d1f8af9ce307fac551f1101392193:1",
"name": "Asset1",
"meta_hash": "827c23a4b1a5f4f9a9a42e61aa7bf7bf7e7925b4723728b60ad1918d632e2b0a",
"asset_id": "03b01073bef443026d3703511d58463687ecd668b65169bba9deefafa7a11cfd"
},
"amount": 200000000,
"script_key": "0250aaeb166f4234650d84a2d8a130987aeaf6950206e0905401ee74ff3f8d18e6",
"decimal_display": 3
}
],
"local_assets": [],
"remote_assets": [
{
"asset_id": "03b01073bef443026d3703511d58463687ecd668b65169bba9deefafa7a11cfd",
"amount": 200000000
}
],
"outgoing_htlcs": [],
"incoming_htlcs": [],
"capacity": 200000000,
"group_key": "020f907aaaa211319ad857f9fbbe0babe40d2277521b1b98e54b0c961b54d99923",
"local_balance": 0,
"remote_balance": 200000000,
"outgoing_htlc_balance": 0,
"incoming_htlc_balance": 0
}
},
We need to make the error message clearer to indicate that there are actually channels, they are just offline, so no RFQ could be attempted with an offline peer.