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

GH-128469: warn when libpython was loaded from outside the build directory #128645

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

FFY00
Copy link
Member

@FFY00 FFY00 commented Jan 8, 2025

…d directory

Signed-off-by: Filipe Laíns <lains@riseup.net

# When running Python from the build directory, if libpython is dynamically
# linked, the wrong library might be loaded.
if build_prefix and not build_prefix.startswith(dirname(abspath(library))):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

library can be None, which is causing the failing CI:

Suggested change
if build_prefix and not build_prefix.startswith(dirname(abspath(library))):
if build_prefix and library and not build_prefix.startswith(dirname(abspath(library))):

It's probably worth stretching this case across multiple lines, though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants