MetaMask / MetaMask/metamask-mobile
(ext) Improve hardware wallet transaction metric reliability
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 3k
- Forks
- 1.7k
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 669
Description
**What is this about?**
Currently, a majority of the [Mobile MM Swap Txns](https://mixpanel.com/project/1979229/view/132079/app/boards#id=10037453&timeFilter=%7E%28dateRange%7E%28type%7E%27in*20the*20last%7Ewindow%7E%28unit%7E%27day%7Evalue%7E30%29%29%7EdisplayText%7E%27Last*2030*20days%29&edited-bookmark=AZeLJyfXa89N) by Account Type are not set. This figure seems to get worse for more recent date ranges (the percentage of account_type = not set increases). This indicates that there was a regression in the metrics calculation but we cannot be certain of this.
What's even weirder is that this metrics does not match up with [Mobile Txns by Account Type](https://mixpanel.com/project/1979229/view/132079/app/boards#id=10037453&timeFilter=%7E%28dateRange%7E%28type%7E%27in*20the*20last%7Ewindow%7E%28unit%7E%27day%7Evalue%7E7%29%29%7EdisplayText%7E%27Last*207*20days%29&edited-bookmark=snfPccFVj2h7) where `not set` is a minority.
The `account_type` property should always be set for transaction events. We need to investigate why this value is not set as well as the discrepancies with the Swaps Txns and normal Txns.
**Technical Details**
- This value seems to be calculated with [this](https://github.com/MetaMask/metamask-mobile/blob/main/app/util/address/index.ts#L426) util function.
**Acceptance Criteria**
- the `account_type` is always set for transactions metrics.
- The default account_type should be MetaMask.
**Stakeholder review needed before the work gets merged**
- [x] 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)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.