Skip to content
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
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
repos:
# Ruff for linting and formatting
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.15.12 # Keep in sync ruff version with pyproject.toml
rev: v0.15.16 # Keep in sync ruff version with pyproject.toml
hooks:
# Run the linter
- id: ruff
Expand All @@ -11,7 +11,7 @@ repos:

# mypy for type checking
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v2.0.0 # Keep in sync mypy version with pyproject.toml
rev: v2.1.0 # Keep in sync mypy version with pyproject.toml
hooks:
- id: mypy
args: [--config-file=pyproject.toml]
Expand Down
4 changes: 2 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,6 @@
- `download_folder` in `utils.find_existing_language_tool_downloads` from `str` to `Path`
- Edited return types of some methods/functions:
- from `str` to `Path` in `utils.get_language_tool_download_path`
- from `List[str]` to `List[Path]` in `utils.find_existing_language_tool_downloads`
- from `list[str]` to `list[Path]` in `utils.find_existing_language_tool_downloads`
- from `str` to `Path` in `utils.get_language_tool_directory`
- from `Tuple[str, str]` to `Tuple[Path, Path]` in `utils.get_jar_info`
- from `tuple[str, str]` to `tuple[Path, Path]` in `utils.get_jar_info`
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ install:
uv sync --all-groups --locked

format:
uv run --group quality --locked ruff format language_tool_python tests
uv run --group quality --locked ruff format

fix:
uv run --group quality --locked ruff check --fix language_tool_python tests
uv run --group quality --locked ruff check --fix

ruff-check:
uv run --group quality --locked ruff check language_tool_python tests
uv run --group quality --locked ruff format --check language_tool_python tests
uv run --group quality --locked ruff check
uv run --group quality --locked ruff format --check

mypy-check:
@if uv run --locked python -c 'import sys; raise SystemExit(0 if sys.version_info >= (3, 10) else 1)'; then \
Expand Down
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -308,9 +308,11 @@ Exit codes:
- `LTP_JAR_DIR_PATH`: use an existing local LanguageTool directory (skip download).
- `LTP_DOWNLOAD_HOST_SNAPSHOT`: override snapshot download host.
- default: `https://internal1.languagetool.org/snapshots/`
- `LTP_DOWNLOAD_HOST_RELEASE`: override release download host.
- `LTP_DOWNLOAD_HOST_NEW_RELEASES`: override release download host for LanguageTool `>= 6.7`.
- default: `https://github.com/jxmorris12/language_tool_python/releases/download/LanguageTool-{version}/`
- `LTP_DOWNLOAD_HOST_RELEASE`: override release download host for LanguageTool `6.0` to `6.6`.
- default: `https://languagetool.org/download/`
- `LTP_DOWNLOAD_HOST_ARCHIVE`: override archive download host.
- `LTP_DOWNLOAD_HOST_ARCHIVE`: override archive download host for LanguageTool `4.0` to `5.9`.
- default: `https://languagetool.org/download/archive/`
- `LTP_DOWNLOAD_SHA256_<VERSION>`: version-specific expected SHA-256 for the downloaded LanguageTool archive, for example `LTP_DOWNLOAD_SHA256_6_9_SNAPSHOT`.
- `LTP_DOWNLOAD_SHA256`: fallback expected SHA-256 for the downloaded LanguageTool archive.
Expand Down
4 changes: 2 additions & 2 deletions language_tool_python/__init__.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
"""LanguageTool API for Python."""

__all__ = [
"LanguageTag",
"LanguageTool",
"LanguageToolPublicAPI",
"LanguageTag",
"Match",
"utils",
"exceptions",
"utils",
]

import logging
Expand Down
Loading