MetaMask / MetaMask/metamask-extension

[Bug]: Install - `TypeError: global.chrome?.runtime.getManifest is not a function`

Open
#42,034 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

regression-RC-13.28.0 Sev2-normal team-extension-platform team-mctp type-bug
Dominant language
TypeScript
Stars
13.2k
Forks
5.6k
Avg merge
2d 5h
Merged PRs (30d)
451

Description

Describe the bug

Whenever I'm importing a wallet build using yarn start I get the following type error in the offscreen.html TypeError: global.chrome?.runtime.getManifest is not a function.

Expected behavior

No errors/ error is handled

Screenshots/Recordings

https://github.com/user-attachments/assets/5fbbd471-d482-4aaa-b690-ac17214cebc8

Steps to reproduce
  1. Build the wallet locally
  2. Import it in Chrome
  3. Open offscreen.html
  4. See error
Error messages or log output
TypeError: global.chrome?.runtime.getManifest is not a function
Where was this bug found?

Internal release testing

Version

found using a dev build 13.28.0 but might be an earlier issue

Build type

None

Browser

Chrome

Operating system

MacOS

Hardware wallet

No response

Additional context

No response

Severity

No response

Jira issue

Expected behavior

No response

Screenshots/Recordings

No response

Steps to reproduce
  1. Build the wallet locally
  2. Import it in Chrome
  3. Open offscreen.html
  4. See error
Error messages or log output
TypeError: global.chrome?.runtime.getManifest is not a function
Where was this bug found?

No response

Version

found using a dev build 13.28.0 but might be an earlier issue

Build number

No response

Build type

None

Browser

Chrome

Operating system

MacOS

Hardware wallet

No response

Additional context

No response

Severity

Sev2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the problem by building the wallet with yarn start, importing it in Chrome, and opening offscreen.html. Inspect the code path that calls global.chrome?.runtime.getManifest and verify the Chrome runtime API behavior; done means opening offscreen.html no longer produces the uncaught TypeError.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.