Repository navigation
Conversation
Greptile SummaryThis PR fixes two Feishu regressions: (1) repeated tool/hook registration on plugin cache misses, addressed with a module-level idempotency flag in The implementation is sound and regression tests cover both scenarios. One architectural note: Confidence Score: 5/5Safe to merge — both regressions are correctly fixed with targeted, backward-compatible changes and regression tests. No P0 or P1 issues found. The idempotency guard and named-account promotion filter are logically correct, consistent with the Telegram precedent, and covered by focused tests. The only note is an architectural P2 about hardcoded channel names in the early-migration fallback table, which is an existing pattern rather than a new one. No files require special attention. Reviews (1): Last reviewed commit: "fix(feishu): preserve top-level groupPol..." | Re-trigger Greptile |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 782e3f3eb5
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| if (feishuToolsRegistered) { | ||
| return; | ||
| } | ||
| feishuToolsRegistered = true; |
There was a problem hiding this comment.
Scope Feishu full-registration guard to each registry load
This module-level feishuToolsRegistered flag makes registerFull a one-shot for the lifetime of the process, so any later full registration (for example an activating plugin reload) will skip all Feishu hook/tool registration. loadOpenClawPlugins explicitly clears previously registered plugin state on activating reloads (src/plugins/loader.ts:1132-1138), so after the first reload Feishu can end up with no subagent hooks/tools in the new registry even though the plugin is still loaded.
Useful? React with 👍 / 👎.
|
Thanks for the context here. I swept through the related work, and this is now duplicate or superseded. The PR addresses a real Feishu regression, but it is not merge-ready because the duplicate-registration fix uses a process-global guard that can skip Feishu hook/tool registration for a rebuilt plugin registry, and the external PR still lacks inspectable redacted real Feishu proof. Canonical path: Close this stale PR. The latest review rated it F, the branch still lacks merge-ready proof, and there has been no human follow-up after the durable review. So I’m closing this here because the remaining work is already tracked in the canonical issue. Review detailsBest possible solution: Close this stale PR. The latest review rated it F, the branch still lacks merge-ready proof, and there has been no human follow-up after the durable review. Do we have a high-confidence way to reproduce the issue? Yes. Source inspection gives a high-confidence path for both sides: current config normalization can move top-level Feishu policy without a named-account filter, and the PR's process-global guard can skip registration after a registry rebuild; I did not run a live Feishu session in this read-only review. Is this the best way to solve the issue? No, not as written. The named-account promotion fix is a plausible narrow direction, but the duplicate-registration fix belongs at a registry/API or loader lifecycle boundary rather than a process-lifetime module flag. Security review: Security review cleared: No concrete security or supply-chain regression was found; the diff changes Feishu registration/config normalization and tests without new dependencies, workflows, permissions, secret handling, or network calls. AGENTS.md: found and applied where relevant. What I checked:
Likely related people:
Codex review notes: model internal, reasoning high; reviewed against 865e4db1cd0a. |
|
ClawSweeper PR egg 🎁 Pass real behavior proof to wake the egg and unlock a hatchable treat. Where did the egg go?
|
|
This pull request has been automatically marked as stale due to inactivity. |
|
ClawSweeper applied the proposed close for this PR.
|
Summary
groupPolicy: "open"back toallowlist.groupPolicyrewrite blocks group replies even when the user explicitly configured Feishu groups to stay open.registerFull, declared Feishu-specific named-account promotion keys, added the early promotion fallback used by legacy config loading, and locked the behavior with regression tests.Change Type (select all)
Scope (select all touched areas)
Linked Issue/PR
Root Cause (if applicable)
registerFullhad no idempotency guard when plugin loader cache misses caused re-registration, and Feishu had no named-account promotion contract, so legacy config normalization treated shared top-level policy keys like single-account fields and movedgroupPolicyintoaccounts.default.groupPolicy: "open".channels.feishu.defaultAccount = "main"with namedmain/candyaccounts and a top-levelgroupPolicy, which hits the legacy promotion path.Regression Test Plan (if applicable)
extensions/feishu/index.test.ts,extensions/feishu/src/setup-surface.test.ts,src/commands/doctor-legacy-config.migrations.test.tsgroupPolicyand avoid synthesizingaccounts.default.User-visible / Behavior Changes
channels.feishu.groupPolicyagain when named accounts are configured.registerFullto rerun.Diagram (if applicable)
N/A.
Security Impact (required)
Yes/No): NoYes/No): NoYes/No): NoYes/No): NoYes/No): NoYes, explain risk + mitigation: N/ARepro + Verification
Environment
channels.feishu.defaultAccount = "main", namedmain/candyaccounts, top-levelgroupPolicy = "open", wildcard group route withrequireMention = falseSteps
groupPolicy: "open".Expected
channels.feishu.groupPolicystaysopen.channels.feishu.accounts.defaultis created.Actual
groupPolicytoallowlist, createdaccounts.default.groupPolicy = "open", and dropped group messages withgroupPolicy=allowlistlogs.Evidence
Attach at least one:
Human Verification (required)
What you personally verified (not just CI), and how:
srcanddistloadConfig()preserved top-levelgroupPolicy: "open", restarted the live gateway service, and confirmed Feishu messages started arriving again.defaultaccount, shared top-level auth plus shared top-level policy, repeatedregisterFullcalls.groupPolicyoverrides were not retested in a live environment.Review Conversations
Compatibility / Migration
Yes/No): YesYes/No): NoYes/No): NoRisks and Mitigations
accounts.default.