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
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ line-length = 88
extend-exclude = ["tests/profiles/syntax_error.py"]

[tool.ruff.lint]
extend-select = ["C", "FA", "FLY", "I", "ISC001", "TID251", "UP006", "UP007", "UP008", "UP010", "UP012", "UP017", "UP024", "UP035", "UP040", "UP041", "RUF100", "B009", "B010", "B011", "BLE", "DTZ005", "D202", "PLR1733", "RUF022", "PLW1510", "TC004", "PIE790", "PERF402", "FURB129", "RET501", "LOG"]
extend-select = ["C", "FA", "FLY", "I", "ISC", "TID251", "UP006", "UP007", "UP008", "UP010", "UP012", "UP017", "UP024", "UP035", "UP040", "UP041", "RUF100", "B009", "B010", "B011", "BLE", "DTZ005", "D202", "PLR1733", "RUF022", "PLW1510", "TC004", "PIE790", "PERF402", "FURB129", "RET501", "LOG"]
ignore = ["UP047", "UP045", "S", "C901", "RUF", "SIM", "B017", "TRY004", "TRY201", "TRY203", "TRY401", "B008", "EXE001", "G201", "ISC004", "PYI034", "PYI064"]

[tool.ruff.lint.flake8-tidy-imports.banned-api]
Expand Down
8 changes: 4 additions & 4 deletions src/utils/token_counter.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ def __str__(self) -> str:
"""
return (
f"{self.__class__.__name__}: "
+ f"input_tokens: {self.input_tokens} "
+ f"output_tokens: {self.output_tokens} "
+ f"counted: {self.input_tokens_counted} "
+ f"LLM calls: {self.llm_calls}"
f"input_tokens: {self.input_tokens} "
f"output_tokens: {self.output_tokens} "
f"counted: {self.input_tokens_counted} "
f"LLM calls: {self.llm_calls}"
)
4 changes: 2 additions & 2 deletions tests/unit/models/config/test_cors.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,8 @@ def test_cors_improper_configuration() -> None:
"""
expected = (
"Value error, Invalid CORS configuration: "
+ "allow_credentials can not be set to true when allow origins contains the '\\*' wildcard."
+ "Use explicit origins or disable credentials."
"allow_credentials can not be set to true when allow origins contains the '\\*' wildcard."
"Use explicit origins or disable credentials."
)

with pytest.raises(ValueError, match=expected):
Expand Down
4 changes: 2 additions & 2 deletions tests/unit/utils/test_ogx_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ async def test_check_ogx_version_too_small_version(

expected_exception_msg = (
f"OGX version >= {MINIMAL_SUPPORTED_OGX_VERSION} "
+ "is required, but 0.0.0 is used"
"is required, but 0.0.0 is used"
)
# test if the version is checked
with pytest.raises(InvalidOgxVersionException, match=expected_exception_msg):
Expand All @@ -84,7 +84,7 @@ async def _check_version_must_fail(mock_client: Any, bigger_version: Version) ->

expected_exception_msg = (
f"OGX version <= {MAXIMAL_SUPPORTED_OGX_VERSION} is required, "
+ f"but {bigger_version} is used"
f"but {bigger_version} is used"
)
# test if the version is checked
with pytest.raises(InvalidOgxVersionException, match=expected_exception_msg):
Expand Down
Loading