Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

frontend mixpanel calls now hit dashboard #10179

Merged
merged 1 commit into from
Dec 9, 2024

Conversation

Israellund
Copy link
Collaborator

Link to Issue

Closes: #10064

Description of Changes

  • Frontend Mixpanel calls now hit the Mixpanel dashboard

"How We Fixed It"

-Changed code to look for process.env.APP_ENV === 'local' and changed error messages to reflect frontend and backend inits

NOTE: The original error shown in the ticket, "Failed to track event, Cannot read properties of 'undefined'" came from the code looking for process.env.APP_ENV === 'development' within the init function, and since the env var isn't 'development' anymore it was throwing that error. If you review this PR and you're seeing an error of Bad HTTP status: 0 that is most likely because an ad blocker you have is blocking the frontend mixpanel calls. Try disabling any ad blockers and trying again.

Test Plan

  • Click around locally and try to trigger some of the frontend mixpanel calls found in shared/analytics.types.ts
  • confirm that you see the event on the Mixpanel Dev dashboard (If you need access to Mixpanel or if you'd like for me to confirm the events in real time while you're testing just let me know.)

@Israellund Israellund merged commit bb82242 into master Dec 9, 2024
11 checks passed
@Israellund Israellund deleted the israel.10064.mixpanel-initialized-earlier branch December 9, 2024 16:50
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.

Some Mixpanel events throwing error and not showing on dashboard
3 participants