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

Fix inbound_liquidity_msats #1062

Merged

Conversation

danielgranhao
Copy link
Contributor

Addresses #1018

@danielgranhao danielgranhao force-pushed the 05-08-2024-fix-inbound-liquidity-msats branch from 515f632 to 25b7b4e Compare August 5, 2024 14:28
@danielgranhao danielgranhao marked this pull request as ready for review August 5, 2024 14:29
Copy link
Contributor

@ok300 ok300 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, added just a NIT on comments.

libs/sdk-core/src/models.rs Show resolved Hide resolved
@ok300 ok300 requested review from roeierez and JssDWt August 5, 2024 15:32
Copy link
Contributor

@JssDWt JssDWt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just have one nit, looking good!

libs/sdk-core/src/models.rs Outdated Show resolved Hide resolved
@danielgranhao danielgranhao force-pushed the 05-08-2024-fix-inbound-liquidity-msats branch from 13913a3 to ee25097 Compare August 5, 2024 17:52
@@ -187,6 +187,7 @@ dictionary NodeState {
u64 max_single_payment_amount_msat;
u64 max_chan_reserve_msats;
sequence<string> connected_peers;
u64 max_receivable_single_payment_amount_msat;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now that we add this field the former one (inbound_liquidity_msats) changes its semantic.
My concern is that developers will upgrade and their logic will break without them knowing about it.
Can we rename the inbound_liquidity_msats so developers will get a compilation error on upgrade which will force them to change the code?
We can also leave it with the old semantic (and mark it as deprecated) and add another field (total_inbound_liquidity_msat) with the unified liquidity.
Anything that will not let this change go under the radar.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a very good point @roeierez. I'll rename it to total_inbound_liquidity_msat.

@danielgranhao danielgranhao force-pushed the 05-08-2024-fix-inbound-liquidity-msats branch from 8e43501 to 544c928 Compare August 6, 2024 08:45
@danielgranhao danielgranhao force-pushed the 05-08-2024-fix-inbound-liquidity-msats branch from 544c928 to c51d212 Compare August 6, 2024 08:51
@roeierez roeierez requested a review from JssDWt August 7, 2024 07:20
Copy link
Contributor

@JssDWt JssDWt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@roeierez roeierez merged commit 74a8208 into breez:main Aug 8, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants