本人也在刚开始学习爬虫,出现了这个我问题,(write() argument must be str, not bytes),这里你自己看下在打开文件并写文件时,用的‘w’,还是’wb’,避免以上错误,需要在字符串前增加b将str转换为bytes,你就会发现自己的小问题了,
还有一种问题,a bytes-like object is required, not ‘method’,这种问题很神奇,你看下自己的read后面有没有括号,
相关文章:
- 2021-10-02
- 2019-02-11
- 2021-10-12
- 2021-10-02
- N/A" is not yet installed." href='/show-108125.html' target="_blank"> 2020-06-09
- 2021-08-17
- 2018-01-25
- 2018-06-27