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

Option to disable incoming push amounts on channel opening #2027

Merged

Conversation

rodentrabies
Copy link
Contributor

@rodentrabies rodentrabies commented Oct 10, 2018

Implements proposal in #1884.

Progress:

  • config option and check implementation;
  • test.

Fixes #1884.

@rodentrabies rodentrabies force-pushed the no-incoming-push-amounts-option branch from 5f8e807 to 975e9a3 Compare October 10, 2018 08:36
config.go Outdated Show resolved Hide resolved
server.go Outdated Show resolved Hide resolved
@rodentrabies rodentrabies force-pushed the no-incoming-push-amounts-option branch from 975e9a3 to b124190 Compare October 11, 2018 21:30
@rodentrabies
Copy link
Contributor Author

I'm not quite sure about adding another error type (lnwire.ErrNonZeroPushAmount), but it seems ok.

@Roasbeef Roasbeef added funding Related to the opening of new channels with funding transactions on the blockchain config Parameters/arguments/config file related issues/PRs P2 should be fixed if one has time labels Oct 18, 2018
wpaulino
wpaulino previously approved these changes Oct 27, 2018
Copy link
Contributor

@wpaulino wpaulino left a comment

Choose a reason for hiding this comment

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

LGTM ⚡️

lnwire/error.go Outdated Show resolved Hide resolved
halseth
halseth previously approved these changes Nov 1, 2018
Copy link
Contributor

@halseth halseth left a comment

Choose a reason for hiding this comment

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

LGTM 👍

lnwallet/errors.go Outdated Show resolved Hide resolved
fundingmanager_test.go Show resolved Hide resolved
@rodentrabies rodentrabies force-pushed the no-incoming-push-amounts-option branch from 3a8e738 to 6f3adcd Compare November 1, 2018 23:55
@Roasbeef Roasbeef merged commit f60012b into lightningnetwork:master Nov 3, 2018
@rodentrabies rodentrabies deleted the no-incoming-push-amounts-option branch November 4, 2018 22:46
cfg.RejectPush = true
defer func() {
tearDownFundingManagers(t, alice, bob)
cfg.RejectPush = rejectPush
Copy link
Contributor

Choose a reason for hiding this comment

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

just leaving a note that this could be lead to a race condition in the unit tests if other tests are reading from cfg in parallel. we can revisit if it surfaces

Copy link
Contributor

Choose a reason for hiding this comment

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

Hm yeah, value should probably be copied to the fundingMgr config.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
config Parameters/arguments/config file related issues/PRs funding Related to the opening of new channels with funding transactions on the blockchain P2 should be fixed if one has time
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants