# read tcp 127.0.0.1:8080->127.0.0.1:5000: read: connection reset by peer

- **ID:** `go/io-reader-error`
- **Domain:** go
- **Category:** network_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

The remote peer forcibly closed the connection during a read operation, causing an io.Read error.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 1.21 | active | — | — |

## Workarounds

1. **** (70% success)
   ```
   if netErr, ok := err.(net.Error); ok && netErr.Timeout() { /* handle timeout */ }
   ```
2. **** (80% success)
   ```
   Re-establish the connection on error
   ```

## Dead Ends

- **** — Connection is already closed, retry won't work (90% fail)
- **** — Leads to incomplete data (80% fail)
