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

Dropping pkg_resources #460

Open
jakirkham opened this issue Dec 6, 2022 · 0 comments
Open

Dropping pkg_resources #460

jakirkham opened this issue Dec 6, 2022 · 0 comments

Comments

@jakirkham
Copy link

Currently this uses pkg_resources, which is planned to go away:

import pkg_resources

The code using it mainly uses the iter_entry_points function:

for entry_point in pkg_resources.iter_entry_points("streamz.sources"):
try_register(cls, entry_point, staticmethod)
for entry_point in pkg_resources.iter_entry_points("streamz.nodes"):
try_register(cls, entry_point)
for entry_point in pkg_resources.iter_entry_points("streamz.sinks"):
try_register(cls, entry_point)

This could be replaced by importlib.metadata.entry_points, which has been around since Python 3.8.

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

No branches or pull requests

1 participant