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

feat: add support for displaying the P2P Address for node secrets info #2361

Merged
merged 4 commits into from
Jun 19, 2024

Conversation

zivkovicmilos
Copy link
Member

@zivkovicmilos zivkovicmilos commented Jun 15, 2024

Description

Closes #1922

This PR introduces a new section to the Node P2P Info secrets output, that displays the P2P connection address.
The secrets fetch command remains unchanged, and this info can be displayed by calling gnoland secrets get NodeKey

It displays the following values:

  • if the config is not initialized yet, the default p2p listen address is used
  • if the config is initialized, the p2p listen address value is used
Screenshot 2024-06-19 at 10 59 48

These values will be easily fetch-able when we introduce json output support for these outputs in #2301

cc @mazzy89

Contributors' checklist...
  • Added new tests, or not needed, or not feasible
  • Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory
  • Updated the official documentation or not needed
  • No breaking changes were made, or a BREAKING CHANGE: xxx message was included in the description
  • Added references to related issues and PRs
  • Provided any useful hints for running manual tests
  • Added new benchmarks to generated graphs, if any. More info here.

Copy link

codecov bot commented Jun 15, 2024

Codecov Report

Attention: Patch coverage is 80.00000% with 4 lines in your changes missing coverage. Please review.

Project coverage is 54.64%. Comparing base (e7e47d2) to head (3286abe).

Files Patch % Lines
gno.land/cmd/gnoland/secrets_get.go 80.00% 2 Missing and 2 partials ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           master    #2361   +/-   ##
=======================================
  Coverage   54.63%   54.64%           
=======================================
  Files         581      581           
  Lines       77967    77987   +20     
=======================================
+ Hits        42598    42614   +16     
- Misses      32190    32192    +2     
- Partials     3179     3181    +2     
Flag Coverage Δ
gno.land 61.95% <80.00%> (+0.08%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mazzy89
Copy link
Contributor

mazzy89 commented Jun 15, 2024

Thank you @zivkovicmilos to bring this in. It certainly improves the bootstrap experience.

One small feedback. WOuld it make sense to call the command NodeId rather than NodeKey. What is the rationale behind the choice of word NodeKey?

Copy link
Contributor

@r3v4s r3v4s left a comment

Choose a reason for hiding this comment

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

I don't think printing protocol (tcp://) is necessary.
Other than that LGTM 👍

@zivkovicmilos
Copy link
Member Author

@r3v4s
Thank you for the heads up about the protocol part of the P2P address 🙏

I've resolved it in:
dc9a07e

@zivkovicmilos
Copy link
Member Author

@mazzy89

I've updated it to NodeID, since we display more information now 👍

Thank you for the suggestion 🙏

846f8dc

@zivkovicmilos zivkovicmilos merged commit 6032b48 into master Jun 19, 2024
7 checks passed
@zivkovicmilos zivkovicmilos deleted the dev/zivkovicmilos/secrets-node-id branch June 19, 2024 09:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📦 ⛰️ gno.land Issues or PRs gno.land package related
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

[chain] Add a get-node-id flag to gnoland secrets // multi-node related
5 participants