CodeChain-io / CodeChain-io/foundry

ConnectionEstablished is called in an already established connection

Aperta
#274 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
bug
Lingua principale
Rust
Stelle
36
Fork
11
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

Recently, discovery5 tests failed occasionally.
I read the failed test log and found that a connection established event is fired in the already existing connection. It made Foundry crash.

## Why this error found nowadays

Recently when we implementing a peer DB, we added an assertion that the same peer is not added twice in the DB. The assertion made Foundry panic.
It seems that the duplicated connection established event bug is aged, but recently found by the assertion.

## How should we fix it

The "connection established" event should not be called in an existing connection.

## ErrorLog

[2020_03_18T01_56_17_226Z.1.log](https://github.com/CodeChain-io/foundry/files/4346655/2020_03_18T01_56_17_226Z.1.log)
[2020_03_18T01_56_17_226Z.4.log](https://github.com/CodeChain-io/foundry/files/4346656/2020_03_18T01_56_17_226Z.4.log)

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.