Skip to content

lsp-pyright#

Build Status MELPA License Join the chat at https://gitter.im/emacs-lsp/lsp-mode

lsp-mode client leveraging Pyright language server

Quickstart#

(use-package lsp-pyright
  :ensure t
  :hook (python-mode . (lambda ()
                          (require 'lsp-pyright)
                          (lsp))))  ; or lsp-deferred

Configuration#

lsp-pyright supports the following configuration. Each configuration is described in detail in Pyright Settings.

  • pyright.disableLanguageServices via lsp-pyright-disable-language-services
  • pyright.disableOrganizeImports via lsp-pyright-disable-organize-imports
  • python.analysis.autoImportCompletions via lsp-pyright-auto-import-completions
  • python.analysis.useLibraryCodeForTypes via lsp-pyright-use-library-code-for-types
  • python.analysis.typeshedPaths via lsp-pyright-typeshed-paths
  • python.analysis.diagnosticMode via lsp-pyright-diagnostic-mode
  • python.analysis.typeCheckingMode via lsp-pyright-typechecking-mode
  • python.analysis.logLevel via lsp-pyright-log-level
  • python.analysis.autoSearchPaths via lsp-pyright-auto-search-paths
  • python.analysis.extraPaths via lsp-pyright-extra-paths
  • python.venvPath via lsp-pyright-venv-path

Projects can be further configured using pyrightconfig.json file. For further details please see Pyright Configuration.


Last update: April 12, 2021