Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Description of datas and binaries needs to be clarified #2733

Open
htgoebel opened this issue Aug 9, 2017 · 7 comments
Open

Description of datas and binaries needs to be clarified #2733

htgoebel opened this issue Aug 9, 2017 · 7 comments
Labels
area:documentation Related to documentation pull-request wanted Please submit a pull-request for this, maintainers will not actively work on this.

Comments

@htgoebel
Copy link
Member

htgoebel commented Aug 9, 2017

From the mailinglist:

It turns out that I was using binaries to include binary programs that I call using subprocess.call() rather than datas. I did this because the "Using Spec Files" section of the docs says, "datas: non-binary files included in the app."

So we need to clarify in the manual what are binaries and what is data.

@htgoebel htgoebel added area:documentation Related to documentation good first issue This is a good issue if you want to start working on PyInstaller pull-request wanted Please submit a pull-request for this, maintainers will not actively work on this. labels Aug 9, 2017
@thekswenson
Copy link

The current version of the documentation is:
"""
binaries: non-python modules needed by the scripts, including names given by the --add-binary option;
datas: non-binary files included in the app, including names given by the --add-data option.
"""

I was thinking of modifying the datas line to be:
"datas: files used by the app but not included with binaries, including names given by the --add-data option."

It's hard to do better since I'm not sure what binaries is exactly.

@tallforasmurf
Copy link
Contributor

The difference was not clear to me when I wrote the current doc, either! Somebody needs to dive into the code and find out what the real, functional difference is between the two categories. Presumably "binary" files are handled differently than "data" files? Stored elsewhere? Unpacked differently?

@thekswenson
Copy link

I know that I've used the "datas" list to include binary files compiled with Cython, and for binaries called using subprocess.call(). Is binaries even necessary?

@springermac
Copy link
Contributor

binaries are analyzed for binary dependencies, i.e., dlls, so, etc., before being bundled. datas are only bundled.

@thekswenson
Copy link

Would this be a better entry?

"""
binaries: binary dependencies (e.g. dll, so, etc.) to be analyzed, including names given by the --add-binary option;
datas: non-binary files included in the app, including names given by the --add-data option.
"""

@springermac
Copy link
Contributor

I would replace non-binary with static since in especially one file mode any modifications to included files will not persist.

@htgoebel
Copy link
Member Author

htgoebel commented Aug 11, 2017

First of all, I would switch the order, so datas is the more standard type. Something like this:

  • datas: static files to be included with the app, including names given by the --add-data option
  • binaries: binary dependencies (e.g. dll, so, etc.) including names given by the --add-binary option. Files listed here will be analyzed to find recursive dependencies, stripped (in case strip==True) and cached.

We should also update the usage (in building/makespec.py::__add_options()) accordingly.

@bwoodsend bwoodsend removed the good first issue This is a good issue if you want to start working on PyInstaller label Nov 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:documentation Related to documentation pull-request wanted Please submit a pull-request for this, maintainers will not actively work on this.
Projects
None yet
Development

No branches or pull requests

5 participants