Skip to content

Remove use of __file__ #257

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

Open
jayvdb opened this issue Oct 30, 2022 · 2 comments · May be fixed by #851
Open

Remove use of __file__ #257

jayvdb opened this issue Oct 30, 2022 · 2 comments · May be fixed by #851

Comments

@jayvdb
Copy link
Contributor

jayvdb commented Oct 30, 2022

__file__ is an optional attribute of packages. c.f. indygreg/PyOxidizer#69 for why and alternatives.

spdx/config.py:_base_dir = os.path.dirname(__file__)
@nicoweidner
Copy link
Collaborator

The link to the promised solution results in a 404, do you have a different one?
https://pyoxidizer.readthedocs.io/en/latest/packaging_pitfalls.html#reliance-on-file

bact added a commit to bact/tools-python that referenced this issue Apr 23, 2025
Potentially fix spdx#257 and allow zip-safe = true in pyproject.toml

Signed-off-by: Arthit Suriyawongkul <arthit@gmail.com>
@bact bact linked a pull request Apr 23, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants