feat: detect existing Slack connection at the end of a wizard run#649
Merged
Conversation
The Connect-Slack step's poll needs integration:read, which only the MCP tutorial requested — in the default run the first poll 403s and the screen never flips to the connected variant. Adds the scope for the posthog-integration program. Also adds an End-screens playground tab (SlackConnectScreen + OutroScreen variants) and lets the playground tab bar wrap instead of clipping overflow tabs. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
🧙 Wizard CIRun the Wizard CI and test your changes against wizard-workbench example apps by replying with a GitHub comment using one of the following commands: Test all apps:
Test all apps in a directory:
Test an individual app:
Show more apps
Results will be posted here when complete. |
gewenyu99
commented
Jun 12, 2026
gewenyu99
commented
Jun 12, 2026
sarahxsanders
approved these changes
Jun 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The Connect-Slack step at the end of the default wizard run now actually detects an existing Slack connection — same behavior as the MCP tutorial.
SlackConnectScreenalready pollsfetchSlackConnectedevery 3s, but that endpoint requires theintegration:readscope, which only themcp-tutorialprogram requested (#648). In the defaultposthog-integrationrun the first poll 403s, the catch stops polling, and an already-connected project is nagged with the connect nudge forever. This addsintegration:readto the program's scope additions (it's already inside the OAuth app ceiling), which makes the existing screen behavior work: already-connected projects flip to the ✓ connected variant on mount, and "Open Slack setup" flips live once the browser OAuth completes.Also
SlackConnectScreenandOutroScreenagainst the shared store.Vswitches view,Ktoggles the Slack state (writes the same store key the poll writes),Ocycles outro success/error/cancel. The demo swaps the playground's fake credentials for a localhost dead-end while mounted (and restores on unmount) so the poll can't reach a real host — credentials stay non-null because nulling them knocks the router out of therunscreen and resets the tab bar.flexWrap="wrap"on theTabContainertab bar, so the now-14-tab playground stacks onto extra rows instead of clipping.Test
pnpm build && pnpm test && pnpm fix— 857 tests pass.🤖 Generated with Claude Code