Skip to content

React npm run build is failing #8238

Closed
Closed
@anandbabud1987

Description

@anandbabud1987

npm run build is failing for reactjs

npm run build

avoda@0.1.0 build C:\Users\anand\worksempire.com
react-scripts build

Creating an optimized production build...

<--- Last few GCs --->

[16588:000002100CB5E0E0] 34186 ms: Scavenge 1382.7 (1423.5) -> 1382.1 (1424.0) MB, 5.3 / 0.0 ms (average mu = 0.106, current mu = 0.069) allocation failure
[16588:000002100CB5E0E0] 34192 ms: Scavenge 1382.9 (1424.0) -> 1382.2 (1425.0) MB, 4.8 / 0.0 ms (average mu = 0.106, current mu = 0.069) allocation failure
[16588:000002100CB5E0E0] 34198 ms: Scavenge 1383.0 (1425.0) -> 1382.4 (1425.5) MB, 4.6 / 0.0 ms (average mu = 0.106, current mu = 0.069) allocation failure

<--- JS stacktrace --->

==== JS stack trace =========================================

0: ExitFrame [pc: 0000024AA335C5C1]

Security context: 0x02a79b91e6e9
1: SourceMapConsumer_allGeneratedPositionsFor [0000032BF0CE5831] [C:\Users\anand\worksempire.com\node_modules\source-map\lib\source-map-consumer.js:~178] [pc=0000024AA4323373](this=0x006d07082291 ,aArgs=0x023eb9e02249 )
2: /* anonymous /(aka / anonymous */) [000002EF6CA...

FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory
1: 00007FF6E1477DDA v8::internal::GCIdleTimeHandler::GCIdleTimeHandler+4506
2: 00007FF6E1452876 node::MakeCallback+4534
3: 00007FF6E14531F0 node_module_register+2032
4: 00007FF6E176B6BE v8::internal::FatalProcessOutOfMemory+846
5: 00007FF6E176B5EF v8::internal::FatalProcessOutOfMemory+639
6: 00007FF6E1951DE4 v8::internal::Heap::MaxHeapGrowingFactor+9620
7: 00007FF6E1948DC6 v8::internal::ScavengeJob::operator=+24550
8: 00007FF6E194741C v8::internal::ScavengeJob::operator=+17980
9: 00007FF6E1950167 v8::internal::Heap::MaxHeapGrowingFactor+2327
10: 00007FF6E19501E6 v8::internal::Heap::MaxHeapGrowingFactor+2454
11: 00007FF6E1A7A487 v8::internal::Factory::NewFillerObject+55
12: 00007FF6E1AF7676 v8::internal::operator<<+73494
13: 0000024AA335C5C1
npm ERR! code ELIFECYCLE
npm ERR! errno 134
npm ERR! avoda@0.1.0 build: react-scripts build
npm ERR! Exit status 134
npm ERR!
npm ERR! Failed at the avoda@0.1.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\anand\AppData\Roaming\npm-cache_logs\2019-12-25T07_59_04_632Z-debug.log

npm -v
5.10.0

node -v
v10.18.0

windows 10 surface

Activity

heyimalex

heyimalex commented on Dec 27, 2019

@heyimalex
Contributor

Duplicate of #8096

anandbabud1987

anandbabud1987 commented on Dec 29, 2019

@anandbabud1987
Author

I have found the working solution.
set GENERATE_SOURCEMAP=false

locked and limited conversation to collaborators on Jan 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @heyimalex@anandbabud1987

        Issue actions

          React npm run build is failing · Issue #8238 · facebook/create-react-app