Skip to content

Commit 7c0aeb7

Browse files
committed
update dependencies
1 parent 2398c56 commit 7c0aeb7

8 files changed

Lines changed: 1252 additions & 1061 deletions

File tree

.github/workflows/codecov.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
runs-on: ${{ matrix.os }}
1313
strategy:
1414
matrix:
15-
python-version: ["3.8", "3.9", "3.10", "3.11"]
15+
python-version: ["3.9", "3.10", "3.11", "3.12"]
1616
os: [ubuntu-latest, windows-latest, macos-latest]
1717
fail-fast: false
1818
env:

.github/workflows/update_poetry_lock.yml

Lines changed: 0 additions & 28 deletions
This file was deleted.

nonebot_plugin_session_orm/migrations/71a72119935f_data_migrate.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
创建时间: 2023-10-12 13:31:08.788371
66
77
"""
8+
89
from __future__ import annotations
910

1011
from collections.abc import Sequence

nonebot_plugin_session_orm/migrations/fff55366306e_init_db.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
创建时间: 2023-10-07 16:34:54.127642
66
77
"""
8+
89
from __future__ import annotations
910

1011
from collections.abc import Sequence

nonebot_plugin_session_orm/model.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import asyncio
22
import sys
3-
from typing import List, Optional, Union
3+
from typing import Optional, Union
44

55
from nonebot.log import logger
66
from nonebot_plugin_orm import Model, get_session
@@ -54,7 +54,7 @@ def filter_statement(
5454
include_platform: bool = True,
5555
include_bot_type: bool = True,
5656
include_bot_id: bool = True,
57-
) -> List[ColumnElement[bool]]:
57+
) -> list[ColumnElement[bool]]:
5858
id_type = min(max(id_type, 0), SessionIdType.GROUP_USER)
5959

6060
if session.level == SessionLevel.LEVEL0:
@@ -70,7 +70,7 @@ def filter_statement(
7070
include_id2 = bool((id_type >> 1) & 1)
7171
include_id3 = bool((id_type >> 2) & 1)
7272

73-
whereclause: List[ColumnElement[bool]] = []
73+
whereclause: list[ColumnElement[bool]] = []
7474
if include_bot_id:
7575
whereclause.append(SessionModel.bot_id == session.bot_id)
7676
if include_bot_type:

poetry.lock

Lines changed: 1233 additions & 1026 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,16 @@ homepage = "https://github.com/noneplugin/nonebot-plugin-session-orm"
99
repository = "https://github.com/noneplugin/nonebot-plugin-session-orm"
1010

1111
[tool.poetry.dependencies]
12-
python = "^3.8"
13-
nonebot2 = { version = "^2.2.0", extras = ["fastapi"] }
12+
python = "^3.9"
13+
nonebot2 = "^2.3.0"
1414
nonebot-plugin-session = "^0.3.0"
1515
nonebot-plugin-orm = ">=0.7.0,<1.0.0"
1616

1717
[tool.nonebot]
1818
plugins = ["nonebot_plugin_session_orm"]
1919

2020
[tool.poetry.group.dev.dependencies]
21+
nonebot2 = { version = "^2.3.0", extras = ["fastapi"] }
2122
nonebot-plugin-orm = { extras = ["default"], version = ">=0.7.0,<1.0.0" }
2223
nonebot-plugin-datastore = "^1.0.0"
2324

@@ -31,6 +32,15 @@ aiomysql = "^0.1.0"
3132
[tool.pytest.ini_options]
3233
asyncio_mode = "auto"
3334

35+
[tool.pyright]
36+
pythonVersion = "3.9"
37+
pythonPlatform = "All"
38+
typeCheckingMode = "basic"
39+
40+
[tool.ruff]
41+
line-length = 88
42+
target-version = "py39"
43+
3444
[tool.ruff.lint]
3545
select = ["E", "W", "F", "UP", "C", "T", "PYI", "Q"]
3646
ignore = ["E402", "E501", "E711", "C901", "UP037"]

tests/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def assert_session(
1313
level: "SessionLevel",
1414
id1: Optional[str],
1515
id2: Optional[str],
16-
id3: Optional[str]
16+
id3: Optional[str],
1717
):
1818
assert session.bot_id == bot_id
1919
assert session.bot_type == bot_type

0 commit comments

Comments
 (0)