logos-co / nomos-node

Nomos blockchain node
38 stars 13 forks source link

Remove duplicate error log in network service #638

Closed youngjoon-lee closed 2 months ago

youngjoon-lee commented 2 months ago

This is a very simple PR.

Because we're already printing a log with a proper log level according to the error type in the upper layer, we can remove the duplicate log in the swarm.rs. That log is actually very annoying because one of these error types always happen when a node A is trying to dial to itself for creating a p2p stream (to send mix packets). That type of log doesn't need to be printed with the ERROR level because it's ignored in the upper layer.

p.s. We may be able to improve the logic to not try to dial if the peer address is mine, but I couldn't find any sophisticated way to check if the address is mine.