Skip to content

fix: Startup fails when legacy model_type "reranking" exists in DB: "'reranking' is not a valid ModelType'" #34471 - #34472

Closed
hsiong wants to merge 3 commits into
langgenius:mainfrom
hsiong:fix/34471
Closed

hsiong wants to merge 3 commits into
langgenius:mainfrom
hsiong:fix/34471

Conversation

@hsiong

@hsiong hsiong commented Apr 2, 2026

Copy link
Copy Markdown
Contributor

Summary

fix #34471

Screenshots

Before After
... ...

Checklist

  • This change requires a documentation update, included: Dify Document
  • I understand that this PR may be closed in case there was no previous discussion or issues. (This doesn't apply to typos!)
  • I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
  • I've updated the documentation accordingly.
  • I ran make lint and make type-check (backend) and cd web && npx lint-staged (frontend) to appease the lint gods

@dosubot dosubot Bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Apr 2, 2026
@github-actions

github-actions Bot commented Apr 2, 2026

Copy link
Copy Markdown
Contributor

Pyrefly Diff

base → PR
--- /tmp/pyrefly_base.txt	2026-04-02 10:05:39.371130604 +0000
+++ /tmp/pyrefly_pr.txt	2026-04-02 10:05:29.831194349 +0000
@@ -313,6 +313,8 @@
   --> extensions/storage/huawei_obs_storage.py:31:20
 ERROR Argument `Module[Crypto.Hash.SHA1] | Unknown` is not assignable to parameter with type `Hash | HashModule` [bad-argument-type]
   --> libs/gmpy2_pkcs10aep_cipher.py:73:49
+ERROR Returned type `object` is not assignable to declared return type `T` [bad-return]
+   --> models/types.py:138:24
 ERROR No matching overload found for function `redis.client.Redis.__init__` called with arguments: (host=int | str | Unknown, port=int | str | Unknown, password=int | str | Unknown | None, db=int, ssl=bool, ssl_ca_certs=str | None, ssl_cert_reqs=Any | None, ssl_certfile=Any | None, ssl_keyfile=Any | None, socket_timeout=Literal[5], socket_connect_timeout=Literal[5], health_check_interval=Literal[30]) [no-matching-overload]
   --> schedule/queue_monitor_task.py:14:21
 ERROR Object of class `Tenant` has no attribute `role` [missing-attribute]

@github-actions

github-actions Bot commented Apr 3, 2026

Copy link
Copy Markdown
Contributor

Pyrefly Diff

No changes detected.

@hsiong

hsiong commented Apr 12, 2026

Copy link
Copy Markdown
Contributor Author

I found that this issue was fixed in #34717, so I’m closing this. @laipz8200 @QuantumGhost

@hsiong hsiong closed this Apr 12, 2026
@hsiong
hsiong deleted the fix/34471 branch April 12, 2026 01:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: Startup fails when legacy model_type "reranking" exists in DB: "'reranking' is not a valid ModelType'"

1 participant