Skip to content
New issue

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

chore(deps): bump pyright from 1.1.347 to 1.1.348 in /language-server #300

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions LSP-pyright.sublime-settings
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@
"python.analysis.diagnosticSeverityOverrides": {
"reportDuplicateImport": "warning",
"reportImplicitStringConcatenation": "warning",
"reportMissingParameterType": "none",
"reportUnboundVariable": "warning",
"reportUninitializedInstanceVariable": "none",
jfcherng marked this conversation as resolved.
Show resolved Hide resolved
"reportUnusedClass": "information",
"reportUnusedFunction": "information",
"reportUnusedImport": "information",
Expand Down
14 changes: 7 additions & 7 deletions language-server/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion language-server/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"private": true,
"dependencies": {
"pyright": "^1.1.347"
"pyright": "^1.1.348"
}
}
22 changes: 10 additions & 12 deletions scripts/update_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
from __future__ import annotations

import json
from collections.abc import Generator
from pathlib import Path
from typing import Any
from urllib.request import urlopen
Expand Down Expand Up @@ -56,7 +55,7 @@ def read_sublime_package_json() -> tuple[JsonDict, JsonDict]:
return (pyrightconfig_schema_json, sublime_package_schema_json)


def update_schema(sublime_package_json: JsonDict, pyrightconfig_schema_json: JsonDict) -> Generator[str, None, None]:
def update_schema(sublime_package_json: JsonDict, pyrightconfig_schema_json: JsonDict) -> list[str]:
pyrightconfig_contribution: JsonDict | None = None
lsp_pyright_contribution: JsonDict | None = None
for contribution in sublime_package_json["contributions"]["settings"]:
Expand Down Expand Up @@ -92,16 +91,15 @@ def update_schema(sublime_package_json: JsonDict, pyrightconfig_schema_json: Jso
# then it might have to be added manually.
all_settings_keys = [key.rpartition(".")[2] for key in settings_properties.keys()]
all_overrides_keys = settings_properties["python.analysis.diagnosticSeverityOverrides"]["properties"].keys()

yield from (
pyrightconfig_key
for pyrightconfig_key in pyrightconfig_properties.keys()
if not (
pyrightconfig_key in all_settings_keys
or pyrightconfig_key in all_overrides_keys
or pyrightconfig_key in IGNORED_PYRIGHTCONFIG_KEYS
)
)
new_schema_keys = []
for pyrightconfig_key in pyrightconfig_properties.keys():
if (
pyrightconfig_key not in all_settings_keys
and pyrightconfig_key not in all_overrides_keys
and pyrightconfig_key not in IGNORED_PYRIGHTCONFIG_KEYS
):
new_schema_keys.append(pyrightconfig_key)
return new_schema_keys


def update_property_ref(property_key: str, property_schema: JsonDict, pyrightconfig_properties: JsonDict) -> None:
Expand Down
48 changes: 48 additions & 0 deletions sublime-package.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,30 @@
"enableTypeIgnoreComments": {
"$ref": "sublime://pyrightconfig#/properties/enableTypeIgnoreComments"
},
"reportAbstractUsage": {
"$ref": "sublime://pyrightconfig#/properties/reportAbstractUsage"
},
"reportArgumentType": {
"$ref": "sublime://pyrightconfig#/properties/reportArgumentType"
},
"reportAssertAlwaysTrue": {
"$ref": "sublime://pyrightconfig#/properties/reportAssertAlwaysTrue"
},
"reportAssertTypeFailure": {
"$ref": "sublime://pyrightconfig#/properties/reportAssertTypeFailure"
},
"reportAssignmentType": {
"$ref": "sublime://pyrightconfig#/properties/reportAssignmentType"
},
"reportAttributeAccessIssue": {
"$ref": "sublime://pyrightconfig#/properties/reportAttributeAccessIssue"
},
"reportCallInDefaultInitializer": {
"$ref": "sublime://pyrightconfig#/properties/reportCallInDefaultInitializer"
},
"reportCallIssue": {
"$ref": "sublime://pyrightconfig#/properties/reportCallIssue"
},
"reportConstantRedefinition": {
"$ref": "sublime://pyrightconfig#/properties/reportConstantRedefinition"
},
Expand Down Expand Up @@ -129,12 +147,24 @@
"reportInconsistentConstructor": {
"$ref": "sublime://pyrightconfig#/properties/reportInconsistentConstructor"
},
"reportInconsistentOverload": {
"$ref": "sublime://pyrightconfig#/properties/reportInconsistentOverload"
},
"reportIndexIssue": {
"$ref": "sublime://pyrightconfig#/properties/reportIndexIssue"
},
"reportInvalidStringEscapeSequence": {
"$ref": "sublime://pyrightconfig#/properties/reportInvalidStringEscapeSequence"
},
"reportInvalidStubStatement": {
"$ref": "sublime://pyrightconfig#/properties/reportInvalidStubStatement"
},
"reportInvalidTypeArguments": {
"$ref": "sublime://pyrightconfig#/properties/reportInvalidTypeArguments"
},
"reportInvalidTypeForm": {
"$ref": "sublime://pyrightconfig#/properties/reportInvalidTypeForm"
},
"reportInvalidTypeVarUse": {
"$ref": "sublime://pyrightconfig#/properties/reportInvalidTypeVarUse"
},
Expand All @@ -159,6 +189,12 @@
"reportMissingTypeStubs": {
"$ref": "sublime://pyrightconfig#/properties/reportMissingTypeStubs"
},
"reportNoOverloadImplementation": {
"$ref": "sublime://pyrightconfig#/properties/reportNoOverloadImplementation"
},
"reportOperatorIssue": {
"$ref": "sublime://pyrightconfig#/properties/reportOperatorIssue"
},
"reportOptionalCall": {
"$ref": "sublime://pyrightconfig#/properties/reportOptionalCall"
},
Expand All @@ -180,6 +216,9 @@
"reportOverlappingOverload": {
"$ref": "sublime://pyrightconfig#/properties/reportOverlappingOverload"
},
"reportPossiblyUnboundVariable": {
"$ref": "sublime://pyrightconfig#/properties/reportPossiblyUnboundVariable"
},
"reportPrivateImportUsage": {
"$ref": "sublime://pyrightconfig#/properties/reportPrivateImportUsage"
},
Expand All @@ -189,6 +228,12 @@
"reportPropertyTypeMismatch": {
"$ref": "sublime://pyrightconfig#/properties/reportPropertyTypeMismatch"
},
"reportRedeclaration": {
"$ref": "sublime://pyrightconfig#/properties/reportRedeclaration"
},
"reportReturnType": {
"$ref": "sublime://pyrightconfig#/properties/reportReturnType"
},
"reportSelfClsParameterName": {
"$ref": "sublime://pyrightconfig#/properties/reportSelfClsParameterName"
},
Expand Down Expand Up @@ -264,6 +309,9 @@
"reportUnusedCoroutine": {
"$ref": "sublime://pyrightconfig#/properties/reportUnusedCoroutine"
},
"reportUnusedExcept": {
"$ref": "sublime://pyrightconfig#/properties/reportUnusedExcept"
},
"reportUnusedExpression": {
"$ref": "sublime://pyrightconfig#/properties/reportUnusedExpression"
},
Expand Down