Python 3.12 Removed the imp package which __init__.py includes
TheMineTrooperYT opened this issue · comments
TheMineTrooperYT commented
As described here the imp
module was removed in Python version 3.12, and i3pystatus __init__.py
file includes the module on line 9:
...
5. from i3pystatus.core.settings import SettingsBase
6. from i3pystatus.core.util import formatp, get_module
7.
8. import argparse
9. import imp # <----
10. import logging
...
A very simple solution as proposed in the aforementioned link is to replace it with importlib
:
...
5. from i3pystatus.core.settings import SettingsBase
6. from i3pystatus.core.util import formatp, get_module
7.
8. import argparse
9. import importlib # <-----
10. import logging
...
Done this on my system, rebuilt the package and it all seems to work.
P.s. this is my first time posting an issue on a public github page, so if I missed some guidelines or smth I apologize.
Giancarlo Razzolini commented
This is fixed by #865
Erik Johnson commented
Closing as the referenced PR has been merged.