8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I use emacs`s lsp-pylsp. When i want to use autoimport function, it suggests path with src.How can i right configurate.
. ├── requirements.txt ├── src │ ├── pycache │ ├── app.py │ ├── config │ ├── data │ ├── func │ │ ├── init.py │ │ ├── pycache │ │ └── rule.py │ ├── image2config │ │ ├── init.py │ │ └── page.py │ ├── model │ │ ├── pycache │ │ ├── database.py │ │ ├── device.py │ │ ├── pagetree.py │ │ └── project.py │ ├── other │ ├── resource │ │ ├── copyposition.ui │ │ ├── copypositiondialog.ui │ │ ├── devicemanage.ui │ │ ├── imagedisplay.ui │ │ ├── imageedit.ui │ │ ├── mainpage.ui │ │ ├── pagedisplay.ui │ │ ├── pageedit.ui │ │ ├── positioncompare.ui │ │ ├── positiondialog.ui │ │ ├── projectdialog.ui │ │ └── projectlist.ui │ ├── ui │ │ ├── init.py │ │ ├── pycache │ │ ├── devicemanageproxy.py │ │ ├── imagedisplayproxy.py │ │ ├── imageeditproxy.py │ │ ├── mainpageproxy.py │ │ ├── pagedisplayproxy.py │ │ ├── pageeditproxy.py │ │ ├── positiondialogproxy.py │ │ ├── projectdialogproxy.py │ │ └── projectlistproxy.py │ └── util │ ├── pycache │ ├── func.py │ └── imageutil.py └── tests └── util ├── pycache ├── func_test.py └── imageutil_test.py
((python-mode . ((lsp-pylsp-configuration . (:python (:analysis (:extraPaths ["src"])))) (lsp-pylsp-plugins-flake8-ignore . ["E111" "E121" "E114" "E501"]) (lsp-pylsp-plugins-jedi-environment . "/Users/tong/program/project/xianyu/venv") (lsp-pylsp-plugins-jedi-completion-extra-paths . ["src"]) (lsp-pylsp-plugins-mypy-overrides . ["--python-executable" "/Users/tong/program/project/xianyu/venv/bin/python" t]) (lsp-disabled-clients . (pyright)) )))
[tool.pylsp] plugins.jedi_completion = { enabled = true, extra_paths = ["src"] } plugins.pylint = { enabled = true, args = ["--max-line-length=100"] } plugins.autopep8 = { enabled = true } plugins.black = { enabled = true } plugins.rope = { enabled = true }
[tool.rope] enabled = true python_path = ["/Users/tong/program/project/xianyu/venv/bin/python"] save_objectdb = true split_imports = true source_folders = ["src"] # 源码目录 ignored_paths = ["tests"] # 排除目录
[tool.jedi_completion] cache_for = ['PySide6', 'PySide6.QtWidgets'] extra_paths = ["src"]
[tool.flake8] enable-extensions = "D" # 启用 docstring 规则(flake8-docstrings) exclude = ".git,pycache,venv,test" # 排除这些目录
[tool.pytest.ini_options] addopts = "-s" testpaths = ["tests"] pythonpath = ["src"]
[tool.ruff] src = ["src"]
[tool.mypy] mypy_path = "src" files = ["src", "tests"]
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I use emacs`s lsp-pylsp. When i want to use autoimport function, it suggests path with src.How can i right configurate.
path tree
.
├── requirements.txt
├── src
│ ├── pycache
│ ├── app.py
│ ├── config
│ ├── data
│ ├── func
│ │ ├── init.py
│ │ ├── pycache
│ │ └── rule.py
│ ├── image2config
│ │ ├── init.py
│ │ └── page.py
│ ├── model
│ │ ├── pycache
│ │ ├── database.py
│ │ ├── device.py
│ │ ├── pagetree.py
│ │ └── project.py
│ ├── other
│ ├── resource
│ │ ├── copyposition.ui
│ │ ├── copypositiondialog.ui
│ │ ├── devicemanage.ui
│ │ ├── imagedisplay.ui
│ │ ├── imageedit.ui
│ │ ├── mainpage.ui
│ │ ├── pagedisplay.ui
│ │ ├── pageedit.ui
│ │ ├── positioncompare.ui
│ │ ├── positiondialog.ui
│ │ ├── projectdialog.ui
│ │ └── projectlist.ui
│ ├── ui
│ │ ├── init.py
│ │ ├── pycache
│ │ ├── devicemanageproxy.py
│ │ ├── imagedisplayproxy.py
│ │ ├── imageeditproxy.py
│ │ ├── mainpageproxy.py
│ │ ├── pagedisplayproxy.py
│ │ ├── pageeditproxy.py
│ │ ├── positiondialogproxy.py
│ │ ├── projectdialogproxy.py
│ │ └── projectlistproxy.py
│ └── util
│ ├── pycache
│ ├── func.py
│ └── imageutil.py
└── tests
└── util
├── pycache
├── func_test.py
└── imageutil_test.py
.dir-locals.el
((python-mode .
((lsp-pylsp-configuration
. (:python (:analysis (:extraPaths ["src"]))))
(lsp-pylsp-plugins-flake8-ignore . ["E111" "E121" "E114" "E501"])
(lsp-pylsp-plugins-jedi-environment . "/Users/tong/program/project/xianyu/venv")
(lsp-pylsp-plugins-jedi-completion-extra-paths . ["src"])
(lsp-pylsp-plugins-mypy-overrides . ["--python-executable" "/Users/tong/program/project/xianyu/venv/bin/python" t])
(lsp-disabled-clients . (pyright))
)))
pyproject.toml
[tool.pylsp]
plugins.jedi_completion = { enabled = true, extra_paths = ["src"] }
plugins.pylint = { enabled = true, args = ["--max-line-length=100"] }
plugins.autopep8 = { enabled = true }
plugins.black = { enabled = true }
plugins.rope = { enabled = true }
[tool.rope]
enabled = true
python_path = ["/Users/tong/program/project/xianyu/venv/bin/python"]
save_objectdb = true
split_imports = true
source_folders = ["src"] # 源码目录
ignored_paths = ["tests"] # 排除目录
[tool.jedi_completion]
cache_for = ['PySide6', 'PySide6.QtWidgets']
extra_paths = ["src"]
[tool.flake8]
enable-extensions = "D" # 启用 docstring 规则(flake8-docstrings)
exclude = ".git,pycache,venv,test" # 排除这些目录
[tool.pytest.ini_options]
addopts = "-s"
testpaths = ["tests"]
pythonpath = ["src"]
[tool.ruff]
src = ["src"]
[tool.mypy]
mypy_path = "src"
files = ["src", "tests"]
The text was updated successfully, but these errors were encountered: