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

Support meta-modules in auto python env #1139

Merged
merged 3 commits into from
Oct 13, 2023

Conversation

vhaldemar
Copy link
Contributor

No description provided.

pylzy/lzy/env/explorer/classify.py Outdated Show resolved Hide resolved
pylzy/lzy/env/explorer/classify.py Outdated Show resolved Hide resolved
pylzy/lzy/env/explorer/utils.py Outdated Show resolved Hide resolved
pylzy/lzy/env/explorer/utils.py Outdated Show resolved Hide resolved
new_meta_packages = self.requirements_to_meta_packages.get(name, ())
for meta_package in new_meta_packages:
if meta_package.name not in seen_meta_packages:
meta_packages.add(meta_package)
Copy link
Collaborator

Choose a reason for hiding this comment

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

since meta_packages is a set, why we need to support seen_meta_packages instead of just add()?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because we could get an early popped meta package later on, it will lead to an infinite loop.


# it is non-meta package, so classify it as usual
package = self._classify_distribution(distribution, binary_distributions)
result.add(package)
Copy link
Collaborator

Choose a reason for hiding this comment

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

so method _classify_meta_package_distributions() returns not only meta packages, but also usual packages which cannot be explored since they are meta packages dependency?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yep
probably I should rename _classify_meta_package_distributions -> _process_meta_packages

@vhaldemar vhaldemar merged commit 1fbc204 into lambdazy:master Oct 13, 2023
6 checks passed
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.

None yet

3 participants