摘要: import gevent,time from urllib import request #urllib的io操作gevent不会识别,不会自动切换,以下方法解决 from gevent import monkey monkey.patch_all() #把当前程序的所有Io操作给我单独的做上标记 阅读全文
posted @ 2020-03-04 21:02 w_boy 阅读(875) 评论(0) 推荐(0) 编辑
摘要: 客户端 #!/usr/bin/env python #-*-coding:utf8-*- import socket HOST = 'localhost' # The remote host PORT = 8001 # The same port as used by the server s = 阅读全文
posted @ 2020-03-04 21:00 w_boy 阅读(1218) 评论(0) 推荐(0) 编辑