Coder Social home page Coder Social logo

Comments (6)

mdomke avatar mdomke commented on September 28, 2024 1

@cedricscheepers could you verify that something similar to

$ pyinstaller schwifty-test.py --name schwifty-test --onefile --console --add-data=C:\Users\christi\AppData\Local\Programs\Python\Python312\Lib\site-packages\schwifty:. --copy-metadata schwifty

helps?

from schwifty.

mdomke avatar mdomke commented on September 28, 2024

Maybe this #187 (comment) helps in your case as well?

from schwifty.

rokm avatar rokm commented on September 28, 2024

The canonical solution would be --collect-data schwifty --copy-metadata schwifty and to revert #92, because the bank_registry data directory is/should be collected as sys._MEIPASS/schwifty/bank_registry and not sys._MEIPASS/bank_registry. Plus, PyInstaller supports importlib.resources.files() since v4.6 (which predates #92), so no special handling is needed. (Alternatively, the package_path for frozen codepath should be fixed into package_path = Path(__file__).parent).

from schwifty.

mdomke avatar mdomke commented on September 28, 2024

@rokm Thank you very much for the clarification. I'm not a pyinstaller user myself and should have paid more attention when integrating the changes in #92. The aforementioned pull-request has been reverted in release 2024.05.1. As I understand from pyinstaller/pyinstaller#8458 you would be willing to add a hook that simplifies the integration of schwifty to pystinaller? Otherwise, I could also add some instructions to schwifty's documentation.

from schwifty.

mdomke avatar mdomke commented on September 28, 2024

@cedricscheepers with schwifty release 2024.05.2 you should be able to do

$ pyinstaller schwifty-test.py --copy-metadata schwifty --collect-data schwifty

Possibly, a custom pyinstaller-hook will make it even easier in the future. Can you confirm that this works for you?

from schwifty.

rokm avatar rokm commented on September 28, 2024

@rokm Thank you very much for the clarification. I'm not a pyinstaller user myself and should have paid more attention when integrating the changes in #92. The aforementioned pull-request has been reverted in release 2024.05.1. As I understand from pyinstaller/pyinstaller#8458 you would be willing to add a hook that simplifies the integration of schwifty to pystinaller? Otherwise, I could also add some instructions to schwifty's documentation.

Thanks for promptly taking care of the problem!

We will indeed add a hook for schwifty that will automatically perform the equivalent of --copy-metadata schwifty --collect-data schwifty - see pyinstaller/pyinstaller-hooks-contrib#742. After installing the release of pyinstaller-hooks-contrib that will include the linked PR, schwifty will work out-of-the-box with PyInstaller.

from schwifty.

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.