ValueError:character U + 6573552f ... Py2aap
问题描述:
我做了一个非常简单的程序,我试图将其导出到应用程序文件。我目前使用Python 3.6和py2app将py文件转换为app。 所以我创建的安装文件:ValueError:character U + 6573552f ... Py2aap
from setuptools import setup
OPTIONS = {'iconfile':'sc.icns',}
setup(
app = ['hello.py'],
options = {
'py2app': OPTIONS},
setup_requires = ['py2app']
)
,然后在终端我输入:
python3 hello_setup.py py2app
几秒钟后,它会创建dist文件夹,并在其中存在hello.app,问题当我运行它,它看来,说“你好错误”然后我打开.exec文件的应用程序里面看到的终端窗口,它显示了这个错误:
ValueError: character U+6573552f is not in range [U+0000; U+10ffff]
它为什么会出现?我如何解决它?非常感谢你。
在它需要的情况下,这里是“hello.py”
from tkinter import *
from tkinter import messagebox
root = Tk()
def printworld():
messagebox.showinfo('Hello', 'Hello World')
button1 = Button(root, text='Press me!', command=printworld)
button1.pack()
root.mainloop()