Commit Graph

21630 Commits

Author SHA1 Message Date
eduardocruz
b079b36677 fix: address remaining review feedback
- Use base-path-relative manifest URL (no leading slash) so PWA works
  under non-root base paths
- Classify push.web.* methods in WRITE_SCOPE so they work for operator
  sessions without admin scope
- Refresh webPushPermission in the finally block of handleWebPushSubscribe
  so denied permission is immediately reflected in the UI
2026-04-25 04:40:01 -05:00
eduardocruz
8858c3cf01 fix: address review — env var VAPID precedence and bootstrap race guard
- Check OPENCLAW_VAPID_PUBLIC_KEY/PRIVATE_KEY env vars before falling
  back to persisted keys, so operators can share a stable VAPID identity
  across multiple gateway instances
- Wrap VAPID key bootstrap in async lock to prevent concurrent first-run
  callers from generating different keypairs
- Add test for env var precedence
2026-04-25 04:40:01 -05:00
eduardocruz
15437b1153 feat: add PWA support and Web Push notifications to Control UI
Make the Control UI installable as a Progressive Web App and add Web Push
notification infrastructure so the gateway can send browser notifications
to subscribed clients.

PWA shell:
- Add manifest.webmanifest with app name, icons, standalone display
- Add service worker with cache-first for hashed assets, network-first
  for HTML/API, push event handler, and notification click focus
- Register service worker from main.ts
- Serve .webmanifest with correct content type from gateway
- Add worker-src 'self' to CSP

Web Push server (src/infra/push-web.ts):
- VAPID key auto-generation and persistence to state dir
- Subscription CRUD with async-locked atomic JSON storage
- Send and broadcast via web-push library
- Mirrors push-apns.ts patterns

Gateway RPC (4 new methods):
- push.web.vapidPublicKey: returns VAPID public key for PushManager
- push.web.subscribe: registers browser push subscription
- push.web.unsubscribe: removes subscription by endpoint
- push.web.test: broadcasts test notification to all subscribers

Client-side push manager (ui/src/ui/push-subscription.ts):
- Permission request, VAPID key fetch, PushManager subscribe/unsubscribe
- Gateway RPC wiring for registration and test

Settings UI:
- New "Notifications" virtual section in Communications tab
- Shows browser support, permission state, subscription status
- Subscribe/unsubscribe/test buttons

Includes 10 unit tests for push-web subscription CRUD and VAPID keys.
2026-04-25 04:40:01 -05:00
Vincent Koc
2896107153 fix(cron): tolerate malformed legacy jobs 2026-04-25 02:39:06 -07:00
Peter Steinberger
a7604f8170 fix(minimax): support token plan tts auth 2026-04-25 10:36:12 +01:00
Peter Steinberger
7fcefd56b7 chore: bump version to 2026.4.25 2026-04-25 10:31:52 +01:00
Vincent Koc
65ea6a0d94 fix(auth): clarify Codex OAuth region failures (#71501) 2026-04-25 02:31:42 -07:00
Peter Steinberger
c6770d3694 fix: align native think menus with session models 2026-04-25 10:30:49 +01:00
Vincent Koc
0ee9e8188d Merge branch 'main' of https://github.com/openclaw/openclaw
* 'main' of https://github.com/openclaw/openclaw:
  feat: add crestodian local planner fallback
  fix(control-ui): clarify chat context details
  fix(telegram): keep polling watchdog active for wedged runner
2026-04-25 02:22:02 -07:00
Peter Steinberger
9056d4f708 feat: add crestodian local planner fallback 2026-04-25 10:20:02 +01:00
Val Alexander
388270ffce fix(control-ui): clarify chat context details
Summary:
- Show full date and time in Control UI chat message footers.
- Collapse assistant model/token/context metadata behind an explicit Context disclosure.
- Update changelog attribution guidance to allow multi-author credited entries.

Validation:
- OPENCLAW_LOCAL_CHECK=0 pnpm test ui/src/ui/chat/grouped-render.test.ts
- OPENCLAW_LOCAL_CHECK=0 pnpm test src/commands/gateway-status/helpers.test.ts
- OPENCLAW_LOCAL_CHECK=0 pnpm check:changed
- GitHub CI passed on f071a38177
2026-04-25 04:19:56 -05:00
Vincent Koc
c52c161f5a refactor(plugins): compact package json index metadata 2026-04-25 02:18:56 -07:00
Vincent Koc
c959c18fc7 fix(plugins): persist registry enabled snapshot 2026-04-25 02:18:56 -07:00
Vincent Koc
00f47f01fe refactor(plugins): trim persisted plugin registry state 2026-04-25 02:18:56 -07:00
Vincent Koc
3556f8441a feat(plugins): add plugin registry facade 2026-04-25 02:18:56 -07:00
Vincent Koc
36219b0ffc fix(plugins): invalidate index on policy changes 2026-04-25 02:18:56 -07:00
Vincent Koc
b001b8c947 feat(plugins): inspect persisted plugin index state 2026-04-25 02:18:55 -07:00
Vincent Koc
74a384d887 feat(plugins): persist installed plugin index snapshots 2026-04-25 02:18:55 -07:00
Vincent Koc
dfac36ee01 feat(plugins): add cold installed index owner APIs 2026-04-25 02:18:55 -07:00
Peter Steinberger
b756dfcb2b perf: speed up boundary and provider tests 2026-04-25 10:08:46 +01:00
hcl
fd74fc5a4f fix(heartbeat): clamp scheduler delay to Node setTimeout cap (#71414) (#71478)
* fix(heartbeat): clamp scheduler delay to Node setTimeout cap (#71414)

When `agents.defaults.heartbeat.every` resolves to >2_147_483_647 ms
(~24.85d), the previous scheduleNext() called setTimeout with the raw
delay. Node clamps any delay > 2^31-1 to 1 ms, fires the callback, and
the heartbeat re-arms with the same oversized value - a tight loop that
floods the log with TimeoutOverflowWarning and crashes the gateway with
exit code 1.

Clamp the computed delay to HEARTBEAT_MAX_TIMEOUT_MS (2_147_483_647)
before calling setTimeout. The worst case is now one heartbeat every
~24.85d instead of crash-loop. Warn once per process when clamping
fires, so a misconfigured "365d" remains visible without flooding.

This is a defense-in-depth fix at the scheduler layer; loadConfig-level
rejection is a broader change with more blast radius and a separate
question (some users may legitimately want "every: 365d" to mean
"effectively never"). The clamped behaviour is closer to that intent
than the crash is.

Test: new scheduler test sets heartbeat.every="365d" with fake timers,
advances 60s, and asserts runSpy was never called (with the bug, it
would be called ~60_000 times).

* style: format heartbeat scheduler clamp

* fix: share safe timeout delay clamp (#71478) (thanks @hclsys)

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-04-25 10:03:43 +01:00
Peter Steinberger
ed0210a187 test: streamline slow import-heavy suites 2026-04-25 10:02:02 +01:00
Vincent Koc
01bf61fcfd fix(media): remove express from media host (#71436)
* fix(media): remove express from media host

* fix(media): harden media host responses

* fix(msteams): stage express runtime dependency

* fix(browser): align profile facade exports

* fix(msteams): keep setup entry narrow

* fix(types): satisfy extension setup gates

* fix(msteams): use generic setup config type
2026-04-25 01:39:42 -07:00
Vincent Koc
ec1f72b6c5 fix(gateway): preserve restart drain for active runs
Fixes https://github.com/openclaw/openclaw/issues/65485
2026-04-25 01:35:47 -07:00
Peter Steinberger
bc21f500d4 fix: align Codex Responses instructions payload 2026-04-25 09:30:34 +01:00
Peter Steinberger
bf0221c5b3 fix(plugins): preserve bundled cli metadata skip 2026-04-25 09:29:16 +01:00
Peter Steinberger
689a353621 fix(plugins): load packaged runtime mirrors from canonical sources 2026-04-25 09:29:16 +01:00
Peter Steinberger
8503935a21 test: speed up changed unit checks 2026-04-25 09:27:59 +01:00
Vincent Koc
bf0d2d70be fix(session): clean up rollover resources 2026-04-25 01:27:16 -07:00
Peter Steinberger
b0c55eb659 fix(feishu): transcode voice TTS audio 2026-04-25 09:26:42 +01:00
Vincent Koc
bd32b1a906 feat(diagnostics): add outbound delivery lifecycle events
Add bounded outbound message delivery lifecycle diagnostics and OTEL export without message body, recipient, room, media path, or raw channel result data.
2026-04-25 01:26:34 -07:00
Val Alexander
af56926e2f Polish markdown preview chrome
Polish the Control UI markdown preview chrome and sidebar raw-text behavior.

- Add the upgraded preview dialog/sidebar chrome and tighten related CSS coverage.
- Show workspace-relative paths in the markdown preview dialog instead of absolute filesystem paths.
- Preserve raw markdown source for idempotent raw-text toggles.
- Align browser plugin-sdk facade export parity for DEFAULT_BROWSER_ACTION_TIMEOUT_MS.
- Stabilize the gateway update channel test by waiting for the async update runner call.

Validation:
- OPENCLAW_LOCAL_CHECK=0 pnpm test ui/src/ui/views/agents.test.ts ui/src/ui/views/chat.test.ts src/plugins/contracts/plugin-sdk-subpaths.test.ts src/gateway/server.roles-allowlist-update.test.ts
- OPENCLAW_LOCAL_CHECK=0 pnpm check:changed
- GitHub checks green on ebbe96fc88
2026-04-25 03:16:54 -05:00
Peter Steinberger
0e9156d205 test: stabilize Docker CLI backend lane 2026-04-25 09:12:48 +01:00
Sanjay Santhanam
1f06dbd04c fix(agent): recover blank streamed replies from final answer 2026-04-25 09:02:23 +01:00
Peter Steinberger
a4fc6c2409 test: speed up slow unit checks 2026-04-25 08:59:53 +01:00
Peter Steinberger
2011de69d3 feat: add Crestodian setup helper 2026-04-25 08:58:21 +01:00
Peter Steinberger
e0bee76fb0 fix: retire one-shot agent MCP runtimes 2026-04-25 08:58:02 +01:00
Peter Steinberger
1ca029e888 fix: clean up infer MCP runtimes 2026-04-25 08:49:27 +01:00
Peter Steinberger
2b2a300b35 fix: align browser profile facade exports 2026-04-25 08:46:13 +01:00
Peter Steinberger
4a80e61680 fix: reap MCP runtimes on config reload 2026-04-25 08:40:45 +01:00
Vincent Koc
13f4657b88 test(plugins): cover install ledger reload indexing 2026-04-25 00:37:06 -07:00
Vincent Koc
8fd3f4cef2 test(plugins): lock installed index source contract 2026-04-25 00:37:06 -07:00
Vincent Koc
28eb56dd21 fix(plugins): index install ledger source facts 2026-04-25 00:37:05 -07:00
Vincent Koc
15d27d1527 feat(channels): read setup discovery from installed index 2026-04-25 00:37:05 -07:00
Vincent Koc
0b2bc8c5f6 feat(models): read provider owners from installed index 2026-04-25 00:37:05 -07:00
Vincent Koc
ea3e390346 feat(plugins): split cold provider contributions 2026-04-25 00:37:05 -07:00
Vincent Koc
fb4eec54a7 feat(plugins): add installed plugin index 2026-04-25 00:37:04 -07:00
Peter Steinberger
7a71a66571 perf: cache provider env var lookups 2026-04-25 08:35:57 +01:00
Peter Steinberger
e9b27ed2a6 perf: speed up auth choice tests 2026-04-25 08:31:40 +01:00
Peter Steinberger
e0beea97aa perf: speed up focused tests 2026-04-25 08:26:28 +01:00