shiv icon indicating copy to clipboard operation
shiv copied to clipboard

asyngpg doesn't work due to c-bindings

Open arunhallan opened this issue 4 years ago • 0 comments

Hi,

I am currently compiling using the following command:

shiv --site-packages .env\Lib\site-packages -c runx -o runx.pyz

"runx" is a custom console app I have packaged.

asyncpg is one of the dependencies.

However when I run C:\python310\python.exe runx.pyz, I get the following error:

  File "\site-packages\psccommon\db\db.py", line 4, in <module>
    import asyncpg
  File "\site-packages\asyncpg\__init__.py", line 8, in <module>
    from .connection import connect, Connection  # NOQA
  File "\site-packages\asyncpg\connection.py", line 19, in <module>
    from . import connect_utils
  File "\site-packages\asyncpg\connect_utils.py", line 27, in <module>
    from . import protocol
  File "\site-packages\asyncpg\protocol\__init__.py", line 8, in <module>
    from .protocol import Protocol, Record, NO_TIMEOUT  # NOQA
ModuleNotFoundError: No module named 'asyncpg.protocol.protocol'

Note that this is on a different machine to the build machine, however they are both Windows 10 builds.

What can I do to mitigate this?

Thanks

arunhallan avatar Dec 24 '21 15:12 arunhallan