Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Connection failure with localhost

Aperta
#431 3 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
haskell

Direzione di ricerca

Esamina il commit 21cd334ef3aa78e2039eff3874fc2d63ea3cd6af, iniziando dalla chiamata a N.getAddrInfo e da decodeSockAddr intorno alla riga dell'errore collegata. Riproduci una connessione usando localhost su un sistema che lo risolve in ::1, quindi verifica che le connessioni a localhost non falliscano più mentre il comportamento IPv4 rimane intatto.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

network-transport-tcp

I'm observing failures when trying to connect and send messages to localhost:

TransportError ConnectFailed "Network.Socket.recvBuf: resource vanished (Connection reset by peer)"

I did not construct a minimal example, but I've traced the issue to the following commit to network-transport-tcp. In particular the original failure occurs in this line. The issue is that at this point sockAddr has the value ::1 but decodeSockAddr only supports IPv4 addresses. Adding a dummy case that handles IPv6 and always returns 127.0.0.1:<port> fixes the connection failures in my case.
The IPv6 address originates from this call to N.getAddrInfo when host="localhost".
A work-around is to always use 127.0.0.1 instead of localhost.
This depends on system configuration, as the issue was only observed on some machines.

Lingua principale
Haskell
Stelle
754
Fork
101
Merge medio
1g 3h
PR unite (30g)
4

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di haskell-distributed/distributed-process

Tutte le issue di haskell-distributed/distributed-process

Issue simili

Altre issue su Haskell

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.