当我使用PyInstaller创建构建时,我遇到了一个问题。
这是错误的堆栈跟踪:
File "asyncpg/protocol/__init__.py", line 8, in <module>
File "asyncpg/protocol/protocol.pyx", line 1, in init asyncpg.protocol.protocol
File "asyncpg/pgproto/./buffer.pyx", line 12, in init asyncpg.pgproto.pgproto
ImportError: cannot import name exceptions我在编译应用程序时添加了asyncpg.pgproto.pgproto,但错误仍然存在。以下是pyinstaller命令的示例:
pyinstaller --hidden-import=asyncpg.pgproto.pgproto --onefile --distpath folter/example_service example/__main__.py --name example-app谢谢!
发布于 2021-04-07 02:04:37
https://stackoverflow.com/questions/65623306
复制相似问题