DS里用计划任务运行python程序出错
DSM6.1.1,python程序在DSM里,直接ssh到DSM里运行这个python程序没问题,然后我到DSM里的计划任务里想每个小时运行一次这个程序,结果出错。脚本如下
/usr/local/bin/python3 /volume1/work/python/aria2ml/aria2ml.py出错信息如下
Traceback (most recent call last):
File "/volume1/work/python/aria2ml/aria2ml.py", line 10, in <module>
confilelist=confile.readlines()
File "/volume1/@appstore/py3k/usr/local/lib/python3.5/encodings/ascii.py", line 26, in decode
return codecs.ascii_decode(input, self.errors)
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe6 in position 0: ordinal not in range(128)
这个我搜索了说是编码的问题,可是我在本机和ssh登录到DSM里运行脚本都没问题呀。
页:
[1]