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

Build error on Windows10 #10748

Closed
wanglonghong opened this issue Mar 29, 2021 · 20 comments
Closed

Build error on Windows10 #10748

wanglonghong opened this issue Mar 29, 2021 · 20 comments
Labels
area-buildSystem related to our build system contributor experience An issue that impacts, or planned improvement to, the contributor experience. needs-triage

Comments

@wanglonghong
Copy link

I am trying to build Metamask9.2.1 on windows 10 using Nodejs 14.15

yarn run v1.22.4
$ lavamoat development/build/index.js
(Error#1)

Error#1: LavaMoat - required package not in whitelist: package "@gulp-sourcemaps\map-sources" requested "through2" as "through2"
at requireRelative (LavaMoat/core/kernel:414:15)
at requireRelativeWithContext (LavaMoat/core/kernel:366:16)
at Object.eval (\work\metamask-extension\node_modules@gulp-sourcemaps\map-sources\index.js:4:15)
at internalRequire (LavaMoat/core/kernel:353:25)
at requireRelative (LavaMoat/core/kernel:394:27)
at requireRelativeWithContext (LavaMoat/core/kernel:366:16)
at Object.eval (
\work\metamask-extension\node_modules\gulp-sourcemaps\index.js:7:15)
at internalRequire (LavaMoat/core/kernel:353:25)
at requireRelative (LavaMoat/core/kernel:394:27)
at requireRelativeWithContext (LavaMoat/core/kernel:366:16)

  • OS: WIndows 10
  • MetaMask Version: 9.2.1
  • Node 14.15
  • Yarn 1.22.4
@danjm danjm added needs-triage area-buildSystem related to our build system labels Apr 8, 2021
@cd3vane
Copy link

cd3vane commented Apr 25, 2021

I am having this same error trying to build it currently were you ever able to get around this?

@chirag64
Copy link

Facing the exact same issue on Windows 10 using node v14.15.1. Any update from dev team would be great as this stops contributors from taking part (though am curious how the dev team isn't facing this issue, unless this is specific to Windows 10)

@paranoiks
Copy link

I have the same issue on Windows 10 using Node 14.17

@sunshasha
Copy link

I am having this same error trying to build it currently were you ever able to get around this?

@paranoiks
Copy link

I installed Ubuntu on a VM and built the files in there

@jaewonha
Copy link

any progess?

@HappyCodingLover
Copy link

I did meet same error like this.

@danjm
Copy link
Contributor

danjm commented Jun 27, 2021

There is a bug we need to fix in our build system. Before we get the fix merged, you might find that the code change on this branch resolves the issue: https://github.com/MetaMask/metamask-extension/compare/lavamoat-dev-optional?expand=1

Edit: this will allow you to build MetaMask by running yarn start

@seniordev21
Copy link

There is a bug we need to fix in our build system. Before we get the fix merged, you might find that the code change on this branch resolves the issue: https://github.com/MetaMask/metamask-extension/compare/lavamoat-dev-optional?expand=1

I can't run your method.
please explain me in details.
Thanks.

@danjm
Copy link
Contributor

danjm commented Jun 28, 2021

@HappyCodingLover @seniordev21

I updated the comment.

If that code change is applied locally, you should be able to build MetaMask by running yarn start

@chirag64
Copy link

chirag64 commented Jun 29, 2021

@danjm

I switched to the lavamoat-dev-optional branch on my local and ran yarn start. The command does run successfully and I can see a list of files getting reloaded on the terminal.

But how do I run this dev build on my browser? If I make code changes and want to view them in my browser, how can I do that?

Sorry if this is a stupid question, I couldn't find this info on the README file.

Edit: Found it immediately after I posted this comment. For anyone else stuck on this, the details are in the Internal Docs

@ysy717324540
Copy link

I make the same mistake by running "yarn dist"

There is a bug we need to fix in our build system. Before we get the fix merged, you might find that the code change on this branch resolves the issue: https://github.com/MetaMask/metamask-extension/compare/lavamoat-dev-optional?expand=1

Edit: this will allow you to build MetaMask by running yarn start

@shubhamanandspeqto
Copy link

I have the same issue in Ubuntu.
how to solve these issues?

@CarlosMayoralMX
Copy link

There is a bug we need to fix in our build system. Before we get the fix merged, you might find that the code change on this branch resolves the issue: https://github.com/MetaMask/metamask-extension/compare/lavamoat-dev-optional?expand=1

Edit: this will allow you to build MetaMask by running yarn start

Hello,

I replaced the code by the suggested, but i got the same error, any updates on this issue?

@jesseharte
Copy link
Contributor

jesseharte commented Mar 8, 2022

I also face this issue for yarn build, while yarn start reports a Uncaught ReferenceError: LavaPack is not defined. I found that this is caused by the a Failed to load resource: net::ERR_FILE_NOT_FOUND runtime-cjs.js, but I believe that this file should have actually been created during the build:

dest: `runtime-cjs.js`,

@brad-decker brad-decker added the contributor experience An issue that impacts, or planned improvement to, the contributor experience. label Sep 27, 2022
@HowardBraham
Copy link
Contributor

Is anyone still having this problem? After PR #16550 was merged to develop today, I think there are no known problems with yarn start or yarn dist on Windows.

We should close this issue soon if nobody reports anything.

@thoth-seshat
Copy link

@HowardBraham I'm having that issue but I'm on Mac with yarn 3 and node v16

@HowardBraham
Copy link
Contributor

@thoth-seshat Are you up to date on the develop branch? Are you running yarn start? Have you tried deleting your node_modules?

@AnnaBarotova
Copy link

Hi!
I faced this issue on win 10, node 18.16, yarn 3.2.4... I'm up-to-date, node_modules were deleted.

@HowardBraham
Copy link
Contributor

@AnnaBarotova Try a git clone to a brand new folder? I'm just trying to figure out what might be going on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-buildSystem related to our build system contributor experience An issue that impacts, or planned improvement to, the contributor experience. needs-triage
Projects
None yet
Development

No branches or pull requests