dap-mode
dap-mode copied to clipboard
Update dap-python for running in pipenv
We have many options for executing the python program. At first, I want to add "pipenv" into the option.
@mpanarin, willing to take a look?
It is the same as https://github.com/emacs-lsp/dap-mode/issues/202
To be honest, I am against explicit support of the virtualenv in lsp-mode
or dap-mode
.
This should be handled by emacs and its executable-find
. There are a bunch of packages and minor-modes that will make executable-find
find a proper python in virtualenv. I mentioned a few in the issue above.
The problem with supporting virtualenvs is that everyone uses them differently. You can use them through pipenv
, 'virtualenv', 'virtualenvwrapper', 'poetry' to name a few. And I don't think we should write support for all of them.
pyenv
is a bit different as it is not really a virtualenv, so we have a direct support for it.
But I am definitely open for a discussion @ericdallo @seagle0128 @yyoncho
I agree with @mpanarin, IMO we should make dap-mode extensible and easy to setup with different templates, support all possible virtualenvs seems to be too much.
But now you are supported pyenv. If you want to do so, you should remove pyenv option, shouldn't you?
In my opinion, we can give the execute-python-path into a template. Can you fix it?
@MokkeMeguru pyenv is a version manager, not a virtualenv manager. As I said, it is a different story, so we support it explicitly
If so, then we must consider conda, and Pyflow... It will be too complex problem...
So how to run dap on python with pipenv? No way?
@MokkeMeguru @mpanarin Since this pull-request is not accepted and #294 is an alternative: can this one be closed?
hi @htgoebel IMO, this pr can be closed. thanks for your review