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

TST: DeprecationWarning: SelectableGroups dict interface is deprecated. Use select. #11524

Closed
pllim opened this issue Apr 12, 2021 · 2 comments · Fixed by #11534
Closed

TST: DeprecationWarning: SelectableGroups dict interface is deprecated. Use select. #11524

pllim opened this issue Apr 12, 2021 · 2 comments · Fixed by #11534

Comments

@pllim
Copy link
Member

pllim commented Apr 12, 2021

Example log: https://github.com/astropy/astropy/runs/2321021984?check_suite_focus=true

Snippet (one of many):

___________ ERROR collecting astropy/modeling/tests/data/__init__.py ___________
tests/lib/python3.7/site-packages/pytest_doctestplus/plugin.py:206: in collect
    module = self.fspath.pyimport()
tests/lib/python3.7/site-packages/py/_path/local.py:704: in pyimport
    __import__(modname)
astropy/modeling/__init__.py:10: in <module>
    from . import fitting
astropy/modeling/fitting.py:1764: in <module>
    populate_entry_points(entry_points().get('astropy.modeling', []))
tests/lib/python3.7/site-packages/importlib_metadata/__init__.py:312: in get
    flake8_bypass(self._warn)()
E   DeprecationWarning: SelectableGroups dict interface is deprecated. Use select.
@saimn
Copy link
Contributor

saimn commented Apr 12, 2021

Hmm, so Python 3.10's entry_points() will return an EntryPoints object and emit the same warning (https://docs.python.org/3.10/library/importlib.metadata.html#entry-points), and importlib_metadata is doing things in advance so their last release is already emitting the warning (python/importlib_metadata#298).
I think we can ignore the warning for now, but when Python 3.10 is out we will need to find a way to adapt the code.

@pllim
Copy link
Member Author

pllim commented Apr 12, 2021

According to PEP 619, 3.10.0 final is expected on Monday, 2021-10-04. It is not that far off. Should we address this properly sooner than later?

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

Successfully merging a pull request may close this issue.

2 participants