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

Bump Ruff version #49

Merged
merged 1 commit into from
Dec 31, 2022
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
5 changes: 3 additions & 2 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,13 @@ mypy-extensions==0.4.3
# mypy
pathspec==0.10.3
# via black
platformdirs==2.6.0
platformdirs==2.6.2
# via black
pygls==1.0.0
# via ruff-lsp (pyproject.toml)
python-lsp-jsonrpc==1.0.0
# via ruff-lsp (pyproject.toml)
ruff==0.0.194
ruff==0.0.204
# via ruff-lsp (pyproject.toml)
tomli==2.0.1
# via
Expand All @@ -52,6 +52,7 @@ typing-extensions==4.4.0
# cattrs
# importlib-metadata
# mypy
# platformdirs
# ruff-lsp (pyproject.toml)
ujson==5.6.0
# via python-lsp-jsonrpc
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ lsprotocol==2022.0.0a9
# via pygls
pygls==1.0.0
# via ruff-lsp (pyproject.toml)
ruff==0.0.194
ruff==0.0.204
# via ruff-lsp (pyproject.toml)
typeguard==2.13.3
# via pygls
Expand Down
2 changes: 1 addition & 1 deletion ruff_lsp/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ def code_action(params: CodeActionParams) -> list[CodeAction] | None:

title: str
if fix.get("message"):
title = f"Ruff: {fix['message']}"
title = f"Ruff ({diagnostic.code}): {fix['message']}"
elif diagnostic.code:
title = f"Ruff: Fix {diagnostic.code}"
else:
Expand Down
3 changes: 1 addition & 2 deletions ruff_lsp/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,7 @@ def run_path(
result = subprocess.run(
argv,
encoding="utf-8",
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
capture_output=True,
check=False,
cwd=cwd,
)
Expand Down
2 changes: 2 additions & 0 deletions tests/test_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ def _handler(params):
},
"data": {
"content": "",
"message": "Remove unused import: `sys`",
"location": {"row": 1, "column": 0},
"end_location": {"row": 2, "column": 0},
},
Expand Down Expand Up @@ -122,6 +123,7 @@ def _handler(params):
},
"data": {
"content": "",
"message": "Remove unused import: `sys`",
"location": {"row": 1, "column": 0},
"end_location": {"row": 2, "column": 0},
},
Expand Down