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

Do not rewrite imports if namespace is empty #11

Merged
merged 1 commit into from
May 14, 2020

Conversation

abn
Copy link
Contributor

@abn abn commented Apr 16, 2020

This is usefuly when the vendor directory is expected to be added to sys.path.

@pradyunsg
Copy link
Owner

@abn Thanks for the PR!

I'm not sure I understand the use case here - how is putting a directory on sys.path directly be relevant to putting the packages in the source tree, to avoid bootstrapping issues like the ones pip and setuptools have?

Or is this for a completely separate use case, that you'd like this tool to support?

@abn
Copy link
Contributor Author

abn commented Apr 17, 2020

This would be a slightly different use case.

python-poetry/poetry-core#25

I was looking at maintaining the use of the tool, do everything it currently does, but not rewrite the imports explicitly. The idea, discussed in the issue related to the above PR, was to make debundling easier for distribution maintainers by adding the vendor directory into sys.path and maintaining the original import statements. So, in theory, one could drop the vendor directory and poetry would pick up the system packages.

@pradyunsg
Copy link
Owner

Sounds fair!

@pradyunsg pradyunsg merged commit 7d304aa into pradyunsg:master May 14, 2020
@abn abn deleted the poetry branch July 10, 2020 15:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants