Python3中的Socket模块发送字符串JAY.LIN 收录于 未分类 2024-08-07 约 177 字 预计阅读 1 分钟 目录 Python3中的Socket模块发送字符串最近在使用linux上的python2.7中的socket,其中可以直接用socket发送字符串,而在win10上用python3.7中的socket模块发现直接发送如s.send(‘USER test\r\n’)会失败。解法方法:改为s.send(b’USER test\r\n’)即可发送成功Please enable JavaScript to view the comments powered by Giscus.