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

Display close_to address in listpeers #3223

Merged

Conversation

niftynei
Copy link
Collaborator

Make close-to address more visible by printing in listpeers channels.

Copy link
Contributor

@rustyrussell rustyrussell left a comment

Choose a reason for hiding this comment

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

Ack 9325204

But needs rebase to remove CHANGELOG patch.

CHANGELOG.md Outdated

### Fixed


Copy link
Contributor

Choose a reason for hiding this comment

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

Needs rebase to use Changelog-Added: instead.

json_add_string(response, "close_to_addr",
encode_scriptpubkey_to_addr(tmpctx,
get_chainparams(ld),
channel->shutdown_scriptpubkey[LOCAL]));
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we handle encode_scriptpubkey_to_addr returning NULL? The classic would be not to add the field if it's NULL...

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

good idea. updated.

@rustyrussell rustyrussell added this to the 0.7.4 milestone Nov 11, 2019
Previously, returned null if a scriptpubkey was not Segwit; now
handles encoding to Base58 for other types.
If a 'upfront_shutdown_script' was specified, show the address +
scriptpubky in `listpeers`

Changelog-added: JSON API: `listpeers` channels now include `close_to` and `close_to_addr` iff a `close_to` address was specified at channel open
Copy link
Contributor

@rustyrussell rustyrussell left a comment

Choose a reason for hiding this comment

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

Ack 87ff75a

@rustyrussell rustyrussell merged commit a333df4 into ElementsProject:master Nov 13, 2019
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.

2 participants