Skip to content

fix: migrate from deprecated legacy packages#11968

Closed
legobeat wants to merge 21 commits intomainfrom
deps-ethjs
Closed

fix: migrate from deprecated legacy packages#11968
legobeat wants to merge 21 commits intomainfrom
deps-ethjs

Conversation

@legobeat
Copy link
Contributor

@legobeat legobeat commented Oct 23, 2024

Description

Related issues

Blocked by / broken out into

Manual testing steps

Screenshots/Recordings

Before

After

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.

@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.

@socket-security
Copy link

socket-security bot commented Oct 23, 2024

🚨 Potential security issues detected. Learn more about Socket for GitHub ↗︎

To accept the risk, merge this PR and you will not be notified again.

Alert Package NoteSourceCI
Network access npm/[email protected] 🚫

View full report↗︎

Next steps

What is network access?

This module accesses the network.

Packages should remove all network access that is functionally unnecessary. Consumers should audit network access to ensure legitimate use.

Take a deeper look at the dependency

Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support [AT] socket [DOT] dev.

Remove the package

If you happen to install a dependency that Socket reports as Known Malware you should immediately remove it and select a different dependency. For other alert types, you may may wish to investigate alternative packages or consider if there are other ways to mitigate the specific risk posed by the dependency.

Mark a package as acceptable risk

To ignore an alert, reply with a comment starting with @SocketSecurity ignore followed by a space separated list of ecosystem/package-name@version specifiers. e.g. @SocketSecurity ignore npm/[email protected] or ignore all packages with @SocketSecurity ignore-all

@legobeat legobeat changed the title deps: migrate from legacy ethjs to @metamask/ethjs fix: migrate from legacy ethjs to @metamask/ethjs Oct 23, 2024
@legobeat legobeat added dependencies Pull requests that update a dependency file team-application-security Application security team Run Smoke E2E labels Oct 23, 2024
@github-actions
Copy link
Contributor

github-actions bot commented Oct 23, 2024

https://bitrise.io/ Bitrise

❌❌❌ pr_smoke_e2e_pipeline failed on Bitrise! ❌❌❌

Commit hash: 5d81074
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/885211b6-0973-4bb6-b0b7-b125f6589328

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

Tip

  • Check the documentation if you have any doubts on how to understand the failure on bitrise

@legobeat legobeat changed the title fix: migrate from legacy ethjs to @metamask/ethjs fix: migrate from deprecated legacy packages Oct 23, 2024
github-merge-queue bot pushed a commit that referenced this pull request Oct 23, 2024
## **Description**

- fix: migrate from legacy `ethjs-` packages to maintained and already
used `@metamask/ethjs-` forks
  - Removes dependency on deprecated `babel-runtime` v6
  - Bundle size reduction

## **Related issues**

- #11952
- #11932

#### Blocking
- #11968

## **Manual testing steps**


## **Screenshots/Recordings**

### **Before**

### **After**

## **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
- [ ] 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.
github-merge-queue bot pushed a commit that referenced this pull request Oct 23, 2024
## **Description**

Bump `eth-json-rpc-filters`

## **Related issues**

- #11973

#### Blocking
- #11968

## **Manual testing steps**


## **Screenshots/Recordings**

### **Before**

### **After**

## **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
- [ ] 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.
@NicolasMassart NicolasMassart self-assigned this Dec 3, 2024
@github-actions
Copy link
Contributor

github-actions bot commented Mar 3, 2025

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 Mar 3, 2025
@legobeat
Copy link
Contributor Author

still relevant

@github-actions github-actions bot removed the stale Issues that have not had activity in the last 90 days label Mar 10, 2025
github-merge-queue bot pushed a commit that referenced this pull request Mar 13, 2025
## **Description**

- Unpin and dedupe `ethereumjs-util` and `ethereumjs-abi` while staying
on legacy v6
- Replace `import { BN } from 'ethereumjs-util'` with importing `BN`
explicitly from either `bn.js@4` or `bn.js@5`
  - Mixing the two is not safe and can cause breakage.
- [Some on why this is A Bad
Thing](ethereumjs/ethereumjs-util#250)
- We don't get complete and correct typings with importing the old
re-export
- This adds both v4 and v5 as explicit dependencies - ideally v4 will be
removed as transition to v5 concludes
- Add EIP-1191 address checksum algorithm support for
`toChecksumAddress()`
- Unblock relying on the ancient and deprecated `[email protected]`
  
- [`ethereumjs-util`
changelog](https://github.com/ethereumjs/ethereumjs-util/blob/master/CHANGELOG.md)
-
[`[email protected]`](ethereumjs/ethereumjs-util@v6.1.0...v6.2.0)

## **Related issues**

- indutny/bn.js#209
- indutny/bn.js#295
- #12010

#### Blocking
- #11932
  - #12043
  - #11968

## **Manual testing steps**


## **Screenshots/Recordings**

### **Before**

### **After**

## **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: Nicolas MASSART <[email protected]>
Co-authored-by: Nico MASSART <[email protected]>
@EllusionN EllusionN removed the team-application-security Application security team label Sep 25, 2025
@metamaskbot metamaskbot added the INVALID-PR-TEMPLATE PR's body doesn't match template label Sep 25, 2025
@NicolasMassart
Copy link
Contributor

deprecated

@github-actions github-actions bot locked and limited conversation to collaborators Oct 29, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

dependencies Pull requests that update a dependency file external-contributor INVALID-PR-TEMPLATE PR's body doesn't match template team-lavamoat

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

5 participants