teamgram / teamgram-server

Unofficial open source mtproto server written in golang with compatible telegram client.
https://teamgram.net
Apache License 2.0
1.8k stars 361 forks source link

Failed to compile the gateway under windows #63

Closed randydom closed 2 years ago

randydom commented 2 years ago

Although it’s not related to your code ( gnet issue ), But i can’t compile the gateway under windows , plz any suggestion(s) on that ? here’s the compile error : # github.com/panjf2000/gnet ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\connection_windows.go:140:2: cannot use interface {} value as type []byte in return argument: need type assertion ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\connection_windows.go:140:23: cannot use c (type *stdConn) as type Conn in argument to c.codec.Decode: *stdConn does not implement Conn (missing ConnID method) ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\connection_windows.go:146:36: cannot use c (type *stdConn) as type Conn in argument to c.codec.Encode: *stdConn does not implement Conn (missing ConnID method) ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\connection_windows.go:149:31: cannot use c (type *stdConn) as type Conn in argument to c.loop.eventHandler.PreWrite: *stdConn does not implement Conn (missing ConnID method) ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\connection_windows.go:151:33: cannot use c (type *stdConn) as type Conn in argument to c.loop.eventHandler.AfterWrite: *stdConn does not implement Conn (missing ConnID method) ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\connection_windows.go:254:30: cannot use c (type *stdConn) as type Conn in argument to c.loop.eventHandler.PreWrite: *stdConn does not implement Conn (missing ConnID method) ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\connection_windows.go:256:32: cannot use c (type *stdConn) as type Conn in argument to c.loop.eventHandler.AfterWrite: *stdConn does not implement Conn (missing ConnID method) ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\eventloop_windows.go:102:41: cannot use c (type *stdConn) as type Conn in argument to el.eventHandler.OnOpened: *stdConn does not implement Conn (missing ConnID method) ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\eventloop_windows.go:104:27: cannot use c (type *stdConn) as type Conn in argument to el.eventHandler.PreWrite: *stdConn does not implement Conn (missing ConnID method) ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\eventloop_windows.go:106:29: cannot use c (type *stdConn) as type Conn in argument to el.eventHandler.AfterWrite: *stdConn does not implement Conn (missing ConnID method) ..\..\..\..\..\..\..\..\pkg\mod\github.com\teamgram\gnet@v1.6.5-0.20220203114726-06bfacbd8548\eventloop_windows.go:106:29: too many errors

teamgramio commented 2 years ago

fixed