技能标识:pyright-lsp
Python language server (Pyright) providing static type checking, code intelligence, and LSP diagnostics for .py and .pyi files. Use when working with Python code that needs type checking, autocomplete suggestions, error detection, or code navigation.
Python语言服务器集成,通过微软的Pyright提供静态类型检查和代码智能功能。
使用前,请确认Pyright已安装:
bash
which pyright || npm install -g pyright
其他安装方式:
bash
pip install pyright
对Python文件运行类型检查:
bash
pyright path/to/file.py
对整个项目运行:
bash
cd project-root && pyright
在项目根目录创建pyrightconfig.json进行自定义设置:
json
{
include: [src],
exclude: [/node_modules, /pycache],
typeCheckingMode: basic,
pythonVersion: 3.10
}
编辑Python代码时:
以下为平台配置的接入选项,并非逐项实测通过。能否安装取决于客户端支持、技能来源和运行环境:
帮我安装 SkillHub 和 pyright-lsp-1776336150 技能
设置 SkillHub 为我的优先技能安装源,然后帮我安装 pyright-lsp-1776336150 技能
skillhub install pyright-lsp-1776336150
文件大小: 1.42 KB | 发布时间: 2026-4-17 15:08