feat(self-driving): integrate first when the project has no PostHog#760
Merged
Conversation
🧙 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. |
Collaborator
Author
This stack of pull requests is managed by Graphite. Learn more about stacking. |
d881b04 to
c13117a
Compare
a259d79 to
0d5a549
Compare
adb713c to
48dccdb
Compare
48dccdb to
3967468
Compare
5 tasks
When the project has no PostHog, self-driving sets it up first, then runs Self-driving — composed as steps in one program: - After auth, the detect screen scans the repo and the user picks which project to set PostHog up in (a monorepo can have several). - posthog-integration exports a self-contained run step; self-driving imports it and runs it in the picked project's dir, then a handoff screen, then its own run step. - The runner walks the step list and runs each run step's own agent. One login: the bootstrap calls an idempotent authenticate() the second run reuses. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
3967468 to
e8f3054
Compare
sortafreel
approved these changes
Jun 30, 2026
sortafreel
left a comment
Contributor
There was a problem hiding this comment.
Great job, kudos! Added a couple of concerns, approving on a trust-me-bro basis :)
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.

Problem
Self-driving assumed the project already had a PostHog SDK. A project without one had nowhere to start — no events, no signals, nothing to drive.
Changes
When PostHog isn't found, the wizard sets it up first, then hands off to Self-driving:
intro → "No PostHog found" → auth → detect-and-pick → integration → handoff → Self-drivingrunInProgramPhases), used by both the runner and the snapshot harness.Test plan
pnpm test— offline flow-trace, router, step, and screen tests.Screens