Skip to content

fix: Don't stop analytics after integration run inside self-driving#771

Merged
sortafreel merged 1 commit into
mainfrom
self-driving/wizard-self-driving-handoff-follow-up
Jun 30, 2026
Merged

fix: Don't stop analytics after integration run inside self-driving#771
sortafreel merged 1 commit into
mainfrom
self-driving/wizard-self-driving-handoff-follow-up

Conversation

@sortafreel

Copy link
Copy Markdown
Contributor

Problem

  • When integration runs, it shuts off analytics before jumping to self-driving

Changes

  • Now it doesn't

Test plan

Copilot AI review requested due to automatic review settings June 30, 2026 13:33
@github-actions

Copy link
Copy Markdown

🧙 Wizard CI

Run 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:

  • /wizard-ci all

Test all apps in a directory:

  • /wizard-ci basic-integration
  • /wizard-ci error-tracking-upload-source-maps
  • /wizard-ci mcp-analytics
  • /wizard-ci misc
  • /wizard-ci revenue

Test an individual app:

  • /wizard-ci basic-integration/android
  • /wizard-ci basic-integration/angular
  • /wizard-ci basic-integration/astro
Show more apps
  • /wizard-ci basic-integration/django
  • /wizard-ci basic-integration/fastapi
  • /wizard-ci basic-integration/flask
  • /wizard-ci basic-integration/javascript-node
  • /wizard-ci basic-integration/javascript-web
  • /wizard-ci basic-integration/laravel
  • /wizard-ci basic-integration/next-js
  • /wizard-ci basic-integration/nuxt
  • /wizard-ci basic-integration/python
  • /wizard-ci basic-integration/rails
  • /wizard-ci basic-integration/react-native
  • /wizard-ci basic-integration/react-router
  • /wizard-ci basic-integration/sveltekit
  • /wizard-ci basic-integration/swift
  • /wizard-ci basic-integration/tanstack-router
  • /wizard-ci basic-integration/tanstack-start
  • /wizard-ci basic-integration/vue
  • /wizard-ci error-tracking-upload-source-maps/android
  • /wizard-ci error-tracking-upload-source-maps/cicd-docker-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-github-actions-docker-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-github-actions-nested-docker-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-github-actions-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-github-actions-single-stage-docker-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-gitlab-node-raw
  • /wizard-ci error-tracking-upload-source-maps/cicd-monorepo-pnpm-node-react
  • /wizard-ci error-tracking-upload-source-maps/cicd-monorepo-raw-node-react
  • /wizard-ci error-tracking-upload-source-maps/cicd-ssh-vps-node-raw
  • /wizard-ci error-tracking-upload-source-maps/flutter
  • /wizard-ci error-tracking-upload-source-maps/ios
  • /wizard-ci error-tracking-upload-source-maps/next
  • /wizard-ci error-tracking-upload-source-maps/next-no-posthog
  • /wizard-ci error-tracking-upload-source-maps/node-raw
  • /wizard-ci error-tracking-upload-source-maps/node-rollup
  • /wizard-ci error-tracking-upload-source-maps/node-rollup-typescript-plugin
  • /wizard-ci error-tracking-upload-source-maps/node-webpack
  • /wizard-ci error-tracking-upload-source-maps/nuxt-3-6
  • /wizard-ci error-tracking-upload-source-maps/nuxt-4-3
  • /wizard-ci error-tracking-upload-source-maps/react-native
  • /wizard-ci error-tracking-upload-source-maps/react-vite
  • /wizard-ci error-tracking-upload-source-maps/rust
  • /wizard-ci mcp-analytics/custom-dispatcher
  • /wizard-ci mcp-analytics/typescript-sdk
  • /wizard-ci misc/quack-quack
  • /wizard-ci revenue/stripe

Results will be posted here when complete.

@sortafreel sortafreel merged commit a7fe755 into main Jun 30, 2026
21 checks passed
@sortafreel sortafreel deleted the self-driving/wizard-self-driving-handoff-follow-up branch June 30, 2026 13:36

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adjusts the agent runner so that when the PostHog integration is executed as a composed sub-run inside the self-driving program, it does not run a terminal outro or shut down the shared analytics client—allowing analytics to continue for the remainder of the host run.

Changes:

  • Runs the integration agent with a new { composed: true } option when invoked as a composed step inside self-driving.
  • Threads the composed option through the unified runner into the linear pipeline.
  • Skips the linear pipeline’s outro + analytics.shutdown('success') when composed is enabled.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
src/lib/programs/posthog-integration/index.ts Marks the composed integration run step to invoke the agent runner with { composed: true }.
src/lib/agent/runner/linear.ts Adds a composed flag and returns before outro + analytics shutdown for composed sub-runs.
src/lib/agent/runner/index.ts Threads composed options into the runner so the linear pipeline can skip outro + analytics shutdown.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 87 to 92
if (isOrchestratorEnabled(boot.wizardFlags)) {
getUI().log.info('Task-queue orchestrator enabled.');
stampVariant(boot, WizardVariant.ORCHESTRATOR);
// composed-run guard is linear-only; the orchestrator is experimental.
return await runOrchestrator(session, programConfig, boot);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants