Add Mixpanel detection to telemetry tree-shaking validation - #8826
Conversation
🎨 Storybook Build Status✅ Build completed successfully! ⏰ Completed at: 02/20/2026, 09:58:04 AM UTC 🔗 Links🎉 Your Storybook is ready for review! |
|
Playwright: ✅ 527 passed, 0 failed · 3 flaky 📊 Browser Reports
|
|
No actionable comments were generated in the recent review. 🎉 📝 WalkthroughWalkthroughThis pull request updates a GitHub Actions CI workflow to enhance telemetry scanning. It adds environment configuration, splits the telemetry detection into separate steps for GTM and Mixpanel, and expands error messaging with remediation guidance for each telemetry provider. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
All alerts resolved. Learn more about Socket for GitHub. This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored. |
📦 Bundle: 4.32 MB gzip ⚪ 0 BDetailsSummary
Category Glance App Entry Points — 21.4 kB (baseline 21.4 kB) • ⚪ 0 BMain entry bundles and manifests
Graph Workspace — 936 kB (baseline 936 kB) • ⚪ 0 BGraph editor runtime, canvas, workflow orchestration
Views & Navigation — 68.6 kB (baseline 68.6 kB) • ⚪ 0 BTop-level views, pages, and routed surfaces
Panels & Settings — 430 kB (baseline 430 kB) • ⚪ 0 BConfiguration panels, inspectors, and settings screens
User & Accounts — 16 kB (baseline 16 kB) • ⚪ 0 BAuthentication, profile, and account management bundles
Editors & Dialogs — 706 B (baseline 706 B) • ⚪ 0 BModals, dialogs, drawers, and in-app editors
UI Components — 42.3 kB (baseline 42.3 kB) • ⚪ 0 BReusable component library chunks
Data & Services — 2.47 MB (baseline 2.47 MB) • ⚪ 0 BStores, services, APIs, and repositories
Utilities & Hooks — 57.6 kB (baseline 57.6 kB) • ⚪ 0 BHelpers, composables, and utility bundles
Vendor & Third-Party — 8.86 MB (baseline 8.86 MB) • ⚪ 0 BExternal libraries and shared vendor chunks
Other — 7.38 MB (baseline 7.38 MB) • ⚪ 0 BBundles that do not match a named category
|
There was a problem hiding this comment.
Pull request overview
This PR enhances the existing CI telemetry scan workflow to detect Mixpanel code in distribution files, ensuring it's properly tree-shaken from OSS builds. This complements the existing Google Tag Manager (GTM) detection that was added in PR #8354 and is part of the comprehensive OSS compliance effort outlined in PR #6777.
Changes:
- Added Mixpanel detection patterns to CI workflow with six specific search patterns
- Added
DISTRIBUTION=localhostenvironment variable to build step to ensure OSS build configuration - Separated GTM and Mixpanel scans into distinct workflow steps for clarity
|
Response to review comment about source map exclusion: Thank you for the suggestion! I've addressed the consistency issue in a different way to maintain the existing pattern. Instead of adding This keeps both scans using the same file filtering approach and avoids modifying the existing GTM scan that has been working correctly. Fixed in: 9fb5fdb |
- Extends existing ci-dist-telemetry-scan workflow - Adds Mixpanel patterns to prevent shipping to OSS builds - Separates GTM and Mixpanel checks for clarity - Adds DISTRIBUTION=localhost env var to build step Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Remove -g '!*.map' from Mixpanel scan to match GTM scan pattern. Both scans should use the same file filtering approach. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
9fb5fdb to
cbdb8e9
Compare
## Summary Enhances the existing CI telemetry scan workflow to also detect Mixpanel code in dist files, ensuring it's properly tree-shaken from OSS builds. ## Context - Extends existing `ci-dist-telemetry-scan.yaml` (added in PR #8354) - Based on analysis in closed PR #6777 (split into focused PRs) - Complements GTM detection already in place - Part of comprehensive OSS compliance effort ## Implementation - Adds separate Mixpanel check step with specific patterns: - `mixpanel.init` - `mixpanel.identify` - `MixpanelTelemetryProvider` - `mp.comfy.org` - `mixpanel-browser` - `mixpanel.track(` - Separates GTM and Mixpanel checks for clarity - Adds `DISTRIBUTION=localhost` env var to build step - Excludes source maps from scanning ## Related - Supersedes part of closed PR #6777 - Complements existing GTM check from PR #8354 - Related to PR #8623 (GTM-focused, may be redundant) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-8826-Add-Mixpanel-detection-to-telemetry-tree-shaking-validation-3056d73d36508153bab5f55d4bb17658) by [Unito](https://www.unito.io) --------- Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
## Summary Adds CI workflow to validate OSS build compliance by checking for proprietary fonts and non-approved dependency licenses. ## Context - Part of comprehensive OSS compliance effort (split from closed PR #6777) - Uses simple bash/grep approach following proven #8623 pattern - Complements telemetry checking in PR #8826 and existing #8354 ## Implementation ### Font Validation - Scans dist/ for proprietary ABCROM fonts (.woff, .woff2, .ttf, .otf) - Fails if any ABCROM fonts found in OSS builds - Provides clear fix instructions ### License Validation - Uses `license-checker` npm package - Validates all production dependencies - Only allows OSI-approved licenses: - MIT, Apache-2.0, BSD-2-Clause, BSD-3-Clause, ISC - 0BSD, BlueOak-1.0.0, Python-2.0, CC0-1.0 - Unlicense, CC-BY-4.0, CC-BY-3.0 - Common dual-license combinations ### Workflow Details - Two separate jobs for parallel execution - Runs on PRs and pushes to main/dev - Builds with `DISTRIBUTION=localhost` for OSS mode - Clear error messages with remediation steps ## Testing - [ ] Font check passes on current main (no ABCROM fonts in dist) - [ ] License check passes on current main (all approved licenses) - [ ] Intentional violation testing ## Related - Supersedes remaining parts of closed PR #6777 - Complements PR #8826 (Mixpanel telemetry) - Follows pattern from PR #8623 (simple bash/grep) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-8828-Add-CI-validation-for-OSS-assets-fonts-and-licenses-3056d73d3650812390d5d91ca2f319fc) by [Unito](https://www.unito.io) --------- Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com> Co-authored-by: bymyself <cbyrne@comfy.org>
…g#8826) ## Summary Enhances the existing CI telemetry scan workflow to also detect Mixpanel code in dist files, ensuring it's properly tree-shaken from OSS builds. ## Context - Extends existing `ci-dist-telemetry-scan.yaml` (added in PR Comfy-Org#8354) - Based on analysis in closed PR Comfy-Org#6777 (split into focused PRs) - Complements GTM detection already in place - Part of comprehensive OSS compliance effort ## Implementation - Adds separate Mixpanel check step with specific patterns: - `mixpanel.init` - `mixpanel.identify` - `MixpanelTelemetryProvider` - `mp.comfy.org` - `mixpanel-browser` - `mixpanel.track(` - Separates GTM and Mixpanel checks for clarity - Adds `DISTRIBUTION=localhost` env var to build step - Excludes source maps from scanning ## Related - Supersedes part of closed PR Comfy-Org#6777 - Complements existing GTM check from PR Comfy-Org#8354 - Related to PR Comfy-Org#8623 (GTM-focused, may be redundant) Co-authored-by: Hanzo Dev <dev@hanzo.ai> ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-8826-Add-Mixpanel-detection-to-telemetry-tree-shaking-validation-3056d73d36508153bab5f55d4bb17658) by [Unito](https://www.unito.io) --------- Co-authored-by: Hanzo Dev <dev@hanzo.ai>
## Summary Adds CI workflow to validate OSS build compliance by checking for proprietary fonts and non-approved dependency licenses. ## Context - Part of comprehensive OSS compliance effort (split from closed PR Comfy-Org#6777) - Uses simple bash/grep approach following proven Comfy-Org#8623 pattern - Complements telemetry checking in PR Comfy-Org#8826 and existing Comfy-Org#8354 ## Implementation ### Font Validation - Scans dist/ for proprietary ABCROM fonts (.woff, .woff2, .ttf, .otf) - Fails if any ABCROM fonts found in OSS builds - Provides clear fix instructions ### License Validation - Uses `license-checker` npm package - Validates all production dependencies - Only allows OSI-approved licenses: - MIT, Apache-2.0, BSD-2-Clause, BSD-3-Clause, ISC - 0BSD, BlueOak-1.0.0, Python-2.0, CC0-1.0 - Unlicense, CC-BY-4.0, CC-BY-3.0 - Common dual-license combinations ### Workflow Details - Two separate jobs for parallel execution - Runs on PRs and pushes to main/dev - Builds with `DISTRIBUTION=localhost` for OSS mode - Clear error messages with remediation steps ## Testing - [ ] Font check passes on current main (no ABCROM fonts in dist) - [ ] License check passes on current main (all approved licenses) - [ ] Intentional violation testing ## Related - Supersedes remaining parts of closed PR Comfy-Org#6777 - Complements PR Comfy-Org#8826 (Mixpanel telemetry) - Follows pattern from PR Comfy-Org#8623 (simple bash/grep) Co-authored-by: Hanzo Dev <dev@hanzo.ai> ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-8828-Add-CI-validation-for-OSS-assets-fonts-and-licenses-3056d73d3650812390d5d91ca2f319fc) by [Unito](https://www.unito.io) --------- Co-authored-by: Hanzo Dev <dev@hanzo.ai> Co-authored-by: bymyself <cbyrne@comfy.org>
## Summary Enhances the existing CI telemetry scan workflow to also detect Mixpanel code in dist files, ensuring it's properly tree-shaken from OSS builds. ## Context - Extends existing `ci-dist-telemetry-scan.yaml` (added in PR #8354) - Based on analysis in closed PR #6777 (split into focused PRs) - Complements GTM detection already in place - Part of comprehensive OSS compliance effort ## Implementation - Adds separate Mixpanel check step with specific patterns: - `mixpanel.init` - `mixpanel.identify` - `MixpanelTelemetryProvider` - `mp.comfy.org` - `mixpanel-browser` - `mixpanel.track(` - Separates GTM and Mixpanel checks for clarity - Adds `DISTRIBUTION=localhost` env var to build step - Excludes source maps from scanning ## Related - Supersedes part of closed PR #6777 - Complements existing GTM check from PR #8354 - Related to PR #8623 (GTM-focused, may be redundant) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-8826-Add-Mixpanel-detection-to-telemetry-tree-shaking-validation-3056d73d36508153bab5f55d4bb17658) by [Unito](https://www.unito.io) --------- Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
## Summary Adds CI workflow to validate OSS build compliance by checking for proprietary fonts and non-approved dependency licenses. ## Context - Part of comprehensive OSS compliance effort (split from closed PR #6777) - Uses simple bash/grep approach following proven #8623 pattern - Complements telemetry checking in PR #8826 and existing #8354 ## Implementation ### Font Validation - Scans dist/ for proprietary ABCROM fonts (.woff, .woff2, .ttf, .otf) - Fails if any ABCROM fonts found in OSS builds - Provides clear fix instructions ### License Validation - Uses `license-checker` npm package - Validates all production dependencies - Only allows OSI-approved licenses: - MIT, Apache-2.0, BSD-2-Clause, BSD-3-Clause, ISC - 0BSD, BlueOak-1.0.0, Python-2.0, CC0-1.0 - Unlicense, CC-BY-4.0, CC-BY-3.0 - Common dual-license combinations ### Workflow Details - Two separate jobs for parallel execution - Runs on PRs and pushes to main/dev - Builds with `DISTRIBUTION=localhost` for OSS mode - Clear error messages with remediation steps ## Testing - [ ] Font check passes on current main (no ABCROM fonts in dist) - [ ] License check passes on current main (all approved licenses) - [ ] Intentional violation testing ## Related - Supersedes remaining parts of closed PR #6777 - Complements PR #8826 (Mixpanel telemetry) - Follows pattern from PR #8623 (simple bash/grep) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-8828-Add-CI-validation-for-OSS-assets-fonts-and-licenses-3056d73d3650812390d5d91ca2f319fc) by [Unito](https://www.unito.io) --------- Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com> Co-authored-by: bymyself <cbyrne@comfy.org>
Summary
Enhances the existing CI telemetry scan workflow to also detect Mixpanel code in dist files, ensuring it's properly tree-shaken from OSS builds.
Context
ci-dist-telemetry-scan.yaml(added in PR fix: route gtm through telemetry entrypoint #8354)Implementation
mixpanel.initmixpanel.identifyMixpanelTelemetryProvidermp.comfy.orgmixpanel-browsermixpanel.track(DISTRIBUTION=localhostenv var to build stepRelated
Co-Authored-By: Claude Sonnet 4.5 noreply@anthropic.com
┆Issue is synchronized with this Notion page by Unito