摘要: Enclose in parentheses: except (IDontLIkeYouException, YouAreBeingMeanException) as e: passSeparating the exception from the variable with a comma will still work in Python 2.6 and 2.7, but is now... 阅读全文
posted @ 2013-09-18 14:45 紫红的泪 阅读(612) 评论(0) 推荐(0) 编辑
摘要: Use __new__ when you need to control the creation of a new instance. Use __init__ when you need to control initialization of a new instance. __new__ is the first step of instance creation. It's ... 阅读全文
posted @ 2013-09-18 11:35 紫红的泪 阅读(560) 评论(0) 推荐(0) 编辑
摘要: 发现找不到matplotlib.sphinxext.mathmpl: 可以直接easy_install matplotlib,也可以去这里下载安装包 发现exception: matplotlib requires dateutil错误: 到这里找dateutil安装包(坑爹的easy_install里找不到这个包) 发现exception: matplotlib requ... 阅读全文
posted @ 2013-09-18 11:32 紫红的泪 阅读(2056) 评论(0) 推荐(0) 编辑