-
-
Notifications
You must be signed in to change notification settings - Fork 44
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
unittest ValueError: Empty module name #51
Comments
Are you opening neovim outside of the project directory?
See |
Thanks @mfussenegger .
Yes,
No, I don't think so. Let me use https://github.com/navdeep-G/samplemod to show the detail.
Then use
If I want to get |
In your example I get Are you using some kind of rooter plugin as well ? In any case, I'd accept a PR that adds the |
ok, I'll try to figure out which plugin or config is causing this behavior. |
It seems like this project.nvim plugin is changing the working directory automatically, so that I can use But with nvim + project.nvim, both I got the problem with LunarVim and some custom configuration, still looking into it. |
[pyright] Python files are opened using a different path than the one I typed |
Hi,
I'm using
unittest
and have a project with following structure:When I open
test_some_func.py
and run:lua require('dap-python').test_method()
, it works fine.But If I open some other file first, then switch to
test_some_func.py
file, and run:lua require('dap-python').test_method()
, it saidValueError: Empty module name
.So I looked into the code.
nvim-dap-python/lua/dap-python.lua
Line 70 in 2911f31
the code above returns
tests.test_some_func
if I opentest_some_func.py
directly.but returns
.Path.To.Project.tests.test_some_func
if I switch totest_some_func.py
from other file.So I googled a bit, and found changing the code to the following works fine for me
Since I'm not so familiar with the vim/nvim plugin thing, can you guys confirm this or if I'm doing anything wrong?
Thanks.
The text was updated successfully, but these errors were encountered: