Code Monkey home page Code Monkey logo

Comments (6)

MatthieuDartiailh avatar MatthieuDartiailh commented on July 4, 2024

I have no personal experience with PyInstaller but is it possible it somehow forgot to package the compiled dll for kiwi ? That's how I read error message.
You should have both a _cext.pyi and a .pyd in your install, PyInstaller may have packaged only the .pyi.

from kiwi.

mapcreatorGuus avatar mapcreatorGuus commented on July 4, 2024

As far as my expertise goes in this regard, it seems to be the other way around: only the pyd (_cext.cp311-win_amd64.pyd) is present.

I'm not entirely sure what to try next and if this is even the problem of kiwisolver or perhaps of PyInstaller instead. This paragraph on the pyinstaller wiki may be related: https://pyinstaller.org/en/v5.13.2/when-things-go-wrong.html#listing-hidden-imports. It seems that, generally, pyinstaller leaves it up to other packages to contribute their own hooks so that packages can be frozen properly, but this could also be an issue on their end.

from kiwi.

MatthieuDartiailh avatar MatthieuDartiailh commented on July 4, 2024

Kiwi has no hidden imports. Could you post the content of the kiwi package in the install created by PyInstaller ?

from kiwi.

mapcreatorGuus avatar mapcreatorGuus commented on July 4, 2024

Just to clarify: I cannot completely view the results of builds as I run PyInstaller with --onefile, which creates a single self-contained exectuable. My findings about the package contents regard those when I use PyInstaller without the --onefile option.

That being said, the installed package contains a kiwisolver folder with inside it only the file "_cext.cp311-win_amd64.pyd".

Another perhaps useful thing me and a colleague discovered in the meantime is the following: when I place msvcp140.dll next to my executable, it does run fine. This suggests that that dll is not properly included when freezing my project with PyInstaller.

from kiwi.

MatthieuDartiailh avatar MatthieuDartiailh commented on July 4, 2024

This is weird on several level:

  • to run you need the exceptions.py file from which some things are imported by _cext
  • you also need __init__.py since typically users are not expected to use functionalities beyond this
  • when building the installer you can set the env var KIWI_DISABLE_FH4 to avoid linking against VCRUNTIME140_1.dll (I mention it since you have a windows dll issue even though it does not seem related to this exact dll).

from kiwi.

mapcreatorGuus avatar mapcreatorGuus commented on July 4, 2024

I'm not really sure how to proceed with this. My personal runtime problem is solved by manually including the msvcp140.dll in the PyInstaller build, but I do not think that is a satisfying solution for this situation.

The way I see it now the desired solution would be either of the following:

But maybe I'm overlooking something, let me know what you think.
Anyway, I really appreciate your help so far :)

from kiwi.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.