Skip to content

Commit 904b13d

Browse files
authored
Merge branch 'main' into fix/bound-msteams-sso-api
2 parents da2d62c + 842f8f3 commit 904b13d

59 files changed

Lines changed: 3627 additions & 295 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

apps/.i18n/native-source.json

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -371,79 +371,79 @@
371371
},
372372
{
373373
"kind": "ui-state-text",
374-
"line": 698,
374+
"line": 701,
375375
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
376376
"source": "Offline",
377377
"surface": "android",
378378
"id": "native.android.c65b61de70a063e7"
379379
},
380380
{
381381
"kind": "conditional-branch",
382-
"line": 1628,
382+
"line": 1631,
383383
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
384384
"source": "Cron job started.",
385385
"surface": "android",
386386
"id": "native.android.fef5049bc20826c7"
387387
},
388388
{
389389
"kind": "conditional-branch",
390-
"line": 1628,
390+
"line": 1631,
391391
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
392392
"source": "Cron run queued.",
393393
"surface": "android",
394394
"id": "native.android.c39fb6f80dbf6820"
395395
},
396396
{
397397
"kind": "conditional-branch",
398-
"line": 1672,
398+
"line": 1675,
399399
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
400400
"source": "Cron job disabled.",
401401
"surface": "android",
402402
"id": "native.android.b878b2913410055a"
403403
},
404404
{
405405
"kind": "conditional-branch",
406-
"line": 1672,
406+
"line": 1675,
407407
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
408408
"source": "Cron job enabled.",
409409
"surface": "android",
410410
"id": "native.android.a45ec59239fbfff0"
411411
},
412412
{
413413
"kind": "conditional-branch",
414-
"line": 3279,
414+
"line": 3282,
415415
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
416416
"source": "Failed: no secure gateway endpoint was detected. Enable gateway TLS or Tailscale Serve, or use a trusted private LAN address with Unencrypted selected.",
417417
"surface": "android",
418418
"id": "native.android.4b07456682e725d9"
419419
},
420420
{
421421
"kind": "conditional-branch",
422-
"line": 3281,
422+
"line": 3284,
423423
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
424424
"source": "Failed: secure endpoint reached, but TLS fingerprint verification timed out. Check Tailscale Serve or gateway TLS and retry.",
425425
"surface": "android",
426426
"id": "native.android.467899bb510b8e34"
427427
},
428428
{
429429
"kind": "conditional-branch",
430-
"line": 3283,
430+
"line": 3286,
431431
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
432432
"source": "Failed: couldn't reach the secure gateway endpoint for this host.",
433433
"surface": "android",
434434
"id": "native.android.84ce52ae1375fded"
435435
},
436436
{
437437
"kind": "conditional-branch",
438-
"line": 4056,
438+
"line": 4059,
439439
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
440440
"source": "Update your Gateway to view provider model config.",
441441
"surface": "android",
442442
"id": "native.android.b76bb2741d8344d0"
443443
},
444444
{
445445
"kind": "conditional-branch",
446-
"line": 4058,
446+
"line": 4061,
447447
"path": "apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt",
448448
"source": "Could not load provider model config.",
449449
"surface": "android",

apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -408,6 +408,9 @@ class NodeRuntime private constructor(
408408
val stableId: String,
409409
val id: String,
410410
val decision: String,
411+
// Captured at registration: canonical readback needs it after a refresh has
412+
// already replaced the visible rows, or the legacy get parse drops the row.
413+
val createdAtMs: Long?,
411414
) {
412415
@Volatile var requestInFlight: Boolean = true
413416
}
@@ -5016,7 +5019,13 @@ class NodeRuntime private constructor(
50165019
val currentRows = _execApprovals.value
50175020
if (currentRows.none { it.id == id && it.resolvingDecision == null }) return@synchronized
50185021
if (pendingExecApprovalWrites.containsKey(id)) return@synchronized
5019-
val pendingWrite = PendingExecApprovalWrite(gatewayScope.stableId, id, decision)
5022+
val pendingWrite =
5023+
PendingExecApprovalWrite(
5024+
gatewayScope.stableId,
5025+
id,
5026+
decision,
5027+
currentRows.firstOrNull { it.id == id }?.createdAtMs,
5028+
)
50205029
pendingExecApprovalWrites[id] = pendingWrite
50215030
registeredWrite = pendingWrite
50225031
invalidateExecApprovalRefreshes()
@@ -5232,7 +5241,9 @@ class NodeRuntime private constructor(
52325241
gatewayScope = gatewayScope,
52335242
methodsSnapshot = methodsSnapshot,
52345243
id = pendingWrite.id,
5235-
createdAtMs = _execApprovals.value.firstOrNull { it.id == pendingWrite.id }?.createdAtMs,
5244+
createdAtMs =
5245+
pendingWrite.createdAtMs
5246+
?: _execApprovals.value.firstOrNull { it.id == pendingWrite.id }?.createdAtMs,
52365247
)
52375248
} catch (_: Throwable) {
52385249
return

apps/android/app/src/test/java/ai/openclaw/app/GatewayExecApprovalRuntimeTest.kt

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ class GatewayExecApprovalRuntimeTest {
292292
}
293293

294294
runtime.resolveExecApproval("approval-1", "deny")
295-
withTimeout(2_000) { resolveStarted.await() }
295+
withTimeout(10_000) { resolveStarted.await() }
296296

297297
// GatewaySession runs onDisconnected before failing the retired socket's
298298
// request waiters. Recreate that production ordering on the same stable ID.
@@ -346,7 +346,7 @@ class GatewayExecApprovalRuntimeTest {
346346
}
347347

348348
runtime.resolveExecApproval("approval-1", "deny")
349-
withTimeout(2_000) { resolveStarted.await() }
349+
withTimeout(10_000) { resolveStarted.await() }
350350
runtime.refreshExecApprovals()
351351
withTimeout(2_000) { refreshReadCompleted.await() }
352352
waitUntil { !runtime.execApprovalsRefreshing.value }
@@ -418,7 +418,7 @@ class GatewayExecApprovalRuntimeTest {
418418
}
419419

420420
runtime.resolveExecApproval("approval-1", "deny")
421-
withTimeout(2_000) { resolveStarted.await() }
421+
withTimeout(10_000) { resolveStarted.await() }
422422
runtime.refreshExecApprovals()
423423
withTimeout(2_000) { retainedReadStarted.await() }
424424

@@ -604,7 +604,7 @@ class GatewayExecApprovalRuntimeTest {
604604
}
605605

606606
runtime.resolveExecApproval("approval-1", "allow-once")
607-
withTimeout(2_000) { resolveStarted.await() }
607+
withTimeout(10_000) { resolveStarted.await() }
608608
invokeApprovalEvent(
609609
runtime,
610610
"exec.approval.resolved",
@@ -653,7 +653,7 @@ class GatewayExecApprovalRuntimeTest {
653653
}
654654

655655
runtime.resolveExecApproval("approval-1", "allow-once")
656-
withTimeout(2_000) { resolveStarted.await() }
656+
withTimeout(10_000) { resolveStarted.await() }
657657
invokeApprovalEvent(
658658
runtime,
659659
"exec.approval.resolved",
@@ -756,7 +756,7 @@ class GatewayExecApprovalRuntimeTest {
756756
}
757757

758758
runtime.resolveExecApproval("approval-1", "allow-once")
759-
withTimeout(2_000) { resolveStarted.await() }
759+
withTimeout(10_000) { resolveStarted.await() }
760760
// Replacement hello on the same stable endpoint: the epoch bump makes the
761761
// already-resolved publish a no-op, leaving only the pending-write record.
762762
invokeReplaceGatewayMethods(runtime, legacyMethods)
@@ -1178,7 +1178,8 @@ class GatewayExecApprovalRuntimeTest {
11781178
)
11791179

11801180
private suspend fun waitUntil(condition: () -> Boolean) {
1181-
withTimeout(3_000) {
1181+
// Generous ceiling for loaded CI runners; passing tests exit on first poll.
1182+
withTimeout(10_000) {
11821183
while (!condition()) delay(10)
11831184
}
11841185
}

0 commit comments

Comments
 (0)