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

importlib.abc.Finder has been removed from Python 3.12 #851

Closed
alcir opened this issue Jul 19, 2023 · 2 comments
Closed

importlib.abc.Finder has been removed from Python 3.12 #851

alcir opened this issue Jul 19, 2023 · 2 comments

Comments

@alcir
Copy link
Contributor

alcir commented Jul 19, 2023

_ModuleHiderBase = getattr(importlib.abc, "MetaPathFinder", importlib.abc.Finder)

Running tests with Python 3.12 this is the result

_____________________________________________________________________________________________ ERROR collecting pynetdicom/tests/test_assoc.py _______________________________________________________________________________________________
pynetdicom/tests/test_assoc.py:69: in <module>
    from .hide_modules import hide_modules
pynetdicom/tests/hide_modules.py:33: in <module>
    _ModuleHiderBase = getattr(importlib.abc, "MetaPathFinder", importlib.abc.Finder)
/usr/lib64/python3.12/importlib/abc.py:38: in __getattr__
    raise AttributeError(f'module {__name__!r} has no attribute {name!r}')
E   AttributeError: module 'importlib.abc' has no attribute 'Finder'

I think that it is related to this change python/cpython/issues/98040

@mrbean-bremen
Copy link
Member

Thanks - yes, I think this had been deprecated before. Python 3.12 is not yet supported in pydicom/pynetdicom, but this is certainly something that can already be adapted. Are you going to make a PR for this yourself?

@mrbean-bremen
Copy link
Member

Closing as fixed.

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

2 participants