-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
fix: trackevent enabled is undefined #12180
Conversation
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
Bitrise❌❌❌ Commit hash: c34c507 Note
Tip
|
Converted to draft as I have issues fixing app/components/Views/Settings/SecuritySettings/Sections/MetaMetricsAndDataCollectionSection/MetaMetricsAndDataCollectionSection.test.tsx |
We decided to go with not fixing but removing the initial cause (that is the backward compatible multi signature trackEvent), and go with a cleanup and update all calls to use new method with event builder. |
Get rid of multiple signatures and backward compat Update unit tests
dc62720
to
e1d4ff5
Compare
remove useless files
remove useless files
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #12180 +/- ##
==========================================
+ Coverage 56.31% 56.35% +0.03%
==========================================
Files 1786 1789 +3
Lines 40375 40495 +120
Branches 5060 5071 +11
==========================================
+ Hits 22738 22819 +81
- Misses 16088 16129 +41
+ Partials 1549 1547 -2 ☔ View full report in Codecov by Sentry. |
@NicolasMassart would it be possible to update the recently added I don't mind adding a fix as part of this PR too if you'd rather I do it! Just let me know. |
I do not see any reason why this would not work. Your wrapper was already using the new way to call trackEvent. |
8545120
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Quality Gate failedFailed conditions |
Description
Important
The issue is due to the fact that
MetaMetrics.trackEvent
method has multiple signatures to handle the backward compatibility with old ways to call it.After discussion (see the change history of this description), we decided to remove backward compatibility and the multiple signature system. We are going to simplify and then fix all the
trackEvent
calls.Asside from the changes in
MetaMetrics
anduseMetrics
hook (and tests) all the changes should be on the calls oftrackEvent
.Current changes in this PR
MetaMetrics.trackEvent
MetaMetrics
unit testsuseMetrics
hookuseMetrics
hook unit teststrackEvent
callstrackEvent
callsRelated issues
Fixes #12117
Manual testing steps
Screenshots/Recordings
events-1.mov
events-2.mov
Before
N/A
After
N/A
Pre-merge author checklist
Pre-merge reviewer checklist