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

chore: cherry-pick #11935 #11982

Merged
merged 3 commits into from
Oct 24, 2024
Merged

Conversation

github-actions[bot]
Copy link
Contributor

This PR cherry-picks #11935

<!--
Please submit this PR as a draft initially.
Do not mark it as "Ready for review" until the template has been
completely filled out, and PR status checks have passed at least once.
-->

## **Description**

<!--
Write a short description of the changes included in this pull request,
also include relevant motivation and context. Have in mind the following
questions:
1. What is the reason for the change?
2. What is the improvement/solution?
-->
<img width="1052" alt="Screenshot 2024-10-11 at 20 29 04"
src="https://github.com/user-attachments/assets/a5680804-7bc8-45c4-a27a-d790bd5f9a5d">
<img width="766" alt="Screenshot 2024-10-16 at 00 01 02"
src="https://github.com/user-attachments/assets/aa4689f2-9ce0-4dc7-9b99-f24fd4db1b78">
<img width="699" alt="Screenshot 2024-10-15 at 17 57 12"
src="https://github.com/user-attachments/assets/dc31684a-4dea-4f26-8b18-c5497679a0ce">

This task is for adding custom spans to track activities that happen
between app start and wallet UI load. The screenshot below is an example
of a trace for Wallet UI load that takes about a minute to load. During
that time, we can see a large gap between app start spans and the
initial http requests.

The goal here is to isolate these areas and track them with custom
spans. Once implemented, we can expect to see the custom spans appearing
within the gap, which would inform us of the areas to optimize

Issue: MetaMask/mobile-planning#1940

Technical Details
* Added custom span for when the Login screen is mounted to when the
login button is tapped
* Added span for when the login button is tapped to when the wallet view
is mounted
* Added custom span for Engine initialization process
* Added custom span for Store creation
* Added custom span Storage rehydration
* Added custom span fro Create New Wallet to Choose Password
* Added custom span for Biometrics authentication

##**Engine Initialisation Bug**##

While initally the engine init trace was preceded by an await, which
would allow the grouping of all the calls that happen inside Engine to
be under the Engine Initialisation process, that would cause a crash of
the application in Production on Android.

As a temporary fix until the issue that happens within Engine is found
and fixed, the only noticeable difference will take place as bellow. API
calls from within the Engine Initialization, will not all be grouped
within the same span.
<img width="1560" alt="Screenshot 2024-10-22 at 05 02 54"
src="https://github.com/user-attachments/assets/4abc259f-be70-4f74-af2b-7ece47343678">

(left without await, right  with await)

**Bitrise Build:**
https://app.bitrise.io/build/6ee0b625-d8b9-4d95-9fcc-a1d624202736?tab=artifacts

## **Related issues**

Fixes:

## **Manual testing steps**

1. Go to this page...
2.
3.

## **Screenshots/Recordings**

<!-- If applicable, add screenshots and/or recordings to visualize the
before and after of your change. -->

### **Before**

<!-- [screenshots/recordings] -->

### **After**

<!-- [screenshots/recordings] -->

## **Pre-merge author checklist**

- [ ] I’ve followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Mobile
Coding
Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md).
- [ ] I've completed the PR template to the best of my ability
- [ ] I’ve included tests if applicable
- [ ] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [ ] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.

---------

Co-authored-by: tommasini <tommasini15@gmail.com>
Co-authored-by: tommasini <46944231+tommasini@users.noreply.github.com>
@NicolasMassart NicolasMassart added the Run Smoke E2E Triggers smoke e2e on Bitrise label Oct 23, 2024
@NicolasMassart NicolasMassart marked this pull request as ready for review October 23, 2024 17:39
@NicolasMassart NicolasMassart requested review from a team as code owners October 23, 2024 17:39
@NicolasMassart NicolasMassart added team-mobile-platform needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) labels Oct 23, 2024
Copy link
Contributor Author

github-actions bot commented Oct 23, 2024

https://bitrise.io/ Bitrise

✅✅✅ pr_smoke_e2e_pipeline passed on Bitrise! ✅✅✅

Commit hash: bd64d87
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/52a2dfd5-c52b-430c-ba2e-2d81a6d49858

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

Copy link
Contributor

@MarioAslau MarioAslau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@NicolasMassart NicolasMassart marked this pull request as draft October 23, 2024 18:28
@NicolasMassart NicolasMassart marked this pull request as ready for review October 23, 2024 18:28
Copy link
Contributor Author

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.

Copy link

sonarcloud bot commented Oct 24, 2024

@NicolasMassart NicolasMassart merged commit 30b548c into release/7.33.0 Oct 24, 2024
33 of 34 checks passed
@NicolasMassart NicolasMassart deleted the chore/cherry-pick-11935 branch October 24, 2024 16:29
@github-actions github-actions bot locked and limited conversation to collaborators Oct 24, 2024
@github-actions github-actions bot removed the needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) label Oct 24, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants