[Bug] npm run develop does not work on Windows machine
See original GitHub issueAnother user (@cmccormack and I who both uses Windows, have run into a problem with the latest master updates when it comes to trying to running npm run develop
on our local machines.
See the following when I tried running npm run develop
in git-bash:
$ npm run develop
> @freecodecamp/freecodecamp@0.0.1 develop D:\coding\fcc
> npm-run-all -s ensure-env start-develop
> @freecodecamp/freecodecamp@0.0.1 ensure-env D:\coding\fcc
> cross-env DEBUG=fcc:* node ./tools/scripts/ensure-env.js
fcc:tools:ensure-env ignoring creation of redirect file in undefined +0ms
fcc:tools:ensure-env pathMigration present +11ms
> @freecodecamp/freecodecamp@0.0.1 start-develop D:\coding\fcc
> node ./tools/scripts/start-develop.js
> @freecodecamp/client@1.0.0 predevelop D:\Coding\fcc\client
> npm run prebuild
Debugger listening on ws://127.0.0.1:9229/ce7034de-7844-41f5-ab4a-bccf273b8f06
For help see https://nodejs.org/en/docs/inspector
> @freecodecamp/client@1.0.0 prebuild D:\Coding\fcc\client
> npm run build:frame-runner && node ../tools/scripts/ensure-env.js
> @freecodecamp/client@1.0.0 build:frame-runner D:\Coding\fcc\client
> webpack --env.production --config ./webpack-frame-runner.js
fcc:server:datasources using MailHog server on port 1025 +0ms
fcc:server:utils:about no google applications credentials environmental variable found
fcc:server:utils:about 'GOOGLE_APPLICATION_CREDENTIALS'
fcc:server:utils:about 'activeUser' api will always return 0
fcc:server:utils:about this can safely be ignored during development +3s
fcc:models:user setting up user hooks +934ms
fcc:server freeCodeCamp server listening on port 3000 in development +4s
fcc:server connecting to db at mongodb://localhost:27017/freecodecamp +26ms
Hash: d0144a0e981d544fd117
Version: webpack 4.22.0
Time: 10622ms
Built at: 2018-12-10 19:14:18
Asset Size Chunks Chunk Names
frame-runner.js 235 KiB 0 [emitted] frame-runner
frame-runner.js.map 1.18 MiB 0 [emitted] frame-runner
sass-compile.js 1.13 KiB 1 [emitted] sass-compile
sass-compile.js.map 4.89 KiB 1 [emitted] sass-compile
test-evaluator.js 156 KiB 2 [emitted] test-evaluator
test-evaluator.js.map 811 KiB 2 [emitted] test-evaluator
Entrypoint frame-runner = frame-runner.js frame-runner.js.map
Entrypoint sass-compile = sass-compile.js sass-compile.js.map
Entrypoint test-evaluator = test-evaluator.js test-evaluator.js.map
[92] (webpack)/buildin/global.js 489 bytes {0} {2} [built]
ModuleConcatenation bailout: Module is not an ECMAScript module
[320] ./src/client/frame-runner.js 4.13 KiB {0} [built]
ModuleConcatenation bailout: Module uses eval()
[321] ./src/client/workers/sass-compile.js 253 bytes {1} [built]
ModuleConcatenation bailout: Module is not an ECMAScript module
[322] ./src/client/workers/test-evaluator.js 2.49 KiB {2} [built]
ModuleConcatenation bailout: Module uses eval()
+ 324 hidden modules
> @freecodecamp/client@1.0.0 develop D:\Coding\fcc\client
> gatsby develop
fcc:server db connected +1s
fcc:boot:donate activeDonator count: 0 +1s
No Stripe API keys were found, moving on...
It hung on that last part. Both @cmccormack and I waited a very long time to no avail.
I even deleted my local repo and re-cloned and still was not able to make it work.
The only way to get it to work is a two create two session windows. In the first session you need to switch to api-server/
and then run node development-entry.js
. Once it gets to the same part regarding the “No Stripe API keys were found, moving on…”, in the second session, you then run npm run develop
and it will finally work and you will see:
You can now view @freecodecamp/client in the browser.
http://localhost:8000/
View GraphiQL, an in-browser IDE, to explore your site's data and schema
http://localhost:8000/___graphql
Note that the development build is not optimized.
To create a production build, use gatsby build
i 「wdm」:
i 「wdm」: Compiled successfully.
@Bouncey This is the same issue you helped @cmccormack work through back on November 27th.
Issue Analytics
- State:
- Created 5 years ago
- Comments:17 (17 by maintainers)
Top GitHub Comments
@RandellDawson
replace your
scripts
block with thisThen try
npm run develop
again.This script block change fixed my problem running it locally. I look forward to having it merged into master. Thanks @Bouncey I did not have any issues killing the process.