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

Fixed connect to seeders print + main print #3473

Merged
merged 3 commits into from
Sep 28, 2021
Merged

Conversation

iulianpascalau
Copy link
Contributor

@iulianpascalau iulianpascalau commented Sep 28, 2021

  • fixed connect to seeders print
  • added missing log print on node start error

Testing scenario:

  1. build the node binary from master branch and run it in a new folder without the config folders. The node will close itself without printing any messages. Repeat the step from this branch: should see a log print error message.

2.a. run node (with configs) from master branch (no seeder, nothing else and log level -log-level *:DEBUG). You should see the log debug print error connecting to seeder (this is correct).
2.b. Now, change in the p2p.toml file, place these seeders:

    InitialPeerList = [
        "/dns4/gondor.mainnet.elrond.com/tcp/10000/p2p/16Uiu2HAmQihd2Di6JrDCRf6bnxXEmgfFy8C3S7WDnq7WNXscfkrG",
        "/dns4/isengard.mainnet.elrond.com/tcp/10000/p2p/16Uiu2HAkxWoEwkkxMfUgi2CkxjWkZ7cccjvh4V57gxUQQC6c45N6",
        "/ip4/188.166.192.50/tcp/10000/p2p/16Uiu2HAmT2rqgzWYnFe7YL4poyjXvKhGtrwkhaAibSDFCjGATDZ7",
        "/ip4/188.166.203.198/tcp/10000/p2p/16Uiu2HAmJeuEEczm6kLyBKAJQobVn7ARmGFQ5mPrbNVsjdhJz9s1",
    ]

you can still see the log print as debug stating error connecting to seeder and mentioning something about an unwanted peer.
2.c. re-run the same scenario with the same steps (run the node with -log-level *:DEBUG,p2p:TRACE) and for scenario 2a. you will see the print as log debug. For repeating 2b., you will see a TRACE message stating tryConnectToSeeder: unwanted peer and no log debug error connecting to seeder.

sasurobert
sasurobert previously approved these changes Sep 28, 2021
bogdan-rosianu
bogdan-rosianu previously approved these changes Sep 28, 2021
@codecov
Copy link

codecov bot commented Sep 28, 2021

Codecov Report

Merging #3473 (99a48a8) into master (ac00df9) will decrease coverage by 0.00%.
The diff coverage is 53.84%.

❗ Current head 99a48a8 differs from pull request most recent head 78cd500. Consider uploading reports for the commit 78cd500 to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3473      +/-   ##
==========================================
- Coverage   73.85%   73.85%   -0.01%     
==========================================
  Files         579      579              
  Lines       73407    73415       +8     
==========================================
+ Hits        54215    54217       +2     
- Misses      14824    14829       +5     
- Partials     4368     4369       +1     
Impacted Files Coverage Δ
p2p/libp2p/discovery/continuousKadDhtDiscoverer.go 73.10% <50.00%> (-2.81%) ⬇️
p2p/libp2p/discovery/optimizedKadDhtDiscoverer.go 79.03% <100.00%> (ø)
p2p/libp2p/netMessenger.go 75.00% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ac00df9...78cd500. Read the comment docs.

@iulianpascalau iulianpascalau changed the title Fixed connect to seeders print Fixed connect to seeders print + main print Sep 28, 2021
Copy link
Collaborator

@gabi-vuls gabi-vuls left a comment

Choose a reason for hiding this comment

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

System test passed.

@gabi-vuls gabi-vuls merged commit b11336f into master Sep 28, 2021
@gabi-vuls gabi-vuls deleted the fix-prints-in-kad-dht branch September 28, 2021 12:06
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.

None yet

4 participants