Integrate Krill Switch feature flags - #3285
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Codex review: found issues before merge. Reviewed August 5, 2026, 3:28 PM ET / 19:28 UTC. ClawSweeper reviewWhat this changesThe PR adds Krill Switch SDK evaluation during server rendering and hydration so a typed flag can vary the homepage subtitle without a default-state flash. Merge readiness⛔ Blocked by patch quality or review findings - 11 items remain Keep this member-authored PR open: current main still uses the fixed homepage subtitle, while the unchanged branch retains blockers around pre-publication dependency integrity, root-wide evaluation, and missing inspectable browser proof. Priority: P2 Review scores
Verification
How this fits togetherThe TanStack Start root route renders every ClawHub page and wraps the application’s global providers. This PR obtains an anonymous flag context at that boundary, calls the flag service, then feeds the hydrated value to the homepage hero. flowchart LR
A[Visitor request] --> B[Root route loader]
B --> C[Anonymous context cookie]
C --> D[Flag evaluation service]
D --> E[Hydrated flag provider]
E --> F[Homepage hero subtitle]
Decision needed
Why: The patch introduces a new external SDK, environment contract, root-route network dependency, anonymous targeting cookie, and polling behavior; choosing the permanent scope is a product and platform decision beyond mechanical review. Before merge
Findings
Agent review detailsSecurityNeeds attention: The branch introduces an external server/browser SDK and anonymous targeting identifier, but the lockfile hashes are knowingly not tied to a published artifact. Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Publish and independently inspect the SDK, regenerate its lock entries from the registry artifact, then restrict initial evaluation and the provider to the homepage before attaching real-browser SSR/hydration proof. Do we have a high-confidence way to reproduce the issue? Yes for the route-scope and package-integrity blockers: the source shows root-level evaluation and pre-publication lock hashes, though this read-only review did not run the branch or install the unpublished package. Is this the best way to solve the issue? No; a homepage-only provider and loader are the narrower maintainable path for the sole Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 109384dcb8f0. LabelsLabel justifications:
EvidenceSecurity concerns:
What I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (15 earlier review cycles; latest 8 shown)
|
Patrick-Erichsen
left a comment
There was a problem hiding this comment.
This introduces Krill Switch as a remote feature-flag provider and uses it for homepage hero copy. It is not merge-ready because it adds a new production/SSR dependency before the package contract and operating model are established.
LOC: +325/-13 (13 files)
Findings: rebase the conflicted branch, verify the lock entry against the published SDK tarball, add real-browser enabled/default/fail-open proof, and get an explicit product decision to reintroduce remote flag machinery after the prior flag system was removed.
Best-fix verdict: too broad for one copy experiment. A platform dependency is justified only if ClawHub is committing to a supported flag operating model beyond this single use.
Alternatives considered: a local config/build-time switch is simpler for one experiment; adopting the remote SDK can be reasonable once ownership, failure mode, privacy, and rollout policy are durable.
Code read: root provider/SSR wiring, homepage flag consumer, package/lock changes, tests, and current main’s lack of a flag platform.
Remaining uncertainty: published package identity/integrity, operational sponsorship, and browser behavior.
|
This pull request has been automatically marked as stale due to inactivity. |
Summary
@openclaw/krillswitch-reactSDK with a single typedsoulsproof flag.When
soulsis enabled, the homepage subtitle becomes “Discover skills and plugins built with soul.” When disabled or unavailable, it remains “Discover skills and plugins from top creators.”Dependency prerequisite
Merge Krill Switch #43 and publish
@openclaw/krillswitch-react@0.0.1before merging this PR. The lockfile entries were prepared from the package artifacts at Krill commit51df4d3; regenerate the lockfile if the published artifacts differ.Local proof
soulscopy.Checks
bun run test --run src/lib/featureFlags.test.tsx src/lib/featureFlags.server.test.ts— 4 tests passednpm_config_registry=https://registry.npmjs.org bun run ci:static— passedbun run ci:unit— 5,610 tests passedbun run ci:types-build— passedbun run build— passedAutomated autoreview was attempted twice but its isolated reviewer could not authenticate to the OpenAI Responses endpoint (
401 Unauthorized). A manual review of the complete PR diff and installed SDK contract found no actionable issues.