mirror of
https://github.com/willmiao/ComfyUI-Lora-Manager.git
synced 2026-09-22 03:24:09 -03:00
feat(recipes): remove deprecated Repair Metadata feature
The recipe "Repair Metadata" action has been marked Deprecated in the UI
for a while and cannot reliably recover recipes imported from CivitAI URLs
whose REST meta has no resources/hashes and whose image has no embedded
metadata (e.g. CivitAI-only generation data). Drop the feature end to end.
Backend:
- remove repair routes (repair, cancel-repair, recipe/{id}/repair,
repair-bulk, repair-progress) and their handler mappings/methods
- remove RecipeScanner repair_all_recipes / repair_recipe_by_id /
_repair_single_recipe and REPAIR_VERSION
- remove WebSocketManager recipe-repair progress channel
- drop repair_version column from the persistent recipe cache
- rematch mutual-exclusion now only checks rematch
Frontend:
- remove repair entries from per-recipe, bulk and global context menus
- remove repairRecipe / repairSelectedRecipes / repairRecipes + cancelRepair
and the repairBulk API client method/endpoint
- drop recipe-repair i18n keys (synced across locales; doctor keys kept)
Tests/docs: delete test_recipe_repair.py, update scaffolding/routes/ws/
persistent-cache/integration tests and i18n guideline examples.
This commit is contained in:
@@ -1874,20 +1874,14 @@ async def test_create_from_example_does_not_recompute_stored_autov3(
|
||||
def _clean_recipe_run_progress_state():
|
||||
"""Keep the shared WS manager run-state isolated between tests."""
|
||||
ws_manager._recipe_rematch_progress = None
|
||||
ws_manager._recipe_repair_progress = None
|
||||
yield
|
||||
ws_manager._recipe_rematch_progress = None
|
||||
ws_manager._recipe_repair_progress = None
|
||||
|
||||
|
||||
def _set_rematch_running(status: str = "processing") -> None:
|
||||
ws_manager._recipe_rematch_progress = {"status": status}
|
||||
|
||||
|
||||
def _set_repair_running(status: str = "processing") -> None:
|
||||
ws_manager._recipe_repair_progress = {"status": status}
|
||||
|
||||
|
||||
async def test_rematch_recipes_starts_background_run(monkeypatch, tmp_path: Path) -> None:
|
||||
async with recipe_harness(monkeypatch, tmp_path) as harness:
|
||||
response = await harness.client.post("/api/lm/recipes/rematch")
|
||||
@@ -1911,15 +1905,6 @@ async def test_rematch_recipes_409_when_rematch_running(monkeypatch, tmp_path: P
|
||||
assert "already in progress" in payload["error"].lower()
|
||||
|
||||
|
||||
async def test_rematch_recipes_409_when_repair_running(monkeypatch, tmp_path: Path) -> None:
|
||||
async with recipe_harness(monkeypatch, tmp_path) as harness:
|
||||
_set_repair_running()
|
||||
response = await harness.client.post("/api/lm/recipes/rematch")
|
||||
payload = await response.json()
|
||||
assert response.status == 409
|
||||
assert payload["success"] is False
|
||||
assert "already in progress" in payload["error"].lower()
|
||||
|
||||
|
||||
async def test_rematch_recipe_409_when_rematch_running(monkeypatch, tmp_path: Path) -> None:
|
||||
async with recipe_harness(monkeypatch, tmp_path) as harness:
|
||||
|
||||
Reference in New Issue
Block a user