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

Record files don't always include directories so find eggdir by looking ... #2076

Merged
merged 2 commits into from Oct 6, 2014

Conversation

Projects
None yet
2 participants
@abadger
Contributor

abadger commented Sep 29, 2014

...for a file within it.

Fixes #2075

@dstufft

This comment has been minimized.

Show comment
Hide comment
@dstufft

dstufft Oct 4, 2014

Member

Here's a question, this is probably me being overly paranoid but do we need to look for a filename inside it instead of just any file inside it?

Something like:

if os.path.basename(os.path.dirname(line)).endswith(".egg-info"):
    egg_info_dir = prepend_root(os.path.dirname(line))

I think this would work similarly to what you have, but it only relies on there being any file inside of the egg-info directory, not a particularly named file.

Member

dstufft commented Oct 4, 2014

Here's a question, this is probably me being overly paranoid but do we need to look for a filename inside it instead of just any file inside it?

Something like:

if os.path.basename(os.path.dirname(line)).endswith(".egg-info"):
    egg_info_dir = prepend_root(os.path.dirname(line))

I think this would work similarly to what you have, but it only relies on there being any file inside of the egg-info directory, not a particularly named file.

@abadger

This comment has been minimized.

Show comment
Hide comment
@abadger

abadger Oct 6, 2014

Contributor

Yep, that's probably a better strategy.

Contributor

abadger commented Oct 6, 2014

Yep, that's probably a better strategy.

@dstufft

This comment has been minimized.

Show comment
Hide comment
@dstufft

dstufft Oct 6, 2014

Member

Awesome, thanks!

Member

dstufft commented Oct 6, 2014

Awesome, thanks!

dstufft added a commit that referenced this pull request Oct 6, 2014

Merge pull request #2076 from abadger/feature/no-egg-info-dir-in-record
Record files don't always include directories so find eggdir by looking ...

@dstufft dstufft merged commit 7e0e302 into pypa:develop Oct 6, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details

dstufft added a commit that referenced this pull request Oct 6, 2014

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