-
Notifications
You must be signed in to change notification settings - Fork 52
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_star_imports broken in latest version (PyInf#11805) #281
Comments
I cannot reproduce, did you by any chance update something else, or use it in different environment where some things might have been cached ? I added a test in #282, let see if it fails only on some platforms. I also dug into CPython history, the really strange things is that Has not been touched in quite a while: pyflyby/lib/python/pyflyby/_modules.py Line 253 in c7aa87d
And when stepping through the code, seem to access |
I don't understand why the bug is happening, and why this get a FrozenImporter as it was never getting one before, but this should fix the bug.
I'm guessing #283 will prevent the crash, but I'd still like to understand the cause to have a proper fix. |
I don't understand why the bug is happening, and why this get a FrozenImporter as it was never getting one before, but this should fix the bug.
Right. Missed to mention that the issue happens in py3.11. Probably #280 could have helped us |
Also, I tried quickly verifying the commit. |
It seem that in 3.11 there is now another FrozenImporter from _frozen_importlib, I did not manage to get isinstance to work with it so we need to check with hasattr.
Ok, yes, I can reproduce on 3.11. 5ec2d56 seem to be the first failing commit. I'll do a different fix. |
It seem that in 3.11 there is now another FrozenImporter from _frozen_importlib, I did not manage to get isinstance to work with it so we need to check with hasattr.
@Carreau The issue still persists in the latest version as well
Can you please check ? Its in python 3.11 |
replace_star_imports is broken in latest version 1.8.8
Can this be fixed on priority ? (cc: @quarl )
The text was updated successfully, but these errors were encountered: