fkxxyz / ssfconv

Sogou input method skin file (.ssf file) converter, supports conversion to fcitx or fcitx5 format.
GNU General Public License v3.0
190 stars 24 forks source link

合成提示TypeError #6

Closed yixun666 closed 3 years ago

yixun666 commented 3 years ago

报错,代码如下: File "./ssfconv", line 1211, in exit(main(args)) File "./ssfconv", line 1181, in main result = ssf2fcitx(skin_dir) File "./ssfconv", line 708, in ssf2fcitx skin.write(open(skin_dir + os.sep + 'fcitx_skin.conf', 'w', encoding="utf-8"), False) TypeError: 'encoding' is an invalid keyword argument for this function

fkxxyz commented 3 years ago

大概是python2没有python3的一些函数参数。换成python3试试

有些发行版比如 centos ,默认用的是 python2

不过这倒提醒我了我应该在代码第一行显式指明 python3,感谢

#!/bin/python3