panic: concurrent write to websocket connection

#2 · closed · 1 comments

View on GitHub ↗

codeskyblue

2025/07/21 15:36:38 [Info] server.go:95 transport tcp test.proxyloal.com:80 panic: concurrent write to websocket connection goroutine 850 [running]: github.com/gorilla/websocket.(*messageWriter).flushFrame(0xc000366cc0, 0x1, {0x0?, 0x4711f9?, 0x30?}) /Users/codeskyblue/Codes/proxylocal/vendor/github.com/gorilla/websocket/conn.go:617 +0x4af github.com/gorilla/websocket.(*messageWriter).Close(0xc0003b0760?) /Users/codeskyblue/Codes/proxylocal/vendor/github.com/gorilla/websocket/conn.go:731 +0x35 github.com/gorilla/websocket.(*Conn).beginMessage(0xc000126420, 0xc0002e14d0, 0x1) /Users/codeskyblue/Codes/proxylocal/vendor/github.com/gorilla/websocket/conn.go:480 +0x37 github.com/gorilla/websocket.(*Conn).NextWriter(0xc000126420, 0x1) /Users/codeskyblue/Codes/proxylocal/vendor/github.com/gorilla/websocket/conn.go:520 +0x3f github.com/gorilla/websocket.(*Conn).WriteJSON(0x89f6c0?, {0x89f6c0, 0xc0002e14a0}) /Users/codeskyblue/Codes/proxylocal/vendor/github.com/gorilla/websocket/json.go:24 +0x34 github.com/codeskyblue/proxylocal/pxlocal.(*webSocketTunnel).RequestNewConn(0xc00010a510, {0xc0002f88b0, 0x2}) /Users/codeskyblue/Codes/proxylocal/pxlocal/server.go:76 +0x166 github.com/codeskyblue/proxylocal/pxlocal.(*webSocketTunnel).generateTransportDial.func1({0x8e502b?, 0x4711f9?}, {0xc00033f240, 0x1e} ) /Users/codeskyblue/Codes/proxylocal/pxlocal/server.go:96 +0xb6 net/http.(*Transport).dial(0x0?, {0x996488?, 0xc0002c5180?}, {0x8e502b?, 0x0?}, {0xc00033f240?, 0x0?}) /opt/homebrew/Cellar/go/1.24.4/libexec/src/net/http/transport.go:1285 +0x5

Comments

Copilot

@codeskyblue Unfortunately I hit an unexpected error while trying to work on issue #2. I've automatically reported this to GitHub. You can ask me to try again later by unassigning and then reassigning the issue to me again. If you want to contact GitHub about this error, please mention the following identifier so they can better serve you: `c44c9d0c-c8d8-4250-9991-8630c8d1d8d0` Sorry for the inconvenience! <!-- copilot-coding-agent-error: issue-generic-error -->