-
Notifications
You must be signed in to change notification settings - Fork 922
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
add max_total_htlc_out to listpeerchannels #8084
add max_total_htlc_out to listpeerchannels #8084
Conversation
7f6a22d
to
9330714
Compare
Gah, this requires more work. I will rebase on #8089 once that is merged! |
bca0265
to
391119d
Compare
391119d
to
e69ecbd
Compare
4b10c23
to
0ed14c3
Compare
But then we later query against all these fields, which isn't allowed for deprecated columns( |
b31e91f
to
2a56e44
Compare
2a56e44
to
cfa069f
Compare
Otherwise, deprecating a field causes SELECT * to fail: ``` > l1.rpc.sql(f"SELECT * FROM peerchannels;") ... > raise RpcError(method, payload, resp['error']) E pyln.client.lightning.RpcError: RPC call failed: method: sql, payload: ('SELECT * FROM peerchannels;',), error: {'code': -1, 'message': 'query failed with access to peerchannels.max_total_htlc_in_msat is prohibited (Deprecated column table peerchannels.max_total_htlc_in_msat)'} ``` So if they use a wildcard, allow access: though "SELECT *" is fraught, "COUNT(*)" is perfectly legit. Signed-off-by: Rusty Russell <[email protected]>
db089e7
to
4b81a5c
Compare
Changelog-Added: JSON-RPC: `listpeerchannels` new output fields `their_max_total_htlc_out_msat` and `our_max_total_htlc_out_msat` as the value of `max_htlc_value_in_flight` (as of BOLT02) set by the local and remote nodes on channel creation. Changelog-Deprecated: JSON-RPC: `listpeerchannels` value `max_total_htlc_in_msat`: use `our_max_total_htlc_out_msat` instead to follow spec naming convention.
Signed-off-by: Rusty Russell <[email protected]>
The parameter max_htlc_value_in_flight_msat stablished by peers on channel opening (BOLT02) can now be retrived from the gossmods_from_listpeerchannels API. Adapted the corresponding callback functions in renepay and askrene to take into account that value as a constraint to the value we can send through a channel. Changelog-Add: fetch max_htlc_value_in_flight_msat from gossmods_listpeerchannels API Signed-off-by: Lagrang3 <[email protected]>
Signed-off-by: Rusty Russell <[email protected]>
4b81a5c
to
9b32ea4
Compare
with fixed our/their_max_htlc_value_in_flight_msat values suggested by @ShahanaFarooqui
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK 986245f
This was #7193 but I closed that by accident.