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

[FEATURE] Create detectSnapLocation method to install a Local Snap #5923

Merged
merged 4 commits into from
Mar 17, 2023

Conversation

owencraston
Copy link
Contributor

@owencraston owencraston commented Mar 8, 2023

Development & PR Process

  1. Follow MetaMask Mobile Coding Standards
  2. Add release-xx label to identify the PR slated for a upcoming release (will be used in release discussion)
  3. Add needs-dev-review label when work is completed
  4. Add needs-qa label when dev review is completed
  5. Add QA Passed label when QA has signed off

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?

  • in order to install a snap from NPM we need to update to controllers version v.0.26.2 (minimum)
  • then we need to create a custom fetch function and a custom detectSnapLocation
    2. What is the improvement/solution?
  • updates the snaps-controllers package
    • also update the snaps util package
  • creates the custom fetch function
  • creates the detectSnapLocation and passes the fetch function to it
  • we can install a local snap
  • I also migrated from rn-fetch-blob to react-native-blob-util which is much more actively maintained

Screenshots/Recordings

Screen.Recording.2023-03-07.at.4.12.02.PM.mov

Issue

Progresses https://github.com/MetaMask/mobile-planning/issues/504

  • this is just 1/3 parts of the above issue.

Checklist

  • There is a related GitHub issue
  • Tests are included if applicable
  • Any added code is fully documented

@owencraston owencraston requested a review from a team as a code owner March 8, 2023 00:00
@github-actions
Copy link
Contributor

github-actions bot commented Mar 8, 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.

@owencraston owencraston added the No QA Needed Apply this label when your PR does not need any QA effort. label Mar 8, 2023
Copy link
Member

@gantunesr gantunesr left a comment

Choose a reason for hiding this comment

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

Pending task to do on follow up PR,

  • Add testing to,
    • app/core/Snaps/location/fetch.ts
    • app/core/Snaps/location/http.ts
    • app/core/Snaps/location/local.ts
    • app/core/Snaps/location/location.ts
  • Remove app/util/snaps/fetchNPMPackage.ts if its not necessary anymore

LGTM. Solve conflicts and merge

@owencraston owencraston force-pushed the detectSnapLocation-local branch from 6536f3e to 61387b0 Compare March 17, 2023 19:00
@owencraston owencraston force-pushed the detectSnapLocation-local branch from 3278bf3 to 7647226 Compare March 17, 2023 20:44
@owencraston
Copy link
Contributor Author

@owencraston owencraston merged commit 639b9bd into feat/snaps-system-integration Mar 17, 2023
@owencraston owencraston deleted the detectSnapLocation-local branch March 17, 2023 21:00
@github-actions github-actions bot locked and limited conversation to collaborators Mar 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
mobile-snaps No QA Needed Apply this label when your PR does not need any QA effort.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants