wallet: Make `fetch` injectable in `NetworkController` initialization
Los mantenedores suelen responder en 1 día
@grypez ya está trabajando en esto.
Desde el 26/5/2026.
Evaluación
Este issue todavía no se ha evaluado.
Descripción
Problem
getRpcServiceOptions in packages/wallet/src/initialization/instances/network-controller.ts hardcodes fetch to globalThis.fetch. Platforms that provide their own fetch implementation — React Native being the primary example — cannot supply it, making the wallet non-portable across those environments.
Proposed direction
Add an optional fetch?: typeof globalThis.fetch field to WalletOptions. The NetworkController init should use options.fetch ?? globalThis.fetch.bind(globalThis) when building getRpcServiceOptions, so the default behaviour is unchanged and platform-specific implementations can be injected at construction time.
Acceptance
WalletOptionshas an optionalfetchfield.getRpcServiceOptionsuses the injected fetch when provided, falling back toglobalThis.fetch.- Existing tests pass; a test covers the injected-fetch path.
- Changelog entry added.
- Lenguaje dominante
- TypeScript
- Estrellas
- 424
- Forks
- 311
- Merge medio
- 1 d 8 h
- PR fusionados (30 d)
- 446
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Sin guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de MetaMask/core
-
EIP-1898 object selectors fail before downstream RPC in eth-json-rpc-middleware 26.0.0Posiblemente ocupada @debojyoti10CC la tomó hace 5 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
Los mantenedores suelen responder en 1 día
-
CI: "Validate changelog diffs" job fails on every fork-sourced pull requestPosiblemente ocupada @Roxen-AS la tomó hace 37 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día
-
platform-api-docs: `scan` strategy misses ESM-only packages, which ship `.d.ts` rather than `.d.cts`Posiblemente ocupada @gaohan1994 la tomó hace 38 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Los mantenedores suelen responder en 1 día
-
[utils] Replace the `uuid` dependency with `crypto.randomUUID()`Posiblemente ocupada @avantikonde la tomó hace 51 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
MetaMask/core#10210 · 1 reacción ·
Los mantenedores suelen responder en 1 día
-
[utils] `toWei` accepts fractional wei and returns wrong valuesPosiblemente ocupada @Roxen-AS la tomó hace 37 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
Los mantenedores suelen responder en 1 día
Todos los issues de MetaMask/core
Issues similares
-
Flaky test: selecting a portion just after inserting it can also match its Change and Delete buttonsAbiertoready-for-agent
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
linagora/dcs-onlyoffice#172 ·
-
bug follow-up
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
Los mantenedores suelen responder en 1 día
-
nightly-tests
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
BlackBeltTechnology/pi-agent-dashboard#1226 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
danielmiessler/LifeOS#3028 ·
Los mantenedores suelen responder en 5 días
-
execute_sql cannot create a SQLite trigger or a PostgreSQL BEGIN ATOMIC function: the statement is cut at the semicolons inside its bodyPosiblemente ocupada @goranai la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
Los mantenedores suelen responder en 1 día