Skip to content

Conversation

@MarioAslau
Copy link
Contributor

@MarioAslau MarioAslau commented Jun 10, 2024

Description

We need to add @metamask/eth-json-rpc-middleware v^12 package, and we can remove the used eth-json-rpc-middleware v4 from our package.json

We need also to replace the usage of it on the application (Snaps and BackgroundBridge)
It would also be good to refactor it to use ecmascript (import) instead of commonJS (require) syntax!

Issue: https://github.com/MetaMask/mobile-planning/issues/1805

Related issues

Fixes:

Manual testing steps

  1. Go to this page...

Screenshots/Recordings

Before

After

Recording.12.mp4

Pre-merge author checklist

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.

@MarioAslau MarioAslau requested a review from a team as a code owner June 10, 2024 22:31
@MarioAslau MarioAslau self-assigned this Jun 10, 2024
@github-actions
Copy link
Contributor

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.

@MarioAslau MarioAslau added needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) team-mobile-platform Mobile Platform team labels Jun 10, 2024
@MarioAslau MarioAslau requested a review from tommasini June 10, 2024 22:32
pify "^3.0.0"
safe-event-emitter "^1.0.1"

eth-json-rpc-middleware@^6.0.0:
Copy link
Contributor

@legobeat legobeat Jun 11, 2024

Choose a reason for hiding this comment

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

Note that even after this, eth-json-rpc-middleware@6.0.0 is still used by remaining direct legacy dependencies json-rpc-engine@^6.1.0 and eth-json-rpc-filters@4.2.2.

@MarioAslau
Copy link
Contributor Author

MarioAslau commented Jun 11, 2024

The work on this branch is finished but it will be merged through the PR #9930 that @legobeat made

E2E: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/582806b0-8822-42f7-985f-dae0c8b41b1f

@socket-security
Copy link

socket-security bot commented Jun 20, 2024

@MarioAslau MarioAslau marked this pull request as ready for review June 20, 2024 17:14
@MarioAslau MarioAslau requested a review from a team as a code owner June 20, 2024 17:14
@MarioAslau MarioAslau requested a review from a team June 20, 2024 17:14
@github-actions
Copy link
Contributor

github-actions bot commented Jun 20, 2024

https://bitrise.io/ Bitrise

✅✅✅ pr_smoke_e2e_pipeline passed on Bitrise! ✅✅✅

Commit hash: 1df1a8e
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/e1c74716-9933-42fc-9db8-c2c060a4a174

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

@github-actions
Copy link
Contributor

github-actions bot commented Jun 20, 2024

https://bitrise.io/ Bitrise

✅✅✅ pr_smoke_e2e_pipeline passed on Bitrise! ✅✅✅

Commit hash: a37d6f5
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/7d4a2403-edb0-425a-a862-5924f7d80ed7

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

@sonarqubecloud
Copy link

@github-actions
Copy link
Contributor

This PR has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 7 days. Thank you for your contributions.

@github-actions github-actions bot added the stale Issues that have not had activity in the last 90 days label Sep 20, 2024
@github-actions
Copy link
Contributor

This PR was closed because there has been no follow up activity in 7 days. Thank you for your contributions.

@github-actions github-actions bot closed this Sep 27, 2024
github-merge-queue bot pushed a commit that referenced this pull request Dec 13, 2024
## **Description**

- This PR is a rebase of #10098, including:
    * #9925
    * #9930
- Bump `@metamask/eth-json-rpc-filters` to `^7.0.0`
- Bump `@metamask/json-rpc-engine` to `^10.0.0`
- Bump `@metamask/eth-json-rpc-middleware` to `^15.0.0`
- Migrate from `json-rpc-middleware-stream` to
`@metamask/json-rpc-middleware-stream`
- Upgrade `@metamask/providers` from v13 to v16
  - Also broken out separately as #12085 
- Revert `Internal JSON-RPC error` message change to accomodate for
`@metamask/rpc-errors` v7


## **Related issues**

Expected to fix the following issues:

- [x] #11163
- [x] #11129
- [ ] #11105
- [ ] #9715
- [ ] #8308
- [x] #7926
- [x] #4621
- [x] #4646
- [ ] #12634

#### Blocked by
- [x] #12085
- [x] #12047
  - [x] #12024
    - [x] #11980 
- [x] #12008
- [x] #11978 

## **Manual testing steps**

1. Go to in-app browser
2. Test connect with multiple dapps
3. Perform transaciton on test dapp
1. Go to this page...

## **Screenshots/Recordings**


https://github.com/MetaMask/metamask-mobile/assets/46944231/c608d957-6684-40e2-8963-67a11dc610df

### **Before**

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

### **After**

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

## **Pre-merge author checklist**

- [x] 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).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] 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: Aslau Mario-Daniel <marioaslau@gmail.com>
Co-authored-by: tommasini <tommasini15@gmail.com>
Co-authored-by: kylanhurt <kylan.hurt@gmail.com>
Co-authored-by: sethkfman <Seth.Kaufman@consensys.net>
Co-authored-by: Nicolas MASSART <nicolas.massart@consensys.net>
Co-authored-by: Nico MASSART <NicolasMassart@users.noreply.github.com>
runway-github bot added a commit that referenced this pull request Dec 13, 2024
## **Description**

- This PR is a rebase of #10098, including:
    * #9925
    * #9930
- Bump `@metamask/eth-json-rpc-filters` to `^7.0.0`
- Bump `@metamask/json-rpc-engine` to `^10.0.0`
- Bump `@metamask/eth-json-rpc-middleware` to `^15.0.0`
- Migrate from `json-rpc-middleware-stream` to
`@metamask/json-rpc-middleware-stream`
- Upgrade `@metamask/providers` from v13 to v16
  - Also broken out separately as #12085 
- Revert `Internal JSON-RPC error` message change to accomodate for
`@metamask/rpc-errors` v7


## **Related issues**

Expected to fix the following issues:

- [x] #11163
- [x] #11129
- [ ] #11105
- [ ] #9715
- [ ] #8308
- [x] #7926
- [x] #4621
- [x] #4646
- [ ] #12634

#### Blocked by
- [x] #12085
- [x] #12047
  - [x] #12024
    - [x] #11980 
- [x] #12008
- [x] #11978 

## **Manual testing steps**

1. Go to in-app browser
2. Test connect with multiple dapps
3. Perform transaciton on test dapp
1. Go to this page...

## **Screenshots/Recordings**


https://github.com/MetaMask/metamask-mobile/assets/46944231/c608d957-6684-40e2-8963-67a11dc610df

### **Before**

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

### **After**

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

## **Pre-merge author checklist**

- [x] 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).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] 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: Aslau Mario-Daniel <marioaslau@gmail.com>
Co-authored-by: tommasini <tommasini15@gmail.com>
Co-authored-by: kylanhurt <kylan.hurt@gmail.com>
Co-authored-by: sethkfman <Seth.Kaufman@consensys.net>
Co-authored-by: Nicolas MASSART <nicolas.massart@consensys.net>
Co-authored-by: Nico MASSART <NicolasMassart@users.noreply.github.com>
runway-github bot added a commit that referenced this pull request Dec 13, 2024
## **Description**

- This PR is a rebase of #10098, including:
    * #9925
    * #9930
- Bump `@metamask/eth-json-rpc-filters` to `^7.0.0`
- Bump `@metamask/json-rpc-engine` to `^10.0.0`
- Bump `@metamask/eth-json-rpc-middleware` to `^15.0.0`
- Migrate from `json-rpc-middleware-stream` to
`@metamask/json-rpc-middleware-stream`
- Upgrade `@metamask/providers` from v13 to v16
  - Also broken out separately as #12085
- Revert `Internal JSON-RPC error` message change to accomodate for
`@metamask/rpc-errors` v7

## **Related issues**

Expected to fix the following issues:

- [x] #11163
- [x] #11129
- [ ] #11105
- [ ] #9715
- [ ] #8308
- [x] #7926
- [x] #4621
- [x] #4646
- [ ] #12634

#### Blocked by
- [x] #12085
- [x] #12047
  - [x] #12024
    - [x] #11980
- [x] #12008
- [x] #11978

## **Manual testing steps**

1. Go to in-app browser
2. Test connect with multiple dapps
3. Perform transaciton on test dapp
1. Go to this page...

## **Screenshots/Recordings**

https://github.com/MetaMask/metamask-mobile/assets/46944231/c608d957-6684-40e2-8963-67a11dc610df

### **Before**

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

### **After**

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

## **Pre-merge author checklist**

- [x] 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).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] 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: Aslau Mario-Daniel <marioaslau@gmail.com>
Co-authored-by: tommasini <tommasini15@gmail.com>
Co-authored-by: kylanhurt <kylan.hurt@gmail.com>
Co-authored-by: sethkfman <Seth.Kaufman@consensys.net>
Co-authored-by: Nicolas MASSART <nicolas.massart@consensys.net>
Co-authored-by: Nico MASSART <NicolasMassart@users.noreply.github.com>
runway-github bot pushed a commit that referenced this pull request Dec 13, 2024
)

## **Description**

- This PR is a rebase of #10098, including:
    * #9925
    * #9930
- Bump `@metamask/eth-json-rpc-filters` to `^7.0.0`
- Bump `@metamask/json-rpc-engine` to `^10.0.0`
- Bump `@metamask/eth-json-rpc-middleware` to `^15.0.0`
- Migrate from `json-rpc-middleware-stream` to
`@metamask/json-rpc-middleware-stream`
- Upgrade `@metamask/providers` from v13 to v16
  - Also broken out separately as #12085 
- Revert `Internal JSON-RPC error` message change to accomodate for
`@metamask/rpc-errors` v7


## **Related issues**

Expected to fix the following issues:

- [x] #11163
- [x] #11129
- [ ] #11105
- [ ] #9715
- [ ] #8308
- [x] #7926
- [x] #4621
- [x] #4646
- [ ] #12634

#### Blocked by
- [x] #12085
- [x] #12047
  - [x] #12024
    - [x] #11980 
- [x] #12008
- [x] #11978 

## **Manual testing steps**

1. Go to in-app browser
2. Test connect with multiple dapps
3. Perform transaciton on test dapp
1. Go to this page...

## **Screenshots/Recordings**


https://github.com/MetaMask/metamask-mobile/assets/46944231/c608d957-6684-40e2-8963-67a11dc610df

### **Before**

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

### **After**

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

## **Pre-merge author checklist**

- [x] 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).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] 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: Aslau Mario-Daniel <marioaslau@gmail.com>
Co-authored-by: tommasini <tommasini15@gmail.com>
Co-authored-by: kylanhurt <kylan.hurt@gmail.com>
Co-authored-by: sethkfman <Seth.Kaufman@consensys.net>
Co-authored-by: Nicolas MASSART <nicolas.massart@consensys.net>
Co-authored-by: Nico MASSART <NicolasMassart@users.noreply.github.com>
sethkfman added a commit that referenced this pull request Dec 13, 2024
)

- fix: replace legacy eth-json-rpc deps (#11952)

## **Description**

- This PR is a rebase of #10098, including:
    * #9925
    * #9930
- Bump `@metamask/eth-json-rpc-filters` to `^7.0.0`
- Bump `@metamask/json-rpc-engine` to `^10.0.0`
- Bump `@metamask/eth-json-rpc-middleware` to `^15.0.0`
- Migrate from `json-rpc-middleware-stream` to
`@metamask/json-rpc-middleware-stream`
- Upgrade `@metamask/providers` from v13 to v16
  - Also broken out separately as #12085 
- Revert `Internal JSON-RPC error` message change to accomodate for
`@metamask/rpc-errors` v7


## **Related issues**

Expected to fix the following issues:

- [x] #11163
- [x] #11129
- [ ] #11105
- [ ] #9715
- [ ] #8308
- [x] #7926
- [x] #4621
- [x] #4646
- [ ] #12634

#### Blocked by
- [x] #12085
- [x] #12047
  - [x] #12024
    - [x] #11980 
- [x] #12008
- [x] #11978 

## **Manual testing steps**

1. Go to in-app browser
2. Test connect with multiple dapps
3. Perform transaciton on test dapp
1. Go to this page...

## **Screenshots/Recordings**



https://github.com/MetaMask/metamask-mobile/assets/46944231/c608d957-6684-40e2-8963-67a11dc610df

### **Before**

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

### **After**

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

## **Pre-merge author checklist**

- [x] 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).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] 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: Aslau Mario-Daniel <marioaslau@gmail.com>
Co-authored-by: tommasini <tommasini15@gmail.com>
Co-authored-by: kylanhurt <kylan.hurt@gmail.com>
Co-authored-by: sethkfman <Seth.Kaufman@consensys.net>
Co-authored-by: Nicolas MASSART <nicolas.massart@consensys.net>
Co-authored-by: Nico MASSART <NicolasMassart@users.noreply.github.com>
[d967a76](d967a76)

Co-authored-by: legobeat <109787230+legobeat@users.noreply.github.com>
Co-authored-by: Aslau Mario-Daniel <marioaslau@gmail.com>
Co-authored-by: tommasini <tommasini15@gmail.com>
Co-authored-by: kylanhurt <kylan.hurt@gmail.com>
Co-authored-by: sethkfman <Seth.Kaufman@consensys.net>
Co-authored-by: Nicolas MASSART <nicolas.massart@consensys.net>
Co-authored-by: Nico MASSART <NicolasMassart@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) stale Issues that have not had activity in the last 90 days team-mobile-platform Mobile Platform team

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants