-
Notifications
You must be signed in to change notification settings - Fork 406
channel_reserve_satoshis variable names confusing #181
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
Comments
Hmm, I don't think flipping it on its head is any more clear, it was the value provided by them ie its not our own setting, but, indeed, we have to have it towards us. We could rename it something like min_channel_reserve_to_self to make that more clear? |
Now I am not confused as you clearly stated, and agree that flipping wouldn't make any clear. I added some comments in #189 and think that would suffice to prevent confusion. |
Reopening because I'd agree these names are confusing, as pointed out as well by @ariard here. I think it's effectively "our setting," so would be fine to just flip it, but since people seem to disagree I'm open to something along the lines of |
My two sats: Who is doing the setting is irrelevant once the setting is in place and is thus extraneous information. In the context of a channel, all that matters is what side the reserve applies to. IMHO, "local" and "remote" seem descriptive enough in this case. However, I haven't put much thought into whether there are more suitable names for this concept. |
In the spec,
And, as my understanding, this means it's the value that the node receiving Open/AcceptChannel should keep.
We do
channel.thier_channel_reserve_satoshis = msg.channel_reserve_satoshis
So
channel.their_channel_reserve_satoshis
is used when checking conditions for our channel reserve and I found it pretty confusing.Perhaps,
channel.our_channel_reserve_satoshis = msg.channel_reserve_satoshis
and
Channel::get_their_channel_reserve_satoshis
is better?The text was updated successfully, but these errors were encountered: