Skip to content

refactor(zalouser): deslop profile and monitor forwarding - #162409

Merged
steipete merged 1 commit into
mainfrom
deslop/l256-dup-channel-plugins-zalouser-20261001
Oct 1, 2026
Merged

steipete merged 1 commit into
mainfrom
deslop/l256-dup-channel-plugins-zalouser-20261001

Conversation

@steipete

@steipete steipete commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Zalo Personal repeats profile normalization already owned by withZaloApi and keeps single-use forwarding helpers around acknowledgement and abort handling.

User Impact

No intended behavior change. Profile identity, credential persistence, delivery/seen ordering, cancellation, config keys, stored state, wire formats, and user-visible text are preserved.

Why This Change Was Made

Ten callers now pass their original profile input to the existing API owner, which normalizes it synchronously before awaiting work. Callers that use the normalized profile for cache, persistence, or multiple operations retain their local value. The acknowledgement sequence keeps one captured argument object and the same catch boundary; abort registration and removal use the existing stable settlement callback directly.

Measured production delta: 17 additions, 37 deletions, 20 net lines removed. No tests, dependencies, or public APIs changed.

Evidence

Independent Codex P0–P2 autoreview completed with no actionable findings.

On Blacksmith Testbox tbx_01m3tth7s6zv8bhz30yzqck42k (run), the repository wrapper verified the candidate source tree 7a829a473e09830208a6725213cea8dbac29781e from base 7e43f459ced39aed2030eb455aa4fcb977d3427a plus this two-file patch:

  • Full Zalo Personal suite: 25 files / 226 tests passed (92 s including preparation).
  • Plugin contracts: 48 files / 1,153 tests passed (66 s).
  • Both cycle checks reported zero; SDK export registration passed.
  • Changed-file checks passed (396 s), including targeted extension type/lint checks and the repository guards.

Existing credential tests cover mixed-case profile selection; listener and monitor cases cover abort, closure, message rejection, account scope and delivery behavior. No tests were added or changed, and no live Zalo messages were sent. Hosted exact-head CI is the final merge gate.

Hosted CI run 36817193822 passed on exact head 17dd06004c8cff5e0b2d4bc10f89985f62cbea20; squash-merged as 58432fd36569356c0f18b1af7b49d66512bb6f40. Merge ancestry was verified on freshly fetched main.

@clawsweeper

clawsweeper Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added channel: zalouser Channel integration: zalouser size: S labels Oct 1, 2026
@steipete
steipete enabled auto-merge (squash) October 1, 2026 04:57
@steipete
steipete merged commit 58432fd into main Oct 1, 2026
93 checks passed
@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Oct 1, 2026
@steipete
steipete deleted the deslop/l256-dup-channel-plugins-zalouser-20261001 branch October 1, 2026 05:01
@clawsweeper

clawsweeper Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed October 1, 2026, 1:01 AM ET / 05:01 UTC.

ClawSweeper review

What this changes

The PR removes redundant Zalo Personal profile normalization and forwarding helpers while preserving acknowledgement ordering and monitor cancellation.

Merge readiness

✅ Ready for maintainer review

Keep open: this remains a useful, focused cleanup absent from inspected main and the latest release. No introduced correctness or security defect was found.

Priority: P3
Reviewed head: 17dd06004c8cff5e0b2d4bc10f89985f62cbea20

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused, maintainable cleanup with relevant reported validation and no actionable finding.
Proof confidence 🌊 off-meta tidepool Not applicable: The verified repository-admin author is exempt from ordinary contributor runtime proof. Reported suite results supplement the inspected profile and monitor equivalence; no stored-data contract or material authority change requires additional proof.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The verified repository-admin author is exempt from ordinary contributor runtime proof. Reported suite results supplement the inspected profile and monitor equivalence; no stored-data contract or material authority change requires additional proof.
Evidence reviewed 8 items Introduced change: The pinned introduction changes only profile forwarding and monitor acknowledgement/abort wrappers. The verified test-merge comparison retains the same two-file scope.
Canonical normalization owner: withZaloApi normalizes the profile synchronously before its first await and retains credential persistence and send-handoff checks. Removed caller normalization is redundant; callers needing normalized cache or persistence keys retain it.
Acknowledgement and settlement equivalence: The monitor still captures one acknowledgement object, awaits delivered before seen, and catches both failures together. The zero-argument settlement callback ignores the event argument and is used consistently for abort registration and removal.
Findings None None.
Security None None.

How this fits together

Zalo Personal connects OpenClaw to personal Zalo accounts. Its API adapter selects saved credential profiles, while its monitor receives messages, sends acknowledgements, and manages listener shutdown.

flowchart TD
  A[Profile input] --> B[Normalize profile]
  B --> C[Zalo API and saved credentials]
  D[Incoming Zalo message] --> E[Message monitor]
  E --> C
  E --> F[Agent dispatch]
  G[Abort signal] --> H[Stop listener and ingress]
  E --> H
Loading

Before merge

None.

Agent review details

Security

None.

PR surface

Source -20. Total -20 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 2 17 37 -20
Tests 0 0 0 0
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 17 37 -20

Review metrics

None.

Technical review

Best possible solution:

Keep profile normalization in the existing API owner and preserve the monitor’s acknowledgement and shutdown contracts.

Do we have a high-confidence way to reproduce the issue?

Not applicable: the PR proposes behavior-preserving cleanup rather than a reported defect.

Is this the best way to solve the issue?

Yes: reusing the existing normalization owner and removing single-use forwarding preserves the inspected contracts without adding another implementation.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 0783e3f28d4e.

Labels

Label changes:

  • add P3: This is a bounded internal cleanup with no intended user-visible behavior change.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: The verified repository-admin author is exempt from ordinary contributor runtime proof. Reported suite results supplement the inspected profile and monitor equivalence; no stored-data contract or material authority change requires additional proof.

Label justifications:

  • P3: This is a bounded internal cleanup with no intended user-visible behavior change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: The verified repository-admin author is exempt from ordinary contributor runtime proof. Reported suite results supplement the inspected profile and monitor equivalence; no stored-data contract or material authority change requires additional proof.

Evidence

What I checked:

  • Introduced change: The pinned introduction changes only profile forwarding and monitor acknowledgement/abort wrappers. The verified test-merge comparison retains the same two-file scope. (extensions/zalouser/src/monitor.ts:208, 17dd06004c8c)
  • Canonical normalization owner: withZaloApi normalizes the profile synchronously before its first await and retains credential persistence and send-handoff checks. Removed caller normalization is redundant; callers needing normalized cache or persistence keys retain it. (extensions/zalouser/src/zalo-js.ts:451, 17dd06004c8c)
  • Acknowledgement and settlement equivalence: The monitor still captures one acknowledgement object, awaits delivered before seen, and catches both failures together. The zero-argument settlement callback ignores the event argument and is used consistently for abort registration and removal. (extensions/zalouser/src/monitor.ts:881, 17dd06004c8c)
  • Current-main necessity: Pinned main still contains the onAbort forwarding wrapper; separately inspected main source retains caller-side normalization in getZaloUserInfo and listZaloFriends. This cleanup is not already implemented there. (extensions/zalouser/src/monitor.ts:889, 0783e3f28d4e)
  • Latest-release comparison: The latest release also retains the acknowledgement helper and abort wrapper, so it does not supersede this cleanup. (extensions/zalouser/src/monitor.ts:185, c074824a27c9)
  • Author status and proof applicability: Live GitHub permission lookup verifies steipete has repository admin access, resolving the differing association fields in the supplied context. The ordinary external-contributor proof gate does not apply; this patch does not materially change authority.

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • lsr911: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

steipete added a commit that referenced this pull request Oct 1, 2026
Reuse canonical parsing, target projection, lifecycle primitives and parameter contracts across channel plugins and the channel SDK. Preserve delivery text, allowlists, pairing, transport behavior, persisted data and public input shapes.

Reject Mattermost JSON-null interaction callbacks through the existing invalid-body HTTP 400 path. Preserve single-account attachment signing and all Slack native command coverage.

Related: #162339, #162409.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 2, 2026
…62409)

## What Problem This Solves

Zalo Personal repeats profile normalization already owned by `withZaloApi` and keeps single-use forwarding helpers around acknowledgement and abort handling.

## User Impact

No intended behavior change. Profile identity, credential persistence, delivery/seen ordering, cancellation, config keys, stored state, wire formats, and user-visible text are preserved.

## Why This Change Was Made

Ten callers now pass their original profile input to the existing API owner, which normalizes it synchronously before awaiting work. Callers that use the normalized profile for cache, persistence, or multiple operations retain their local value. The acknowledgement sequence keeps one captured argument object and the same catch boundary; abort registration and removal use the existing stable settlement callback directly.

Measured production delta: 17 additions, 37 deletions, **20 net lines removed**. No tests, dependencies, or public APIs changed.

## Evidence

Independent Codex P0–P2 autoreview completed with no actionable findings.

On Blacksmith Testbox `tbx_01m3tth7s6zv8bhz30yzqck42k` ([run](https://github.com/openclaw/openclaw/actions/runs/36813922824)), the repository wrapper verified the candidate source tree `7a829a473e09830208a6725213cea8dbac29781e` from base `215c75a82f1859f259d34e4343ccb76970c2ca5a` plus this two-file patch:

- Full Zalo Personal suite: 25 files / 226 tests passed (92 s including preparation).
- Plugin contracts: 48 files / 1,153 tests passed (66 s).
- Both cycle checks reported zero; SDK export registration passed.
- Changed-file checks passed (396 s), including targeted extension type/lint checks and the repository guards.

Existing credential tests cover mixed-case profile selection; listener and monitor cases cover abort, closure, message rejection, account scope and delivery behavior. No tests were added or changed, and no live Zalo messages were sent. Hosted exact-head CI is the final merge gate.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 2, 2026
Reuse canonical parsing, target projection, lifecycle primitives and parameter contracts across channel plugins and the channel SDK. Preserve delivery text, allowlists, pairing, transport behavior, persisted data and public input shapes.

Reject Mattermost JSON-null interaction callbacks through the existing invalid-body HTTP 400 path. Preserve single-account attachment signing and all Slack native command coverage.

Related: openclaw#162339, openclaw#162409.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

channel: zalouser Channel integration: zalouser P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: S status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant