mirror of
https://gitcode.com/JianFeeeee/TrulyMEM-TrueHumanMEM.git
synced 2026-09-20 08:58:15 +00:00
fix: _init_graph 更新 _db_path 修复用户隔离
问题: - _init_graph 正确解析了用户 DB 路径,但未更新 self._db_path - web_api.py 的 create_server() 用 backend_server._db_path 创建 graph_db - 导致所有用户共用一个 CWD/graph_memory.db(回忆图谱页面数据混在一起) - 同时 jianf 的 config.json 首次创建时空 apikey,未正确写回 修复: - _init_graph 解析用户路径后,同步更新 self._db_path - 现在各用户 graph_db 和 config.json 完全隔离
This commit is contained in:
@ -217,6 +217,7 @@ class BackendServer:
|
||||
temp_db.close()
|
||||
if user_info and user_info.get('db_path'):
|
||||
db_path = user_info['db_path']
|
||||
self._db_path = db_path # 更新 _db_path,供外部(如 web_api.py)获取正确的路径
|
||||
except Exception:
|
||||
pass # 如果获取失败,使用默认路径
|
||||
|
||||
|
||||
Reference in New Issue
Block a user