pymongo工具类
摘要:from itemadapter import ItemAdapter import pymongo class Mongo_Client(object): def __init__(self,collection_name): self.clinet = pymongo.MongoClient("
阅读全文
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x83 in position 0: invalid start byte
摘要:“'Accept-Encoding': 'gzip, deflate'” 这一条是我从Fiddler直接复制过来的,为什么用浏览器可以正常浏览,而用Python模仿就不行呢? 综合网上的解释: 这句话的意思是本地接收压缩格式的数据,服务器传过来压缩格式gzip的文件,而解压这种gzip文件只能用de
阅读全文
python 相关
摘要:python判断文件是否存在 os.path.exists(file_path): python多线程 p1 = threading.Thread(target=down) t1 = threading.Thread(target=crawl) print("启动") p1.start() t1.s
阅读全文