From 6ed1e4086b2c287c8a5d2ce001fd2ceb04dc9b18 Mon Sep 17 00:00:00 2001 From: codex Date: Tue, 4 Aug 2026 07:39:21 +0300 Subject: [PATCH] fix: activate fixture command queue before dispatch --- .../PRecAnnot.Plant3D2026/FirstLimitedApplyAutomation.cs | 6 +++--- .../tests/PRecAnnot.Core.Tests/FoundationTests.cs | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Plant3D2026/P_Rec_Annot/src/PRecAnnot.Plant3D2026/FirstLimitedApplyAutomation.cs b/Plant3D2026/P_Rec_Annot/src/PRecAnnot.Plant3D2026/FirstLimitedApplyAutomation.cs index df58e30..289711f 100644 --- a/Plant3D2026/P_Rec_Annot/src/PRecAnnot.Plant3D2026/FirstLimitedApplyAutomation.cs +++ b/Plant3D2026/P_Rec_Annot/src/PRecAnnot.Plant3D2026/FirstLimitedApplyAutomation.cs @@ -268,13 +268,13 @@ internal sealed class FirstLimitedApplyAutomationCoordinator { if (IsTerminal || document is null) return; transitions.Add("CommandQueued:" + command); - document.SendStringToExecute(command + "\n", true, false, false); + document.SendStringToExecute(command + "\n", true, true, false); } private void QueueReadinessBarrier() { if (IsTerminal || document is null) return; transitions.Add("ReadinessBarrierQueued"); - document.SendStringToExecute("PHP_REC_AUTOMATION_READY\n", true, false, false); + document.SendStringToExecute("PHP_REC_AUTOMATION_READY\n", true, true, false); } private void OnCommandEnded(object sender, CommandEventArgs e) { @@ -396,7 +396,7 @@ internal sealed class FirstLimitedApplyAutomationCoordinator // Persist the exit boundary before handing control back to AutoCAD; // process termination can otherwise prevent the final evidence flush. TryWriteEvidence(functionalCompleted, null); - exitDocument.SendStringToExecute("_.QUIT _N\n", true, false, false); + exitDocument.SendStringToExecute("_.QUIT _N\n", true, true, false); document = null; automationOpenedDocuments.Clear(); } diff --git a/Plant3D2026/P_Rec_Annot/tests/PRecAnnot.Core.Tests/FoundationTests.cs b/Plant3D2026/P_Rec_Annot/tests/PRecAnnot.Core.Tests/FoundationTests.cs index f2fd317..da7d2f4 100644 --- a/Plant3D2026/P_Rec_Annot/tests/PRecAnnot.Core.Tests/FoundationTests.cs +++ b/Plant3D2026/P_Rec_Annot/tests/PRecAnnot.Core.Tests/FoundationTests.cs @@ -116,7 +116,7 @@ public sealed class FoundationTests Assert.Contains("RequestControlledExit", source); Assert.Contains("AcadApplication.Idle += OnExitIdle", source); Assert.Contains("QuitDispatchAttempted", source); - Assert.Contains("exitDocument.SendStringToExecute(\"_.QUIT _N\\n\", true, false, false);", source); + Assert.Contains("exitDocument.SendStringToExecute(\"_.QUIT _N\\n\", true, true, false);", source); Assert.Contains("var exitDocument = AcadApplication.DocumentManager.MdiActiveDocument;", source); }