-
Notifications
You must be signed in to change notification settings - Fork 261
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
Elpy fails with Python 3.12, distutils has been removed #2051
Comments
I too have this problem, which causes spurious syntax error highlighting with new syntax. From a quick look, it appears that
with
or similarly with the |
An update: Making this change solved the problem for me. I made this adjustment to the variable |
P.S. elpy/blackutil.py and elpy/jedybackend.py use pkg_resources which is also deprecated and removed in Python 3.12. This raises a messsage from the elpy backend but is not fatal. All that is used is I'll experiment with changing this when I have a moment, but I thought I'd mention in as a follow up to the earlier comments. P.P.S. The new version is recognized and seems to function, but there do appear to still be some issues using the new version. I haven't tracked down the problem, so it's not as cleancut as I had hoped. |
I've seemingly solved the problem with three changes.
The I've been using this for a bit without difficulty and can finally upgrade to the newer versions for the RPC venv. |
Summary
Python 3.12 has removed distutils Therefore the rpc initialization script fails.
Steps to reproduce
My configuration
OS
Mac OS Sonoma 14.6.1
homebrew install pipx python@3.12 virtualenv
Result of
(elpy-config)
The text was updated successfully, but these errors were encountered: