[英]PyInstaller + Asyncpg: Cannot import name exceptions
使用 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
謝謝!
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.