调试Python程序:
unique_key = name + time.mktime(create_time.timetuple())
TypeError: coercing to Unicode: need string or buffer, float found
错误原因:使用“+”拼接会抛出异常,改用%操作符输出
unique_key = u'%s%s' % (name, time.mktime(create_time.timetuple()))