chore(session-mechanism): 交接单目录改名(去 05- 前缀)+图模式触发词改为「图完成目标」

This commit is contained in:
admin committed 2026-10-20 15:49:38 +08:00
1 parent ce05207aa2
commit 5c862e4005
15 files changed
+62 -62

No files matched your search

+4 -4
View File
@@ -3941,7 +3941,7 @@ def active_schedule_exists(name: str) -> bool:
# handoff-guard.sh : dsh-server-docs ai1net-dsh-server aliyun-dsh-server src poc web test
# docs scripts skills 交接单
# lock-guard-hook.py: dsh-server-docs ai1net-dsh-server aliyun-dsh-server src poc web test
# docs 07-scripts 08-skills 05-交接单
# docs 07-scripts 08-skills 交接单
# 差异:`scripts`/`skills` vs `07-scripts`/`08-skills`。⇒ 命中「第一个锚点段」时,
# **工作区下的路径两边结果一致**(都先命中工作区名)⇒ 本节的实际判据不受影响;
# ⚠️ 但**代码仓根目录下的路径**(无工作区名那段)两边会算出不同键 ⇒ 已存在假绿风险。
@@ -3951,7 +3951,7 @@ def active_schedule_exists(name: str) -> bool:
_DS_ANCHORS = ("dsh-server-docs", "ai1net-dsh-server", "aliyun-dsh-server",
"src", "poc", "web", "test", "docs", "scripts", "skills", "交接单")
# ⚠️ 另一份(`lock-guard-hook.py:83 _DOMAIN_SEGS`)—— 🔴 2026-10-03 10:0x **已对齐**:
# 原值是 `07-scripts/08-skills/05-交接单`(带数字前缀的**旧仓目录名**)⇒ 与本表不同
# 原值是 `07-scripts/08-skills/交接单`(带数字前缀的**旧仓目录名**)⇒ 与本表不同
# ⇒ 那个文件里的 `domain_key()` 会跟抢锁侧算出**不同域键** ⇒ 域锁静默失效(假绿)。
# ✅ 已改成 `scripts/skills/交接单`,与 `_DS_ANCHORS` 及 shell 侧**三处逐字一致**。
# ⛔ 本变量**不参与任何计算**,只保留作"另一侧读到什么"的对照;自检会逐字比三处。
@@ -4019,7 +4019,7 @@ def ds_active_domain_locks() -> dict:
"""
out = {}
_me = str(os.environ.get("DSH_SESSION_NAME") or "").strip()
# 🔴🔴 锁根=文档库的 `05-交接单/.locks`。**键名必须与写侧逐字同源:`DSH_DOCS_ROOT`**
# 🔴🔴 锁根=文档库的 `交接单/.locks`。**键名必须与写侧逐字同源:`DSH_DOCS_ROOT`**
# (写侧六处:`lock/handoff-guard.sh:46`/`lock/preflight-lock.sh:30`/`lock/handoff-status.py:40`/
# `lock/orphan-lock.py:203`/`hooks/lock-guard-hook.py:74`/`session-rules-check.py:107`)
# 2026-10-15 修:原读 `DSH_LOCKROOT`/`DSH_DOCS_REPO` —— 这两个键**全包只此一处**读,
@@ -4030,7 +4030,7 @@ def ds_active_domain_locks() -> dict:
_cands.append(os.environ["DSH_LOCKROOT"])
_dr = (os.environ.get("DSH_DOCS_ROOT") or "").strip() # ← 与写侧同源
if _dr:
_cands.append(os.path.join(_dr, "05-交接单", ".locks"))
_cands.append(os.path.join(_dr, "交接单", ".locks"))
root = next((c for c in _cands if os.path.isdir(c)), "")
if not root:
# ⛔ 不再回落到"猜的盘符"(第 11 条禁令):如实报错 + 留痕。