sk1418 / zhuaxia

download mp3 files/albums from xiami.com and music.163.com
Other
410 stars 83 forks source link

'ascii' codec can't encode character u'\u9996' in position 0 #48

Closed hailinzeng closed 7 years ago

hailinzeng commented 7 years ago

(env) ➜ zhuaxia git:(master) ✗ python zx http://www.xiami.com/space/lib-song/u/4706713 WARNING: [虾] 不登录虾米进行下载, 虾米资源质量为128kbps. WARNING: [虾]如用户收藏较多,解析歌曲需要较长时间,请耐心等待 Traceback (most recent call last): File "zx", line 122, in commander.shall_I_begin(option) File "/home/hailin/Documents/Dev/zhuaxia/zhuaxia/commander.py", line 68, in shall_I_begin from_url_xm(xiami_obj, option.inUrl) File "/home/hailin/Documents/Dev/zhuaxia/zhuaxia/commander.py", line 194, in from_url_xm fav = xm.Favorite(xm_obj, url, verbose) File "/home/hailin/Documents/Dev/zhuaxia/zhuaxia/xiami.py", line 176, in init self.init_fav() File "/home/hailin/Documents/Dev/zhuaxia/zhuaxia/xiami.py", line 194, in init_fav print u'\u9996' UnicodeEncodeError: 'ascii' codec can't encode character u'\u9996' in position 0: ordinal not in range(128)

hailinzeng commented 7 years ago

是mac ssh登陆linux时locale的问题:http://askubuntu.com/a/778672/426130