1322 Commits

Author SHA1 Message Date
Vincent Koc
45fff13b1d
TUI: strip only leading inbound metadata (#22461) 2026-02-21 01:13:02 -05:00
Vignesh Natarajan
cd6bbe8cea Session: enforce startup sequence on bare reset greeting 2026-02-20 20:38:56 -08:00
hcoj
5dae5e6ef2
fix(tools): forward senderIsOwner to embedded runner so owner-only tools work (#22296)
Merged via /review-pr -> /prepare-pr -> /merge-pr.

Prepared head SHA: 0baca5ccc11c83727fe3db02b6ef6b11b421e698
Co-authored-by: hcoj <1169805+hcoj@users.noreply.github.com>
Co-authored-by: obviyus <22031114+obviyus@users.noreply.github.com>
Reviewed-by: @obviyus
2026-02-21 08:33:58 +05:30
Mars
a4e7e952e1
fix(ui): strip injected inbound metadata from user messages in history (#22142)
* fix(ui): strip injected inbound metadata from user messages in history

Fixes #21106
Fixes #21109
Fixes #22116

OpenClaw prepends structured metadata blocks ("Conversation info",
"Sender:", reply-context) to user messages before sending them to the
LLM. These blocks are intentionally AI-context-only and must never reach
the chat history that users see.

Root cause:
`buildInboundUserContextPrefix` in `inbound-meta.ts` prepends the
blocks directly to the stored user message content string, so they are
persisted verbatim and later shown in webchat, TUI, and every other
rendering surface.

Fix:
• `src/auto-reply/reply/strip-inbound-meta.ts` — new utility with a
  6-sentinel fast-path strip (zero-alloc on miss) + 9-test suite.
• `src/tui/tui-session-actions.ts` — wraps `chatLog.addUser(...)` with
  `stripInboundMetadata()` so the TUI never stores the prefix.
• `ui/src/ui/chat/message-normalizer.ts` — strips user-role text content
  items during normalisation so webchat renders clean messages.

* fix(ui): strip inbound metadata for user messages in display path

* test: fix discord component send test spread typing

* fix: strip inbound metadata from mac chat history decode

* fix: align Swift metadata stripping parser with TS implementation

* fix: normalize line endings in inbound metadata stripper

* chore: document Swift/TS metadata-sentinel ownership

* chore: update changelog for inbound metadata strip fix

* changelog: credit Mellowambience for 22142

---------

Co-authored-by: Vincent Koc <vincentkoc@ieee.org>
2026-02-20 17:35:13 -08:00
Shadow
f555835b09
Channels: add thread-aware model overrides 2026-02-20 19:26:25 -06:00
Shadow
eedea6cf34
Discord: add trusted channel topics on new sessions 2026-02-20 18:22:13 -06:00
Glucksberg
38b4fb5d55
fix(auth/session): preserve override reset behavior and repair oauth profile-id drift (openclaw#18820) thanks @Glucksberg
Verified:
- pnpm build
- pnpm check
- pnpm test:macmini

Co-authored-by: Glucksberg <80581902+Glucksberg@users.noreply.github.com>
Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
2026-02-19 21:16:26 -06:00
Vishal
f1e1cc4ee3
feat: surface cached token counts in /status output (openclaw#21248) thanks @vishaltandale00
Verified:
- pnpm build
- pnpm check
- pnpm test:macmini

Co-authored-by: vishaltandale00 <9222298+vishaltandale00@users.noreply.github.com>
Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
2026-02-19 21:06:13 -06:00
lbo728
d6fbed7904 fix: prevent whatsapp fallback for webchat sessions
Fixes #21444

When connecting via Hub Chat/webchat, the runtime channel was incorrectly
defaulting to 'whatsapp' instead of being omitted or set to 'webchat'.

Root cause: The channel resolution fallback chain (OriginatingChannel ->
Surface -> Provider) would use Provider even for webchat sessions, where
Provider may be unrelated (e.g., the user's default configured channel).

Changes:
- Add explicit webchat detection before falling back to Provider
- Skip Provider fallback when Surface is 'webchat' or Provider is 'webchat'
- Channel field is now undefined for webchat sessions (no incorrect label)

This ensures webchat sessions don't receive WhatsApp-specific formatting
hints (no markdown tables, no headers) and fixes the runtime label.
2026-02-19 18:41:57 -08:00
ahdernasr
e321f21daa
fix: serialize tool result delivery to preserve message ordering (#21231)
Merged via /review-pr -> /prepare-pr -> /merge-pr.

Prepared head SHA: 68adbf58c8ec92d32e6183b0c6432963b2b4f9d8
Co-authored-by: ahdernasr <44983175+ahdernasr@users.noreply.github.com>
Co-authored-by: joshavant <830519+joshavant@users.noreply.github.com>
Reviewed-by: @joshavant
2026-02-19 17:23:23 -08:00
Josh Avant
c2876b69fb
feat(auto-reply): add model fallback lifecycle visibility in status, verbose logs, and WebUI (#20704) 2026-02-19 14:33:02 -08:00
Shakker
7579e9511e Auto-reply: delay onAgentRunStart until real activity 2026-02-19 19:15:09 +00:00
Isis Anisoptera
4b7d89100e
fix(auto-reply): restore prompt cache stability by moving per-turn ids to user context (#20597)
Merged via /review-pr -> /prepare-pr -> /merge-pr.

Prepared head SHA: 175919afb67af3b5a5a11a801d0ee2e47bac449b
Co-authored-by: anisoptera <768771+anisoptera@users.noreply.github.com>
Co-authored-by: mbelinky <132747814+mbelinky@users.noreply.github.com>
Reviewed-by: @mbelinky
2026-02-19 19:11:47 +00:00
Peter Steinberger
a1cb700a05 test: dedupe and optimize test suites 2026-02-19 15:19:38 +00:00
Peter Steinberger
3d7ad1cfca fix(security): centralize owner-only tool gating and scope maps 2026-02-19 15:29:23 +01:00
Peter Steinberger
a40c10d3e2 fix: harden agent gateway authorization scopes 2026-02-19 14:37:56 +01:00
Peter Steinberger
0e85380e56 style: format files and fix safe-bins e2e typing 2026-02-19 14:26:12 +01:00
Peter Steinberger
1316e57403 fix: enforce inbound attachment root policy across pipelines 2026-02-19 14:15:51 +01:00
Peter Steinberger
771af40913 chore(ci): fix main check blockers and stabilize tests 2026-02-19 10:15:25 +00:00
Peter Steinberger
49d0def6d1 fix(security): harden imessage remote scp/ssh handling 2026-02-19 11:08:23 +01:00
Peter Steinberger
b4dbe03298 refactor: unify restart gating and update availability sync 2026-02-19 10:00:41 +01:00
Peter Steinberger
7d12c5ea4d test: remove duplicate extra-high think-level case 2026-02-19 08:30:26 +00:00
Peter Steinberger
69e6da0e28 test(auto-reply): dedupe heartbeat typing flow setup 2026-02-19 08:25:12 +00:00
Ayaan Zaidi
221d50bc18 fix: preserve assistant partial stream during reasoning 2026-02-19 00:05:10 -08:00
Peter Steinberger
9a490fbbeb test: drop duplicate followup compaction token assertion 2026-02-19 07:57:24 +00:00
Peter Steinberger
ff1189c6d6 test: remove duplicate inbound-meta coverage from reply-flow 2026-02-19 07:41:52 +00:00
Peter Steinberger
bd4fdfc356 test(reply): dedupe compaction session fixture setup 2026-02-19 07:37:06 +00:00
Peter Steinberger
9ac6f46735 test(messaging): dedupe parser/proxy/followup test scaffolding 2026-02-19 07:24:02 +00:00
Peter Steinberger
b22deada9e refactor(queue): reuse collect-mode item drain flow 2026-02-19 07:01:54 +00:00
Peter Steinberger
2f6b8663ff refactor(shared): reuse outbound text chunking core 2026-02-19 07:01:54 +00:00
Peter Steinberger
8d048d412f refactor(queue): share next-item drain helper across queue drains 2026-02-19 06:43:36 +00:00
Peter Steinberger
989c9dbd37 refactor(auth): share remaining-time formatter 2026-02-19 00:17:31 +00:00
Peter Steinberger
136bd59ba5 refactor(shared): centralize @/# slug normalization 2026-02-18 23:34:15 +00:00
Peter Steinberger
d54a4a08b2 refactor(auto-reply): dedupe allowlist path and name helpers 2026-02-18 23:09:09 +00:00
Peter Steinberger
8b257703d8 refactor(auto-reply): reuse abort session-entry resolver 2026-02-18 23:09:09 +00:00
Peter Steinberger
6eb0964fa6 refactor(auto-reply): share standard set/unset slash parsing 2026-02-18 23:09:09 +00:00
Peter Steinberger
2157385ff6 refactor(auto-reply): share unique model catalog insertion 2026-02-18 22:40:26 +00:00
Peter Steinberger
d7a6a0a0b9 refactor(reply): share embedded run fallback/context builders 2026-02-18 19:02:25 +00:00
Peter Steinberger
307719abe9 fix(types): align restart sentinel and typing test mocks 2026-02-18 18:25:25 +00:00
Peter Steinberger
0def1ac1d2 refactor(commands): share session entry persistence 2026-02-18 18:25:25 +00:00
Peter Steinberger
06b2df9fc7 refactor(reply): share verbose gate helpers 2026-02-18 18:25:25 +00:00
Peter Steinberger
efd6ed9a56 refactor(subagents): dedupe list line rendering 2026-02-18 18:25:25 +00:00
Peter Steinberger
bec94449eb refactor(subagents): share run target resolution 2026-02-18 18:25:25 +00:00
Peter Steinberger
85ebdf88b0 refactor(agents): share text block extraction helper 2026-02-18 18:25:25 +00:00
Peter Steinberger
1aa4d3a6f0 refactor(queue): share runtime settings and summary helpers 2026-02-18 18:25:25 +00:00
Peter Steinberger
7b2697bd4d refactor(auto-reply): reuse native command spec mapping 2026-02-18 17:48:01 +00:00
Peter Steinberger
f46bcbe16d refactor(auto-reply): share slash set/unset command parsing 2026-02-18 17:48:01 +00:00
Peter Steinberger
8ab90858ba refactor(auto-reply): share command action arg formatting 2026-02-18 17:23:44 +00:00
Peter Steinberger
0d25b6a317 perf(test): remove fixed sleeps in async test flows 2026-02-18 17:20:35 +00:00
Peter Steinberger
00e32cf04a test(auto-reply): type set/unset action helper expectations 2026-02-18 17:16:36 +00:00