我想将python脚本(python 3.7)转换为可执行文件,因此只需安装py2exe并试用。
创建一个hello.py并按照py2exe的说明运行安装程序。
此处的代码:
from distutils.core import setup
import py2exe
setup(console =['hello.py'])
我收到以下错误消息:
An exception has occurred, use %tb to see the full traceback.
SystemExit: usage: ipykernel_launcher.py [global_opts] cmd1 [cmd1_opts]
[cmd2 [cmd2_opts] ...]
or: ipykernel_launcher.py --help [cmd1 cmd2 ...]
or: ipykernel_launcher.py --help-commands
or: ipykernel_launcher.py cmd --help