Repository navigation
Conversation
|
🚨 SLOP COP 🚨 · I am the SlopCop. I am reviewing this pull request for security, code quality, performance, duplication, architecture, and end-to-end behavior. |
SawyerHood
left a comment
There was a problem hiding this comment.
🚨 SLOP COP 🚨 · review
ELI5: Plugins can now show a small live label beside a sidebar item. Tasks uses this label to show the open-task count.
I found three concrete issues:
-
Medium: A crashed accessory stays crashed after a plugin reload. The mount needs a React key that includes
panel.generation. -
Medium: Each Tasks change signal starts another broad summary request. Add a count-only RPC and coalesce signals during an active request.
-
Low:
crashFallback={null}selects the default crash chip. Use a non-null empty fallback so a crash hides the accessory.
The authoring skill also says a headerContent crash hides the accessory. Change that phrase to “header content.”
I found no new data exposure, authorization error, or unsafe navigation path. The repeated host and test-harness validation follows the current SDK contract design.
Validation passed on the exact head SHA. GitHub CI passed all required checks. Local Turbo type checks and package tests passed.
The browser test passed on wide and compact viewports. It also passed route navigation and a live count update from 9 to 10. I stopped the dev app after the test.
Please fix the three inline findings before merge.
abd4791 to
07a1964
Compare
1b88128 to
e28b90f
Compare
Summary
experimental_sidebarAccessoryto plugin nav panel registrations, the app/testing registration collectors, bundled SDK types, and authoring docsDesign
A no-props component keeps the surface small while letting live accessories own their RPC query and realtime subscription. Updates stay within the accessory subtree instead of lifting state through the sidebar. The accessory is presentational and sits outside the navigation button, preserving the stable accessible name. It shares the trailing action column with the host options button through the existing inverse hover-action CSS, so hover/focus does not remount or reset its live state. The host applies its 12px secondary chrome type scale so accessory values remain subordinate to 13px row labels. Plugin-generation keys reset a latched error boundary after reload, while a non-null empty crash fallback keeps failure local and silent. Tasks single-flights its count-only RPC and reduces any invalidation burst during a request to one trailing refresh. The audit checklist records the component-versus-value, portal, budget, compact lifecycle, and accessibility questions to revisit before stabilization.
No host-daemon protocol bump is needed because this changes the frontend plugin contract and plugin-local RPC response only, not the server/daemon wire contract.
Testing
pnpm exec turbo run test --filter=@bb/app --force(336 files, 2549 tests)pnpm exec turbo run test --filter=bb-plugin-tasks --force(35 files, 329 tests)pnpm exec turbo run test --filter=@bb/plugin-sdk --force(9 files, 75 tests)pnpm exec turbo run test --filter=@bb/server --force -- test/services/plugins/plugin-authoring-docs.test.tspnpm exec turbo run test --filter=@bb/templates --force(4 files, 23 tests)pnpm exec turbo run typecheck --filter=@bb/plugin-sdk --filter=@bb/app --filter=bb-plugin-tasks --filter=@bb/server --filter=@bb/templates --forcegit diff --checkFixes #1202