8 Commits
Author SHA1 Message Date
qihu-bot 552a962123 #977 时间错位8小时彻底修复 - _beijing_now返回aware
CI / gate (push) Has been cancelled
根因: _beijing_now返回naive datetime(无时区), PG timestamptz列按UTC误解, 存13:53UTC前端按Asia/Shanghai显示21:53错位8小时。修复: 去掉replace(tzinfo=None)返回aware datetime(带+08:00), PG正确转UTC存储, 前端正确显示。
2026-08-18 14:01:57 +08:00
qihu-bot ab11283d92 #976 微信对话同步WebClaw修复 + admin连接时间统一北京时间
CI / gate (push) Has been cancelled
1.mirror_to_ai_chat: _uuid→uuid(NameError被except吞了, 对话从未同步到webclaw) 2.im_bot_admin加_beijing_now并替换5处datetime.now()(容器UTC存naive时间前端按+08:00展示错位8小时)
2026-08-18 13:47:07 +08:00
QihuAI Design a2504bce34 fix(chat): resolve Auto-route failover event-loop freeze (#812)
Root cause: ensure_structured_column() executed a synchronous blocking
engine.connect().execute(SELECT information_schema.columns ...) inside the
async request path (_build_chat_history / _maybe_compress_history), freezing
the uvicorn event loop and hanging all endpoints (~200s, recovered only by
docker restart).

Fix:
- chat_context.py: remove per-request ensure_structured_column() calls; run
  once idempotently at app startup (main.py lifespan). Use CURRENT_DATABASE()
  for PostgreSQL compatibility.
- main.py: add startup-only ensure_structured_column() hook (try/except).
- llm_client.py: trust_env=False + bounded httpx.Timeout/wait_for so broken
  endpoints fail fast instead of hanging the event loop.
- chat_service.py: run media generation in a background daemon thread with its
  own event loop (_launch_media_task_bg) so SSE end does not cancel image/video
  tasks (#811); remove TEMP faulthandler diagnostic.

Safe-align: persist accumulated live container changes (admin/*, knowledge,
market, models, config, observability, mcp_client, platform_knowledge,
im_bot_platform, chat_media, capability_registry, requirements) and add
workflow_templates.

Verified: live failover test (model-006 -> conn-refused) returns in ~1.9s with
concurrent login 0.83s/200; event-loop responsiveness restored (sub-second).
2026-07-26 00:35:35 +08:00
QihuAI Design ab54d7344c refactor: 移除通用频道管理(LangBot)模块,IM Bot 改为直接对接;迁移 _call_real_llm 至 im_llm 2026-07-14 08:21:56 +08:00
qyyfw e8e5ffa1a9 fix: 恢复 rsync 误删的近期开发(agents/skills/mcp/knowledge/workflow/tenant/billing/storage/privacy/promotion/achievement/automation/code-exec/developer/distribution/im-bot/portal/casdoor 等后端模块 + 对应前端页面路由, 补回 main.py 挂载与 App.tsx 路由 2026-07-11 11:40:39 +08:00
qyyfw 5d7f32db0a refactor: sync running-container source back to repo for reproducible docker compose build; remove dead code (orphan pipeline.py + 104 stale files from iterative dev) and drop unused app/ mirror dir 2026-07-11 06:29:32 +08:00
WorkBuddy 75a708a14d feat: 个人微信改为前台每用户独立绑定(按 user_id 隔离),后台仅保留全局 Bot 2026-07-09 20:53:25 +08:00
qyyfw 7daeae6fc7 Phase 4: IM Bot Integration - admin module, frontend, LangBot gateway, routing rules, quick setup wizard 2026-07-06 19:59:05 +08:00