Skip to content

Migrate and remove MIXPANEL_METAMETRICS_ID in app storage #8833

@NicolasMassart

Description

@NicolasMassart

What is this about?

In app/constants/storage.ts we have MIXPANEL_METAMETRICS_ID that is used for legacy compatibility. Some logic is implemented on app/core/Analytics/MetaMetrics.ts #getMetaMetricsId to test if one exists and copy it if needed. At some point we will be able to remove this value completely.
It will require to make sure we don't want to retrieve the legacy MIXPANEL_METAMETRICS_ID even if it's still there. But I think at some point it will not be used anymore and will be recorded in the METAMETRICS_ID directly. The way we test this value could be changed to first get the METAMETRICS_ID and fallback to MIXPANEL_METAMETRICS_ID and eventually to generating a new one.

Given the time will come where 100% of our users will have METAMETRICS_ID, looking at it first will be a time and process saver.

Current processing (A)

Step Value storage action
1 MIXPANEL_METAMETRICS_ID use if defined, else go to next step
2 METAMETRICS_ID use if defined, else go to next step
3 none generate a new UUID

Refactored processing (B)

Step Value storage action
1 METAMETRICS_ID use if defined, else go to next step
2 none generate a new UUID

Scenario

No response

Design

No response

Technical Details

  • remove MIXPANEL_METAMETRICS_ID from app/constants/storage.ts
  • modify app/core/Analytics/MetaMetrics.ts #getMetaMetricsId to implement refactored processing (B)
  • update unit tests

Threat Modeling Framework

No response

Acceptance Criteria

  • no use of MIXPANEL_METAMETRICS_ID
  • directly use METAMETRICS_ID
  • tests are updated

Stakeholder review needed before the work gets merged

  • Engineering (needed in most cases)
  • Design
  • Product
  • QA (automation tests are required to pass before merging PRs but not all changes are covered by automation tests - please review if QA is needed beyond automation tests)
  • Security
  • Legal
  • Marketing
  • Management (please specify)
  • Other (please specify)

References

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions