成果:https://github.com/PrettyPanda/MyTaoBao/tree/master
成果展示:
python问题总结:
1.UnicodeEncodeError:'latin-1' codec can't encode characters in position 0-1: ordinal not in range(256) Scrapy
参考地址:
https://www.cnblogs.com/Skrillex/p/7093488.html
https://blog.csdn.net/mayuko2012/article/details/59126290
https://blog.csdn.net/csdnwws/article/details/51954825
2.python三种字符串链接方式:
https://www.cnblogs.com/chenjingyi/p/5741901.html + join %替换
3.pymysql.err.InternalError: (1366, "Incorrect string value: '\\xE7\\xAC\\x94\\xE8\\xAE\\xB0...' for column 'title' at row 1")
参考地址:https://blog.csdn.net/u011242745/article/details/51660344
4.Python uuid的使用
https://www.cnblogs.com/dkblog/archive/2011/10/10/2205200.html
5.TypeError: not all arguments converted during string formatting
缺少%s、%d
6.TypeError: 'NoneType' object is not subscriptable
7.mac配置cgi
mac自带cgi
https://blog.csdn.net/zhzdeng/article/details/52608199
加载文本,不执行脚本问题:http://blog.51cto.com/xpleaf/1740221 需要打开模块
8.httpd
https://blog.csdn.net/wangye1989_0226/article/details/72782103
9.UnicodeEncodeError: 'ascii' codec can't encode characters in position 20-24: ordinal not in range(128)
https://blog.csdn.net/love_rongrong/article/details/17119261 保存文件是得是中文
在脚本前加上如下两句即可正常显示中文。
https://blog.csdn.net/zhanyongjia_cnu/article/details/77996055
import codecs, sys
sys.stdout = codecs.getwriter('utf8')(sys.stdout.buffer)
10.End of script output before headers
脚本有问题哈
11.Permission denied: AH01241: exec of '/Users/panda/PycharmProjects/untitled/test/web/cgi/first.py' failed
权限问题
12.python like语句的问题
https://blog.csdn.net/chenxiao_ji/article/details/51332791
原文地址:http://blog.51cto.com/13496382/2114117