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

Replace deprecated pkg_resources check #3096

Open
rozyczko opened this issue Aug 28, 2024 · 1 comment
Open

Replace deprecated pkg_resources check #3096

rozyczko opened this issue Aug 28, 2024 · 1 comment
Assignees
Labels
dependencies Pull requests that update a dependency file Minor Small job

Comments

@rozyczko
Copy link
Member

rozyczko commented Aug 28, 2024

Describe the bug
Class PackageGatherer uses pkg_resources.working_set to poll the installed packages.

This package has been deprecated ( https://setuptools.pypa.io/en/latest/pkg_resources.html ) and we should replace this with

import importlib.metadata
installed_packages = [x.name for x in importlib.metadata.distributions()]

SasView version (please complete the following information):

  • Version: <=6.0

Operating system (please complete the following information):

  • OS: all

Additional context
Errrr where do we actually use this functionality? Nothing in the code seems to call the relevant methods.

@rozyczko rozyczko self-assigned this Aug 28, 2024
@rozyczko rozyczko added Minor Small job dependencies Pull requests that update a dependency file labels Aug 28, 2024
@krzywon
Copy link
Contributor

krzywon commented Sep 17, 2024

This was added for 5.0.5 in #1961 but was removed from the GUI because the release version never worked properly. We might want to revisit this now the cli is working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file Minor Small job
Projects
None yet
Development

No branches or pull requests

2 participants