fix(admin): use task_name column (not task_type) in _is_generating query
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1722,7 +1722,7 @@ async def _get_article_stats() -> dict:
|
||||
async def _is_generating() -> bool:
|
||||
"""Return True if a generate_articles task is currently pending."""
|
||||
row = await fetch_one(
|
||||
"SELECT COUNT(*) AS cnt FROM tasks WHERE task_type = 'generate_articles' AND status = 'pending'"
|
||||
"SELECT COUNT(*) AS cnt FROM tasks WHERE task_name = 'generate_articles' AND status = 'pending'"
|
||||
)
|
||||
return bool(row and row["cnt"] > 0)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user