When i run ionic build android --prod --release
i get a failure see below at end of scripts (THis only happens on my macbook but not on my windows) any ideas? i am on ionic 2.2.0.
Note this has been working fine for a month now it just started breaking yesterday… no idea why
12:57:25] ionic-app-scripts 1.1.4
[12:57:25] build prod started …
[12:57:25] clean started …
[12:57:25] clean finished in 4 ms
[12:57:25] copy started …
[12:57:25] ngc started …
[12:57:42] ngc finished in 17.17 s
[12:57:42] preprocess started …
[12:57:42] optimization started …
[12:57:43] copy finished in 17.61 s
[12:57:59] optimization finished in 16.59 s
[12:57:59] preprocess finished in 16.59 s
[12:57:59] webpack started …
[12:58:41] webpack finished in 42.28 s
[12:58:41] sass started …
[12:58:41] transpile bundle started …
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory
** 1:**
<— Last few GCs —>
97800 ms: Mark-sweep 1327.6 (1426.7) -> 1315.8 (1428.7) MB, 851.4 / 0.0 ms [allocation failure] [GC in old space requested].
98672 ms: Mark-sweep 1315.8 (1428.7) -> 1315.8 (1429.7) MB, 871.8 / 0.0 ms [allocation failure] [GC in old space requested].
99653 ms: Mark-sweep 1315.8 (1429.7) -> 1315.8 (1395.7) MB, 981.7 / 0.0 ms [last resort gc].
100544 ms: Mark-sweep 1315.8 (1395.7) -> 1315.8 (1395.7) MB, 890.7 / 0.0 ms [last resort gc].
<— JS stacktrace —>
==== JS stack trace =========================================
Security context: 0x144b9a9cfb51
1: stringify [native json.js:178] [pc=0x340c28e519d7] (this=0x3c24e5d884d9 <an Object with map 0x7b295c75119>,E=0x36c559b12459 <an Object with map 0x28b729a95a39>,F=0x144b9a904381 ,S=0x144b9a904381 )
2: arguments adaptor frame: 1->3
3: getText [/Users/saulabiuakinlolu/Documents/testmobileui/node_modules/typescript/lib/typescript.js:35629] [pc=0x340c29051241]…
node::Abort() [/usr/local/bin/node]
2: node::FatalException(v8::Isolate*, v8::Localv8::Value, v8::Localv8::Message) [/usr/local/bin/node]
3: v8::internal::V8::FatalProcessOutOfMemory(char const*, bool) [/usr/local/bin/node]
4: v8::internal::NewRawOneByteString(int, v8::internal::PretenureFlag) [/usr/local/bin/node]
5: v8::internal::String::SlowFlatten(v8::internal::Handlev8::internal::ConsString, v8::internal::PretenureFlag) [/usr/local/bin/node]
6: v8::internal::BasicJsonStringifier::SerializeString(v8::internal::Handlev8::internal::String) [/usr/local/bin/node]
7: v8::internal::BasicJsonStringifier::Result v8::internal::BasicJsonStringifier::Serialize_(v8::internal::Handlev8::internal::Object, bool, v8::internal::Handlev8::internal::Object) [/usr/local/bin/node]
8: v8::internal::BasicJsonStringifier::Result v8::internal::BasicJsonStringifier::Serialize_(v8::internal::Handlev8::internal::Object, bool, v8::internal::Handlev8::internal::Object) [/usr/local/bin/node]
9: v8::internal::Runtime_BasicJSONStringify(int, v8::internal::Object**, v8::internal::Isolate*) [/usr/local/bin/node]
10: 0x340c261092a7