Skip to content

Commit 5fc83da

Browse files
authored
Update suggested VSCode extensions and project settings (#130)
* Add tool configuration for mypy Signed-off-by: Mattt Zmuda <[email protected]> * Add suggested VSCode extensions and update project settings Signed-off-by: Mattt Zmuda <[email protected]> --------- Signed-off-by: Mattt Zmuda <[email protected]>
1 parent 07abc4c commit 5fc83da

File tree

3 files changed

+23
-13
lines changed

3 files changed

+23
-13
lines changed

.vscode/extensions.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"recommendations": [
3+
"charliermarsh.ruff",
4+
"ms-python.black-formatter",
5+
"ms-python.python",
6+
"ms-python.vscode-pylance"
7+
]
8+
}

.vscode/settings.json

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,25 @@
11
{
2-
"python.formatting.provider": "black",
3-
"python.languageServer": "Pylance",
42
"editor.formatOnSave": true,
5-
"python.testing.unittestEnabled": false,
6-
"python.testing.pytestEnabled": true,
73
"editor.formatOnType": true,
84
"editor.formatOnPaste": true,
95
"editor.renderControlCharacters": true,
106
"editor.suggest.localityBonus": true,
117
"files.insertFinalNewline": true,
128
"files.trimFinalNewlines": true,
13-
"[json]": {
14-
"editor.defaultFormatter": "esbenp.prettier-vscode"
15-
},
16-
"[jsonc]": {
17-
"editor.defaultFormatter": "esbenp.prettier-vscode"
18-
},
199
"[python]": {
20-
"editor.defaultFormatter": "ms-python.python",
10+
"editor.formatOnSave": true,
2111
"editor.codeActionsOnSave": {
12+
"source.fixAll": true,
2213
"source.organizeImports": true
23-
}
14+
},
15+
"editor.defaultFormatter": null
2416
},
17+
"python.languageServer": "Pylance",
18+
"python.testing.pytestArgs": ["-vvv", "python"],
19+
"python.testing.unittestEnabled": false,
20+
"python.testing.pytestEnabled": true,
21+
"python.formatting.provider": "black",
2522
"python.linting.mypyEnabled": true,
26-
"python.linting.mypyArgs": ["--show-column-numbers", "--no-pretty"]
23+
"python.linting.mypyArgs": ["--show-column-numbers", "--no-pretty"],
24+
"ruff.args": ["--config=pyproject.toml"]
2725
}

pyproject.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@ testpaths = "tests/"
2929
[tool.setuptools.package-data]
3030
"replicate" = ["py.typed"]
3131

32+
[tool.mypy]
33+
plugins = "pydantic.mypy"
34+
exclude = ["tests/"]
35+
3236
[tool.ruff]
3337
select = [
3438
"E", # pycodestyle error

0 commit comments

Comments
 (0)