test: migrate console conversation sessions and ORM models to SQLite - #40528
Open
asukaminato0721 wants to merge 1 commit into
Open
test: migrate console conversation sessions and ORM models to SQLite#40528asukaminato0721 wants to merge 1 commit into
asukaminato0721 wants to merge 1 commit into
Conversation
asukaminato0721
requested review from
QuantumGhost and
laipz8200
as code owners
August 11, 2026 20:04
Contributor
Pyrefly Diffbase → PR--- /tmp/pyrefly_base.txt 2026-08-11 20:06:24.432324466 +0000
+++ /tmp/pyrefly_pr.txt 2026-08-11 20:06:10.408213641 +0000
@@ -1956,18 +1956,8 @@
--> tests/unit_tests/controllers/console/app/test_app_import_api.py:89:29
ERROR Cannot index into `object` [bad-index]
--> tests/unit_tests/controllers/console/app/test_audio.py:137:17
-ERROR Argument `SimpleNamespace` is not assignable to parameter `current_user` with type `Account` in function `controllers.console.app.conversation._get_conversation` [bad-argument-type]
- --> tests/unit_tests/controllers/console/app/test_conversation_api.py:125:61
-ERROR Argument `SimpleNamespace` is not assignable to parameter `current_user` with type `Account` in function `controllers.console.app.conversation._get_conversation` [bad-argument-type]
- --> tests/unit_tests/controllers/console/app/test_conversation_api.py:134:56
-ERROR Argument `SimpleNamespace` is not assignable to parameter `current_user` with type `Account` in function `controllers.console.app.message._update_message_feedback` [bad-argument-type]
- --> tests/unit_tests/controllers/console/app/test_message_api.py:115:26
-ERROR Argument `SimpleNamespace` is not assignable to parameter `app_model` with type `App` in function `controllers.console.app.message._update_message_feedback` [bad-argument-type]
- --> tests/unit_tests/controllers/console/app/test_message_api.py:116:23
-ERROR Argument `SimpleNamespace` is not assignable to parameter `app_model` with type `App` in function `controllers.console.app.message._get_message_detail` [bad-argument-type]
- --> tests/unit_tests/controllers/console/app/test_message_api.py:138:19
ERROR Argument `Literal['550e8400-e29b-41d4-a716-446655440000']` is not assignable to parameter `message_id` with type `UUID` in function `controllers.console.app.message._get_message_detail` [bad-argument-type]
- --> tests/unit_tests/controllers/console/app/test_message_api.py:139:20
+ --> tests/unit_tests/controllers/console/app/test_message_api.py:179:20
ERROR Argument `list[FromClause]` is not assignable to parameter `tables` with type `Sequence[Table] | None` in function `sqlalchemy.sql.schema.MetaData.create_all` [bad-argument-type]
--> tests/unit_tests/controllers/console/app/test_model_config_api.py:88:51
ERROR Argument `str | None` is not assignable to parameter `s` with type `bytearray | bytes | str` in function `json.loads` [bad-argument-type]
|
Contributor
Pyrefly Type Coverage
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Motivation
The previous response-source tests only asserted calls against mocked model methods. Real persistence now covers the SQL-backed helper properties and nested serialization behavior that the controllers depend on.
Production changes
None.
Size
233 additions, 96 deletions (329 changed lines). This is a cohesive console conversation/message cluster.
Validation