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

Misc. smaller changes #8279

Merged
merged 3 commits into from Feb 3, 2024
Merged

Misc. smaller changes #8279

merged 3 commits into from Feb 3, 2024

Conversation

rokm
Copy link
Member

@rokm rokm commented Feb 3, 2024

Miscellaneous smaller changes based on this week's issue tracker activity:

  • display version of pyinstaller-hooks-contrib next to PyInstaller version at program start, to make it easier to determine the user's actual setup

  • when trying to run pyinstaller (or equivalent python -m PyInstaller) against non-existing script file(s), exit immediately - without trying to write the .spec file and building it. Mainly to avoid scenario with overwriting a customized .spec file due to typo in command's arguments (PyInstaller poiting to wrong spec file #8276), but also because I sometimes fail to change the directory prior to trying to build a test program, and then have to deal with stay .spec files.

  • fix deprecation warnings emitted by ruff 0.2.0

  • bump the required pyinstaller-hooks-contrib version to the latest release, in attempt to minimize amount of issues reported due to old hooks.

Augment displayed the PyInstaller version with version of the
`pyinstaller-hooks-contrib` package.
Update ruff settings in `pyproject.toml` to fix deprecation warnings
with `ruff` 0.2.0.
When trying to run PyInstaller against non-existent script file(s),
exit with error message immediately, before writing the spec file
and trying to build it.

This prevents us from overwriting an existing (and customized) .spec
file if user makes a typo in the .spec file's suffix when trying to
build it, for example, `pyinstaller program.cpes`. It also prevents
creation of a .spec file when `pyinstaller program.py` is accidentally
ran from a directory that does not contain the script (for example,
due to failing to change the directory prior to running the command).

This applies only to the `pyinstaller` command (and the equivalent
`python -m PyInstaller` invocation); the `pyi-makespec` command is
still allowed to be called with non-existent script file(s) that
might be added later, before the actual build attempt with the
generated .spec file.
@bwoodsend
Copy link
Member

bump the required pyinstaller-hooks-contrib version to the latest release, in attempt to minimize amount of issues reported due to old hooks.

I could start doing this as part of the release process?

@rokm
Copy link
Member Author

rokm commented Feb 3, 2024

bump the required pyinstaller-hooks-contrib version to the latest release, in attempt to minimize amount of issues reported due to old hooks.

I could start doing this as part of the release process?

Good idea. I'll drop the corresponding commit here, then, and you can bump the version prior to next release.

@rokm rokm merged commit 40119f9 into pyinstaller:develop Feb 3, 2024
3 of 18 checks passed
@rokm rokm deleted the weekly-mop-up branch February 3, 2024 21:46
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 4, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants