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 .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.14.0
rev: v0.15.0
hooks:
# Run the linter.
- id: ruff
Expand Down
1 change: 1 addition & 0 deletions prepare_locales_catalog.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
and copy it to the same directory as this file. Run `python prepare_locales_catalog.py`
and this script will create the articles.{locale}.json files under bring-api/locales.
"""

import glob
import json
import os
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Issues = "https://github.com/miaucl/bring-api/issues"
"Release notes" = "https://github.com/miaucl/bring-api/releases"

[tool.ruff]
target-version = "py314"
target-version = "py311" # Python 3.11

[tool.ruff.lint]
select = [
Expand Down
2 changes: 1 addition & 1 deletion requirements_dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ mypy>=1.8.0
pydantic>=2.9.2
pre-commit>=3.6.1
python-dotenv>=1.0.1
ruff~=0.14
ruff~=0.15
mkdocs-material==9.7.1
mkdocstrings[python]==1.0.2
mashumaro>=3.13.1
Expand Down
18 changes: 9 additions & 9 deletions smoke_test/test_2_methods.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,15 +76,15 @@ async def test_translation(self, bring: Bring, test_list: BringList) -> None:
}
for k, v in test_items.items():
# Save an item an item to
bring.user_list_settings[str(test_list.listUuid)][
"listArticleLanguage"
] = locale_to
bring.user_list_settings[str(test_list.listUuid)]["listArticleLanguage"] = (
locale_to
)
await bring.save_item(test_list.listUuid, v)

# Get all the pending items of a list
bring.user_list_settings[str(test_list.listUuid)][
"listArticleLanguage"
] = locale_from
bring.user_list_settings[str(test_list.listUuid)]["listArticleLanguage"] = (
locale_from
)
items = await bring.get_list(test_list.listUuid)
item = next(ii.itemId for ii in items.items.purchase if ii.itemId == k)
assert item == k
Expand All @@ -93,9 +93,9 @@ async def test_translation(self, bring: Bring, test_list: BringList) -> None:
await bring.remove_item(test_list.listUuid, k)

# reset locale to original value for other tests
bring.user_list_settings[str(test_list.listUuid)][
"listArticleLanguage"
] = locale_org
bring.user_list_settings[str(test_list.listUuid)]["listArticleLanguage"] = (
locale_org
)

async def test_batch_list_operations(
self, bring: Bring, test_list: BringList
Expand Down
Loading