ConfigPublishCoordinator dispatched a deployment exactly once: on DPS a node whose
deployments registry entry had not gossiped to central missed it (#1106), on gRPC a
failed dial was dropped, and either way the deployment timed out at 120 s.
Coordinator: re-sends the same DispatchDeployment at +5/+15/+35 s (bounded by half the
remaining deadline) with the new additive TargetNodes naming only expected nodes whose
ack has not arrived (an ack still being persisted counts). Stops on last ack,
completion, time-out, supersede or schedule end; a recovered in-flight deployment gets
the same re-send. Counter otopcua.deploy.redispatched.
Transport: CentralCommunicationActor's gRPC fan dials only the named nodes; proto gains
repeated target_nodes = 4 (additive). On DPS, non-addressed nodes ignore the re-send.
Node (DriverHostActor): a re-send is idempotent per DeploymentId — ignored if not
addressed here or mid-apply; ANY copy of a deployment whose Applied ack is held on the
address-space outcome no longer starts a second apply; a re-send of a deployment it
already acked re-delivers the remembered ack (last 16) instead of re-applying (#601
would otherwise re-apply a degraded revision). Original dispatches are unchanged.
Docs: Redundancy.md §Dispatch re-send, Configuration.md, cluster-topology rule.
The deploy-seal timeouts (#843/#1106) were a lost dispatch, not a slow one. Reproduced 3 times
under CPU stress (load 250-430, 1 in ~3-18 runs) with new diagnostics: node B's DriverHost never
logged "reading artifact", its row stayed Applying, and the deployment was still AwaitingApplyAcks
60 s after the wait gave up. The deploy was published 13 ms after node B came Up - before node A's
DistributedPubSub mediator had received B's registry bucket (exchanged on its own 1 s gossip tick,
independent of cluster membership), so the Publish reached node A's driver host only.
TwoNodeClusterHarness.StartAsync / RestartNodeBAsync now also wait until both nodes' DPS
registries carry both nodes' `deployments` subscriptions and the same non-empty
`deployment-acks` set (read off the mediator by reflection; test-only).
Regression test: with pub-sub gossip-interval = 10s a deploy started right after StartAsync
fails deterministically without the wait (exact #1106 signature) and seals with it.
Diagnostics: the seal-timeout message (now on DeployHappyPathTests too) carries each node's DPS
registry view for the deploy topics, both nodes' recent Akka log events / dead letters, and a
60 s late-seal watch that says "slow, not lost" vs "lost, not slow".
Production note: the same window exists on the DPS transport (fire-and-forget dispatch, no
re-dispatch; the 120 s apply deadline closes it TimedOut). Follow-up to be filed.
Same treatment #1100 gave the heartbeat bounds, each assertion keeping its meaning:
- Runaway soft answer (was softElapsed < T + 400 ms): now an ORDERING fact - the worker has not
exited when the caller is answered (answered before the hard kill) - plus < T + G. Grace 500 ms ->
2.5 s so a stall cannot push the soft notice past T + G ("script worker unresponsive").
- Kill timing: lower bound T + G - 50 ms unchanged (stall-proof); upper slack 1.5 s -> 2 s, still
< 2 x G and well under the 10 s Exited wait.
- Host CPU window: 1.5 s window / 1 s CPU absolute -> 3 s window, CPU < half the MEASURED wall time
(a spinning orphan burns ~wall; a stall stretches the window, never adds CPU).
- Pipe-close exit (was < 2 s): bound dropped; the meaning is the exit CODE (ExitPipeClosed is only the
worker's own EOF exit), waits 5 s -> 10 s.
Stall check (temporary harness, not committed: SIGSTOP/SIGCONT of the test host + worker pids for
1.2 s every ~2.3 s): new bounds passed 3/3; the old file failed the runaway test 2/2 under the same
harness.
int[][] / byte[][] used to be the one result divergence left after #1100: in process
ScriptResultMaterializer passed it (SdkValueBoundary.FromClr carries it as an array of Variants),
while the worker's wire has no nested-array tag and answered "unsupported type". A script-fed node
has a scalar DataType, so a Variant-of-arrays value is not what it declares either; not documented as
a feature anywhere (only noted as the known divergence). Decision: refuse, via the shared rule.
- IsPublishable: a 1-D array's element must be a PublishableScalarTypes scalar (no recursion).
- EnsurePublishable: a nested array gets its own reason, still "... which an OPC UA node cannot
carry: an array of arrays ...", with a flatten hint (SelectMany). Same "script threw: ..." text in
both runners.
- SdkValueBoundaryScriptResultTests: int[][] leaves the rule==FromClr theory; a separate fact pins
the one deliberate difference (FromClr takes it, the rule refuses).
- ParityTests: "jagged array" + "jagged byte array" rows. ShadowModeTests census: the jagged script
now MATCHES; the unsupported_type mismatch is exercised by a decimal INPUT (design §14 #11), the
real remaining worker-only refusal.
- ContainmentTests.Unsupported_input_and_result_types: jagged now expects the materializer reason.
Mutation: restoring the recursive element check fails 4 tests (2 parity rows, shadow census,
containment unsupported-type).
Behaviour change: a value script returning a jagged array now fails (Bad + script log) in process
too, instead of publishing a Variant array onto a scalar-typed node.
The filter compares a newer source version against the last COMMITTED value, but the reader may hold an
earlier value past IsEligible and not yet committed. A tick in that window dropped a newer value equal to
the old baseline; the earlier value then committed and the client held it until the source changed again.
The worker now records the version it suppressed (cleared when a later version is queued). ValueDelivery.OnCommit,
committing a value older than that, rewinds LastConsidered and marks the source dirty so the next tick
re-evaluates against the new baseline. Pre-existing (predates #1098); independent of shared serving.
Tests (GrpcData1102FilterBaselineTests) park the in-flight value at the reader's pre-commit seam and run the
tick that considers the newer version to completion: value-equal and deadband cases fail without the fix
([2] instead of [2, 1]); a control pins that a queued newer value is still delivered exactly once.
Release, 10k cohort: ~1.69 KB -> 1.65-1.67 KB per delivered value process-wide; queue section 40 B -> 0 B per value.
- ProjectedDataAccess's cohort channel carries a CohortMessage struct (control Event, or frame + charge + received
timestamp); control events convert implicitly, so every writer is unchanged. Slot release, charge and dispose obligations
on the read, drain and finally paths are unchanged.
- GrpcDataWave3PerfTests asserts queue 0 B/value, build < 192 B/value and (Release) < 1.8 KB/value process-wide.
Declined (documented in docs/DataConnections.md): ProjectedValueUpdate+DataValueSnapshot (public publish API, retained by the
publisher), the one-element publish list (reuse needs an ownership promise IProjectedValuePublisher does not make), origin
frame records (public Core.Abstractions contract; the frame is owned by the reader), CachedSourceRead (public, escapes,
identity-based once-only guards).
Release, 10k cohort, 5 runs each: 2.21-2.31 KB -> 1.68-1.72 KB per delivered value, process-wide.
- A live value takes over its hub read's sample lease and charge (CachedSourceRead.TryTransferSample:
same amount, same budget; the read keeps its source guard until disposed) instead of retaining a
second copy and reserving a second charge. Re-stamped with the item's serving only when it differs.
- ValueLease holds a reference on the item's SharedSessionLease directly (no Hold per value); the
release order (charge, item, snapshot) and once-only guard are unchanged.
- The latest-sample cache keeps the published update itself for a scalar payload (arrays still copied).
- The cohort's frame window is a FrameSlotWindow (SemaphoreSlim semantics: over-release throws, a
cancelled wait takes no slot) on one reused SlotWaiter and one registration per attempt; the pump
waited for nearly every frame, each wait allocating a task, state machine and registration.
- SlotWaiter (moved out of the session) now makes a re-arm wait out a signaller still inside SetResult,
so the old signal cannot complete the next wait; it is hot now (one wait per frame under load).
- Indexed loops for the pump's frame sizing and DataSubscriptionValues.Dispose (no boxed enumerators).
- ClientFilterState keeps its baseline's compared fields and value lease, not a re-wrapped sample.
Pooling ValueLease/ValueDelivery (~150 B) is declined: the lease escapes as the public
DataSubscriptionValues.ResourceLease and a delivery's Gate is handed to the gRPC sink as a publication
guard, so a recycled object could release or authorize for another value.
Tests (GrpcData1098OwnershipTests) fail on a read releasing a transferred sample, a lease not holding
its item, a frame-window double release / lost wakeup, and a re-arm racing a completing signal.
ShadowModeTests counted 'return 1.5m;' as an unsupported_type mismatch (in process Ok decimal, worker
'unsupported type'). Since 9dbccf231 both runners refuse it with the same reason, so it matches; the one
result the worker alone still refuses is a jagged array (no nested-array wire tag), which takes its place.
ScriptedAlarmEngine.PreparePredicates called DependencyExtractor and refused on !IsValid — a second copy of
the rule ScriptCompileRules owns since #1083 (RefusesNonLiteralTagPaths / TagPathFindings), which the deploy
gate and the editor read. Now ScriptCompileRules.PathRefusals(kind, source, extraction?) is the one verdict
and text ("dependency extraction rejected — …") for both the gate (RoslynDeployScriptChecker) and the engine.
TagPathFindings takes an optional extraction so the engine, which still needs the extraction's Reads, parses
once. Behaviour identical: for AlarmPredicate every rejection refuses with its extractor message, joined "; ".
ScriptedAlarmEngineTagPathRuleParityTests runs 8 predicates (literal, two literals, variable, concatenated,
interpolated, empty, two refusals, dynamic beside a literal) through the gate and a real engine load and
asserts refused <=> refused with the gate's exact text; plus a control that the table holds both outcomes.
Mutation: an engine rule that refuses only empty paths fails 6 of 8 rows.
ProjectedDataAccess gets a test-only IProjectedPublishProbe (null in production) over six synchronous
sections: the stream pump, the frame queue, the cohort loop's dispatch, a value's build, its publication
and the frame's release. The perf harness prints them and the remainder against the process-wide figure.
Release, 10k cohort, 5 runs: the ~600-650 B/value that #1094 left unattributed is Pump 84-209 (the LINQ
Sum's boxed enumerator plus SemaphoreSlim.WaitAsync under a full frame window), Queue 40 (FrameEvent),
Build 184 (DataValueSnapshot + ProjectedValueUpdate), Publish 208 (the latest-sample cache re-wrapping
the update in two identical records, plus the one-element list), Release 55-88 (enumerators boxed by
the frame disposes); 15-51 B/value stays unattributed (other threads).
Audit of the heartbeat / silence / liveness-kill bounds in ScriptWorker.Tests after cb5250fac (#1092):
- PipeFaultTests (reader stalls, heartbeats continue): silence 5 x 200 ms = 1 s -> 2 s, write-stall 2 s -> 5 s.
The silence limit must stay below the write-stall limit or "killed unresponsive, not for silence" proves
nothing. Mutation (worker stops heartbeating when its reader stalls): KilledHeartbeat at ~2 s, test fails.
- WorkerSoftClockTests.The_progress_ceiling_leaves_a_worker_that_keeps_answering_alone: ceiling 1 s over
20 x 150 ms -> 2.5 s over 40 x 150 ms. Mutation (no progress stamp on a Results frame): killed
KilledUnresponsive, queued runs complete null, test fails.
- SupervisionTests burst test: kept at 3 s (production's limit; frames every 50 ms, so only a ~2.95 s stall
trips it; raising it would stop it catching the 3 s windev defect). Comment records the decision.
- The two #1092 tests (1.5 s) and the never-reports-progress test (lower bound only) are already stall-safe.
Stall check, temporary instrumentation (libc kill SIGSTOP/SIGCONT of the worker pid, not committed): a 1.2 s
stall failed the old PipeFault bounds 3/3 and a 1 s stall failed the old ceiling bounds; the new bounds passed
1.2 s stalls 3/3 each. (A first attempt that spawned /bin/kill measured a 2.5 s stall, not 1 s — process
spawn on the loaded box — and was discarded.)
Where an in-process result really ends up: VirtualTagActor -> VirtualTagHostActor -> OpcUaPublishActor ->
OtOpcUaNodeManager.WriteValueLocked -> SdkValueBoundary.FromClr (VariantHelper.TryCastFrom). Probed against
SDK 2.0.1: Guid / Guid[] become an OPC UA Guid scalar/array; KeyValuePair<,>[] (a returned Dictionary),
decimal, enum, TimeSpan, char, DateTimeOffset, tuples, Nullable<T>[] and rank>1 arrays are refused, so the
node write threw, OpcUaPublishActor logged a Warning, and the node kept its PREVIOUS value and status (a
silent freeze, possibly under Good) while the worker answered "unsupported type".
Decision, per type, by what a client can see:
- Guid (scalar + 1-D array): representable -> the wire gains an additive GUID tag (15, `bytes g = 10`,
16 ToByteArray bytes; a wrong length is a protocol fault). Guid INPUTS cross too. protocol_version stays 1:
the worker ships in the host's script-worker/ folder, and an unknown tag already fails closed.
- Everything FromClr refuses: refused identically in both runners by ScriptResultMaterializer, inside the run,
with one reason ("script threw: The script returned a value of type 'KeyValuePair<Int32, Double>[]', which
an OPC UA node cannot carry; return ..."). A lazy unpublishable sequence is refused before it runs.
ScriptResultMaterializer.PublishableScalarTypes / IsPublishable own the set.
Pins: SdkValueBoundaryScriptResultTests (OpcUaServer.Tests, new Core.Scripting ref) checks IsPublishable ==
"FromClr takes it" over 34 values; ProtocolTests checks the wire carries every publishable type scalar + array;
ParityTests gains guid / guid array / guid list / dictionary / KVP[] / lazy KVPs / KVP / decimal / decimal[] /
enum / TimeSpan / char[] / 2-D rows, a Guid unboxing row, and a positive+negative control. Mutations: with the
type check disabled 11 parity tests fail; with Guid not encoded 9 protocol/parity tests fail.
Behaviour change: a value script returning a Dictionary, decimal, enum, TimeSpan, char or tuple now fails
(Bad + script log) in process too, instead of "succeeding" and leaving its node frozen. Remaining divergence:
a jagged array (publish path carries it as Variant[], worker answers "unsupported type") — follow-up.
SupervisionTests.A_caller_that_blocks_after_its_result_does_not_starve_the_reader and its
WorkerSoftClockTests sibling killed a healthy worker for "sent nothing for ~344 ms" at a
300 ms limit (3 x 100 ms) on a loaded macOS box. Investigated before loosening, with
send-stamped heartbeats (temporary instrumentation, not committed):
- the late beats were late at the WORKER (290-380 ms between sends, 1-150 ms transit), mid
run, not during startup;
- a cold worker beat every 100 +/- 8 ms from its first beat in 50 isolated runs at load
60-200, with and without 28 CPU burners, and in full-suite runs under 40 burners, with the
heartbeat on the thread pool or on a dedicated thread alike (A/B) — no JIT / Roslyn /
pool-injection starvation to fix;
- the stalls appeared only in a full-suite run under the real load of other agents, with the
box 24 of 25.6 GB into swap: whole-process stalls no worker change removes.
So the tests take a 1.5 s limit (production: 3 s) and block the caller 3.5 s. Mutation still
caught: with callers resumed inline on the reader both fail (the Supervision test by the
heartbeat kill itself). 20/20 runs of the pair pass.
ScriptResultMaterializer returned a non-array ICollection as-is (capped by Count only), so
in process the host got the List<double> itself while the out-of-process worker, whose wire
carries arrays but no collection type, answered "unsupported type" for the same script.
Every non-array, non-string sequence now goes through the one materialisation: a collection
is held to Scripting:MaxResultElements by its Count before it is copied, then becomes T[]
of its IEnumerable<T> element type; an open element type (List<object>, List<List<int>>) or
none (ArrayList) is refused like the lazy equivalent. Both runners give double[] for a
List<double>.
ParityTests.Result_materialisation_and_the_element_cap_agree gains list / at-cap / over-cap
/ hash set / queue / List<object> / nested-list rows plus a positive control (6 rows + the
control fail against the old materializer). ContainmentTests' "unsupported result type"
example moves from List<int> (now int[]) to KeyValuePair<int,int>.
Behaviour change: a script returning List<object> (or another open element type) now fails
the run (Bad + script log) in process too, as the lazy form already did.
#1083: OTSCRIPT_DYNPATH was an error in every editor mode while the deploy gate refuses a
non-literal tag path only for a scripted-alarm predicate (editor stricter than the gate).
Decision: do not make the gate stricter (it would reject configurations that deploy today).
ScriptCompileRules now owns the split — RefusesNonLiteralTagPaths(kind) and
TagPathFindings(kind, source), each finding carrying Refuses — the gate refuses on exactly
those findings and the editor draws them as errors (8) and the rest as warnings (4), whose
text says what the path does at runtime (not a declared input: not subscribed, does not
re-trigger, reads BadNodeIdUnknown unless also read literally). DependencyRejection gains
Kind + MethodName for that wording. EditorGateParityTests carries dynamic / concatenated /
interpolated / empty paths in all three modes (14 rows fail with the old always-error
severity).
#1093: hovering a {{equip}} path literal in Calculation mode showed the VirtualTag
"resolves ... when deployed" text, contradicting the OTSCRIPT_EQUIPCALC marker on the same
span. It now says the token is refused in a Calculation script and why (no owning
equipment, never substituted, the gate refuses it). The {{equip}} hover no longer needs a
tag catalog.
#1084 - DataExport.AllowSecuredWrites (default false; migration AddDataExportAllowSecuredWrites, a bit NOT NULL DEFAULT 0
column, no constraint => no MigrationPreChecks twin; the preflight's legacy-schema tolerance covers the missing column).
- Valid only with Write: validator code DataExportSecuredWriteInvalid at authoring, the deploy gate and on a deployed
row (an artifact row breaking it fails closed), modelled on AllowGalaxyServiceAck.
- LocalExportCatalog keeps it per rule (counts only with Write) and answers AllowsSecuredWrite(principal, node): an
export of the principal, in the node's realm, granting Write, opted in, whose root contains the node.
- DataWriteExecutor stamps DataWriteAdmission.AllowsSecuredWrite (new, default false) from the catalog generation that
admitted the write (re-checked by the dispatch gate's commit), never from the request.
- DriverInstanceActor.RichCaller returns null without it, so the driver gets NO caller: the driver option
MxAccess.SecuredWritesOverDataConnections alone no longer lets a forwarding consumer cluster's link key write
SecuredWrite attributes. Fail closed by default.
- AdminUI export editor: "Allow secured writes under this peer's key identity" checkbox (enabled only with Write).
#1091 (a) - GalaxyDriver implements IWriteOutcomeCapability + ICallerAwareWriteOutcomeCapability. GalaxyWriteOutcomes
maps BadUserAccessDenied and the OnWriteComplete verdicts BadNotWritable/BadTypeMismatch/BadOutOfRange/
BadConfigurationError to DriverConfirmedFailure, Good to AcceptedUnconfirmed (a provisional Good is indistinguishable),
everything else to OutcomeUnknown. A refused secured write is now a definite BadUserAccessDenied, not OutcomeUnknown.
- RunRichWriteAsync precedence: caller-aware outcome overload (caller present) -> outcome overload -> ICallerAwareWritable
(caller present) -> IWritable. Both earlier behaviours kept; the OPC UA path is unchanged.
Tests (each failed before its fix where applicable):
- End to end through the runtime path (artifact -> catalog -> DataWriteRuntime executor -> ActorDataWriteRoute ->
DriverInstanceActor behind the real dispatch gate -> real GalaxyDriver): export opt-in x driver option matrix; only
both commit as the key's identity, either alone refuses BadUserAccessDenied definitively with no identity lookup.
Ignoring the flag in RichCaller fails 3 tests.
- Catalog scope (root containment, Write, principal), artifact round-trip + fail-closed row, validator, migration SQL +
no pending model changes, AdminUI checkbox enable/save (bUnit), actor precedence, Galaxy outcome mapping.
- ScriptForeignKeysAndExternalIdUniquenessMigrationTests now migrate to THEIR migration, not the latest.
Docs: DataConnections.md (two-gate table), Galaxy.md, security.md, rules/drivers.md.
- ICallerAwareWritable and the new ICallerAwareWriteOutcomeCapability join the guarded-interface list. Each derives
from a guarded interface but declares its OWN member, which is not an implementation of the base's, so
callerAware.WriteAsync(writes, caller, ct) on an interface or concrete receiver passed unflagged.
- ICallerAwareWriteOutcomeCapability (Core.Abstractions.DataConnections): IWriteOutcomeCapability on behalf of a
WriteCaller, for the gRPC data-connection write path (used by the Galaxy driver, next commit).
- Tests: unwrapped caller-aware WriteAsync trips on interface AND concrete receivers; the caller-aware outcome
overload trips unwrapped and passes wrapped (positive control). Both failed (0 diagnostics) with the two
entries removed from the list.
- WriteCaller gains an additive Origin (WriteCallerOrigin: Unspecified (default) | OpcUaSession | DataConnection),
stamped by the runtime at the receiving seam: OtOpcUaNodeManager -> OpcUaSession, the rich (gRPC data-connection)
write path -> DataConnection. Never parsed from the principal/key.
- New driver-config option MxAccess.SecuredWritesOverDataConnections (default false; factory key
mxAccess.securedWritesOverDataConnections; AdminUI "Also for gRPC data-connection writes", owned path). The
Galaxy driver gives a caller an identity source only in ApiKeyIdentity mode AND for an allowed origin:
OpcUaSession always, DataConnection only with the option, Unspecified never (fail closed). Off => a secured write
over a data connection is refused exactly as before #1074 (local BadUserAccessDenied, no identity lookup; the gRPC
caller sees the same OutcomeUnknown as before).
- Tests: option off refuses a gRPC write end to end into the real GalaxyDriver (with an OPC UA positive control on
the same driver); option-on end-to-end kept; driver-level origin matrix incl. Unspecified; factory binding; AdminUI
round-trip; node-manager callers now carry OpcUaSession.
- Docs: Galaxy.md (origin table, opt-in, forwarded-write delegation caveat, live-gate leg), security.md,
DataConnections.md, Configuration.md, rules/drivers.md.
- DriverInstanceActor's rich write path (RouteRichWrite -> WriteAttributeWithOutcome) now hands an
ICallerAwareWritable driver WriteCaller(principal, apiKeyId) taken from the DataWriteAdmission, i.e.
the connection's authenticated DataAuthenticatedContext (never the request payload), re-checked by the
dispatch gate's commit. Same caller shape as the OPC UA path (#1017). No proto change: the identity was
already server-side. IWriteOutcomeCapability keeps precedence (no driver implements both today).
- Fail-closed unchanged: Galaxy resolves only the key's own identity (no fallback); no identity => refused.
- Tests: rich write reaches the caller-aware overload with the admitted principal/key (failed before: the
caller-less overload was used); OPC UA WriteAttribute and gRPC rich write deliver equal WriteCallers; a
real GalaxyDriver in ApiKeyIdentity mode resolves the connection key's identity end to end.
- Docs: Galaxy.md (gRPC path, federated writes run as the LINK key's identity, refusal reported as
OutcomeUnknown on the legacy path), DataConnections.md, security.md, rules/drivers.md.
- PendingDelivery is an abstract base: ValueDelivery carries a value's state in fields (was a closure +
seven delegates per value), DelegateDelivery keeps the delegate form for controls/acks/conditions.
One ValueLease replaces BudgetLease + one or two CompositeLeases (same release order).
- EnqueueAsync returns ValueTask and completes synchronously when a slot is free. A full window waits on
the session's reused SlotWaiter (signalled by every dequeue and by Stop, which sets _closed first)
instead of the channel's WriteAsync (a writer operation + cancellation registration per wait); the
wait and TickAsync/PumpSnapshotsAsync/ConsiderAsync use PoolingAsyncValueTaskMethodBuilder, as do the
reader's MoveNextAsync/NextPendingAsync. The #994 behaviour is unchanged: an ack meeting a full window
waits for the reader and never resets the stream.
- ConsiderAsync decides 'already considered / not yet due' on a version peek before taking a full
cache read (CachedSourceRead + sample copy + value).
- The tick signal is one shared immutable Work.
New test: a worker waiting on a full window ends when the stream stops and releases what it held
(fails if Stop does not wake the waiter).
The held runner's stale timer was created only after its loop had unwound, so under load the
BadNoCommunication mark came a full stale timeout after a slow unwind - late, or skipped when the
MaxHold release (timed from the hold) ended the hold first. The timer now starts with the hold; a
mark due before the unwind waits for it (no late Good from that loop can follow the mark) and lands
at the unwind.
Tests (fake clock, ProjectedConditionAccess on ManualTimeProvider; the fixture can gate the runner's
lease release to model a slow unwind): the mark lands at the unwind when it fell due earlier, still
before MaxHold (failed before the fix: no mark, the release came first); and lands exactly at hold
start + stale timeout with a prompt unwind.
#1063: the Monaco diagnostics dropped every Roslyn error located in the synthesized
wrapper as 'phantom', so CS0161 (not all code paths return a value, pinned on Run)
passed the editor and failed the deploy gate. ScriptCompileRules (Core.Scripting) now
states which diagnostics refuse (every Error, wherever located; LMX001/002 injection)
and which sources skip the compile (blank/passthrough value scripts); ScriptEvaluator
and the editor both use it, and the editor wraps with ScriptEvaluator.WrapperPreamble/
WrapperSuffix instead of its own copy. Wrapper-located refusals are drawn on the
script's last line. EditorGateParityTests runs one corpus through editor and gate in
all three modes.
#1065: a Calculation tag is raw/device-level with no equipment and its seam never
substitutes {{equip}}, so such a script deployed clean and read Bad forever. Refused
rather than substituted: EquipTokenLiteralScanner.FindInCalculation is run by
RoslynDeployScriptChecker for every Calculation use (before the passthrough shortcut,
outside the shared VT/Calc cache) and by the editor in the new 'calculation' mode
(Calculation tag editor; ScriptEdit defaults to it when a Calculation tag uses the
script).
Confirmed, deterministically: Context.Stop is asynchronous and messages from two children are unordered, so an operator
Restart's old child announced comms loss from PostStop AFTER the replacement had connected and pushed its initial values
(the old child reaches its stop only once a synchronous driver call returns). The host then stamped every value node
BadNoCommunication with nothing left to re-publish them, re-latched them and cancelled the new incarnation's recovery
audit - nodes stuck Bad, tripwire disarmed. Pre-fix the new test saw 2 status batches where 1 is correct.
Fix at the root, in DriverHostActor.OnDriverConnectivityChanged: IsStaleRetiredConnectivity drops, whole, any
Connected=true from a retired child, and its Connected=false once the current child of the same id has announced
Connected (new ChildEntry.Connected, set only from the current child's own edges). A retired Bad edge is still applied
while the replacement has not connected (or there is none) - the 03/S15 gap cover Restart/respawn rely on; same rule the
condition-signal tracker already applied. Senders that were never children are not filtered.
Tests (DriverHostStaleConnectivityTests): the race made deterministic by wedging the old child in a blocking
GetHostStatuses; positive control = a Force Reconnect of the current child must yield exactly one status batch before the
re-subscribe push. Companion: a retired Bad edge before the replacement connects still stamps Bad and the push recovers.
Co-Authored-By: Claude <noreply@anthropic.com>
RawTree gains an opt-in single-select NodePickMode (any entity kind); new UnsRootPicker and
DataRootPickerModal; cluster-scoped trees built from the draft snapshot. Stored kinds and
validation unchanged.