Hello, I’ve been lately seeing a strange issue with python imports that was not present before and can not find a solution to it.
Before, when importing the pandas library or any other library it works fine and the lsp-mode work fine and can get some functionality when coding.
But now I find the message [Missingimports] as the picture
I still can run the python script as normally do but the lsp functionality is missing
What did you expect to happen?
This was not present before.
I tried to use the M-x lsp-restart-workspace enter
but it did not work
Steps to reproduce
I’m using python 3.10 and it is happening in all python scripts inside emacs
Loading data dump...
Do you still have this issue? From my experience with Doom, LSP, and Python, this happens a lot when the “missing dependencies” are installed into a virtual environment that’s not active. I see that you use
direnv in your Doom configuration, do you also use it for Python projects? If so, what do you have in your
What I did was uninstall doom and emacs altogether (backup .doom folder for sure) and do a fresh install and it worked again as normal.
direnv is something I do not use and I added it to the system when I was tinkering with emacs at the beginning many months ago and did not want to touch it again so it is there by mistake .