Skip to content

fix(analytics): exclude private Burn content from PostHog - #30

Draft
aviyashchin wants to merge 1 commit into
mainfrom
codex/21-observability-privacy
Draft

aviyashchin wants to merge 1 commit into
mainfrom
codex/21-observability-privacy

Conversation

@aviyashchin

Copy link
Copy Markdown

Outcome

Before enabling company analytics, keep private chat content out of the existing PostHog SDK. Disable autocapture, replay and automatic page-leave capture. Strip URL query strings/fragments from pageview and initial/referrer properties. Extension chat emits only a context-present boolean, not raw source text.

Tracks #21 (safe UX/MCP monitoring). Reuses the native analytics initialization and event registry. No new SDK, dashboard, UI flow or monitoring framework.

Validation

Focused Jest regression failed before the fix: automatic capture was enabled by default and planted private customer text appeared in the emitted event. After the fix:

Test Suites: 1 passed, 1 total
Tests:       2 passed, 2 total

Command: bun run test --runInBand --no-watchman --no-coverage --runTestsByPath src/app/providers.test.tsx.
Focused oxlint exited 0 (two existing warnings on the unchanged generic assertion), oxfmt and git diff --check passed.

Full bun run types:check fails on the base as well as this candidate:

Unchanged base typecheck exit: 1
Baseline errors: 587 Candidate errors: 587 Identical: True

Do not treat focused tests as a full build pass. Keep this draft pending CI and deployment/provider read-back. No company PostHog configuration was enabled by this PR.

@vercel

vercel Bot commented Sep 18, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
onyx-executive Ready Ready Preview Sep 18, 2026 11:20pm UTC

@aviyashchin

Copy link
Copy Markdown
Author

CI status at candidate e259f9a: 30 passed, 0 failed, 22 skipped, 3 queued image-build jobs. The web image job requests the existing RunsOn labels runs-on, runner=4cpu-linux-arm64, and extras=ecr-cache; GitHub reports no assigned runner. This is a queued execution prerequisite, not a failing test. No workflow/gate changes were made to bypass it.

The two planted-content regressions, quality checks, Jest, Storybook, CodeQL, and Vercel pass. Live company-provider activation and read-back remain outstanding. Full type-check errors match the unchanged base exactly (587); no unrelated UI changes were introduced.

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.

1 participant