@tomflow/chatloop-extension 0.3.73 → 0.3.74

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -593,6 +593,24 @@
593
593
  if(rUserVersion && rVersion!==rUserVersion){
594
594
  fail("APPROVAL_REQUIREMENTS_VERSION_MISMATCH");return false;
595
595
  }
596
+ // An explicit Chat URL may be adopted after the P-approval assistant
597
+ // finishes, but that reply might instead have issued R2/P2. Such a
598
+ // revision invalidates the earlier P1 approval even if the last user
599
+ // message is still the old standalone confirmation.
600
+ const revisedAfterApproval=rows.slice(lastUser+1).some(x=>{
601
+ if(x.role!=="assistant")return false;
602
+ const text=textOf(x),nextR=versionOf(text,"R"),
603
+ nextP=versionOf(text,"P");
604
+ return Boolean(
605
+ /(?:需求|范围|验收)/.test(text)&&nextR&&nextR!==rVersion
606
+ ||/(?:方案|计划)/.test(text)&&nextP&&nextP!==pVersion
607
+ ||/(?:SUPERSEDED|已失效|已废弃|已撤销)/i.test(text)
608
+ &&/(?:需求|方案|计划|R[1-9][0-9]*|P[1-9][0-9]*)/i.test(text)
609
+ );
610
+ });
611
+ if(revisedAfterApproval){
612
+ fail("APPROVAL_REVISED_AFTER_CONFIRMATION");return false;
613
+ }
596
614
  const userKey=messageId(pUser.el,"user");
597
615
  const snap=inspect();
598
616
  // Normally the model calls Start during its P-confirmation Turn.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "manifest_version": 3,
3
3
  "name": "Chat Loop Extension",
4
- "version": "0.3.73",
4
+ "version": "0.3.74",
5
5
  "description": "Chat Loop browser companion: Eye actions, Turn observer, Continue and Handoff Actions",
6
6
  "permissions": [
7
7
  "activeTab",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tomflow/chatloop-extension",
3
- "version": "0.3.73",
3
+ "version": "0.3.74",
4
4
  "type": "module",
5
5
  "description": "Chat Loop Extension package: nine formal Action pages and its own native CLI bridge",
6
6
  "bin": {