Skip to content

[MMI] Fix Connect MMI and Deep link Flows#19881

Merged
albertolive merged 21 commits intodevelopfrom
feature/MMI-3407-investigate-why-our-deeplink-is-not-showing-up
Jul 13, 2023
Merged

[MMI] Fix Connect MMI and Deep link Flows#19881
albertolive merged 21 commits intodevelopfrom
feature/MMI-3407-investigate-why-our-deeplink-is-not-showing-up

Conversation

@albertolive
Copy link
Copy Markdown
Contributor

@albertolive albertolive commented Jul 5, 2023

Explanation

When doing a transaction or signing, the deep link doesn't show up, and no error is emitted in the console.

What we should be seeing:

image

We also ensured the extension is at the home view when the deep link is visible. (Current behavior)

Last, we improved the styles in the "Connect Custody" flow.

Screen.Recording.2023-07-07.at.13.03.10.mov

AC

The deep link appears after doing an operation.

A PR with the necessary changes has been created for the team to review

Ticket

https://consensyssoftware.atlassian.net/browse/MMI-3407

Pre-merge author checklist

  • I've clearly explained:
    • What problem this PR is solving
    • How this problem was solved

Pre-merge reviewer checklist

  • Manual testing (e.g. pull and build branch, run in browser, test code being changed)
  • PR is linked to the appropriate GitHub issue

@albertolive albertolive marked this pull request as ready for review July 5, 2023 14:15
@albertolive albertolive requested a review from a team as a code owner July 5, 2023 14:15
@albertolive albertolive marked this pull request as draft July 5, 2023 14:15
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jul 5, 2023

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.

@albertolive albertolive changed the title Sending showCustodyConfirmLink as a prop and fixing other issues [MMI] Sending showCustodyConfirmLink as a prop and fixing other issues Jul 7, 2023
@albertolive albertolive marked this pull request as ready for review July 7, 2023 12:59
@albertolive
Copy link
Copy Markdown
Contributor Author

@metamaskbot update-policies

@metamaskbot
Copy link
Copy Markdown
Collaborator

Policies updated

@metamaskbot metamaskbot requested review from a team as code owners July 7, 2023 13:12
@albertolive albertolive changed the title [MMI] Sending showCustodyConfirmLink as a prop and fixing other issues [MMI] Fix Connect MMI and Deep link Flows Jul 7, 2023
Copy link
Copy Markdown
Contributor

@brad-decker brad-decker left a comment

Choose a reason for hiding this comment

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

I haven't done a test of functionality yet just code review and just a couple questions about changes in confirm-transaction-base

Comment on lines +595 to +596
await cancelTransaction(txData);
history.push(mostRecentOverviewPage);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

why was this change necessary?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

IMHO, the modified code using await provides a clearer and more concise way of handling this asynchronous operation

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

In general we should try to avoid changes unnecessary to the PR, as there may be unintended consequences that then get traced down to this. This is part of our "Auditability" engineering principle. I'm going to approve and just leave this is a critique to apply to future prs.

@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [12bda86]
Page Load Metrics (1518 ± 40 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint1022531303316
domContentLoaded1396167615188340
load1396167615188340
domInteractive1396167615188340
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 0 bytes
  • ui: 26 bytes
  • common: 189 bytes

NidhiKJha
NidhiKJha previously approved these changes Jul 10, 2023
@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [2fe2167]
Page Load Metrics (1538 ± 33 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint107188131199
domContentLoaded1405165715386833
load1406165715386833
domInteractive1405165715386833
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 0 bytes
  • ui: 26 bytes
  • common: 189 bytes

zone-live
zone-live previously approved these changes Jul 10, 2023
Copy link
Copy Markdown
Contributor

@brad-decker brad-decker left a comment

Choose a reason for hiding this comment

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

There's some interesting logic changes to confirmations (approvals) that I think needs a second set of eyes on it from the confirmations team. See @DDDDDanica 's comment

totalUnapprovedCount,
hasApprovalFlows: getApprovalFlows(state).length > 0,
hasApprovalFlows:
Array.isArray(getApprovalFlows) && getApprovalFlows(state).length > 0,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@jpuri I'd actually like to get your eyes on this or someone from confirmations team (if I should be tagging someone else let me know)

@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [72b1915]
Page Load Metrics (1757 ± 55 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint1172041502512
domContentLoaded15001902175711555
load15001902175711555
domInteractive15001902175711555
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 0 bytes
  • ui: 26 bytes
  • common: 189 bytes

</Box>
);
};

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Possible to test cover changes in this component ?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the feedback. I already did it with snapshots

jpuri
jpuri previously approved these changes Jul 11, 2023
Copy link
Copy Markdown
Contributor

@jpuri jpuri left a comment

Choose a reason for hiding this comment

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

Changes look good, just a small feedback I added to it.

@albertolive albertolive requested a review from brad-decker July 11, 2023 16:34
@brad-decker brad-decker dismissed their stale review July 12, 2023 19:29

Changes addressed

@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [8aa1c72]
Page Load Metrics (1590 ± 40 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint115188133178
domContentLoaded1444185315908440
load1444185315908440
domInteractive1444185315908440

setCurrentJwt(
connectRequestValue.token ||
(await dispatch(mmiActions.getCustodianToken())),
connectRequestValue.token || dispatch(mmiActions.getCustodianToken()),
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

A dispatch should not be required for getter function I think.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Thanks, @jpuri. I'll address, if needed, these changes in a following PR.

@albertolive albertolive merged commit b5ece42 into develop Jul 13, 2023
@albertolive albertolive deleted the feature/MMI-3407-investigate-why-our-deeplink-is-not-showing-up branch July 13, 2023 08:42
@github-actions github-actions Bot locked and limited conversation to collaborators Jul 13, 2023
@metamaskbot metamaskbot added the release-10.35.0 Issue or pull request that will be included in release 10.35.0 label Jul 13, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

release-10.35.0 Issue or pull request that will be included in release 10.35.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants