This is the JSON schema for "mypy" ([tool.mypy]
) specifically designed for the pyproject.toml
file.
We have configured it to reference the JSON schema for mypy in this repository based on the pyproject.json
in the Schema Store.
mypy-json-schema-demo.mp4
Please install the TOML language server called taplo.
You can also download the binary built from the GitHub Releases page, Please download the file with "full"
in its name, such as taplo-full-darwin-aarch64.gz
.
Please create a configuration for evenBetterToml.schema.associations
and set it to reference the schema for pyproject.toml
from this repository's pyproject.json
.
Here is an example of a configuration for the language client I am using. Please adapt it to your environment.
{
"languageserver": {
"taplo": {
"command": "taplo",
"args": ["lsp", "stdio"],
"filetypes": ["toml"],
"settings": {
"evenBetterToml": {
"schema": {
"associations": {
"^(.*(/|\\\\)\\.?pyproject\\.toml|\\.?pyproject\\.toml)$": "https://raw.githubusercontent.com/yaegassy/mypy-json-schema/master/schemas/pyproject.json"
}
}
}
}
}
}
}
MIT