You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This behaviour can be reproduced locally by running this Dependabot update branch: bbc/simorgh#11779
I tried downgrading @emotion/jest back to 11.11.0 and it appears to work and not crash out (although causes snapshot issues, probably due to the mismatch between versions of expected packages)
Previously 11.12.0 of the other Emotion packages, apart from @emotion/jest, also worked: bbc/simorgh#11776
<--- Last few GCs --->
[2287:0x6fed8b0] 212859 ms: Mark-sweep (reduce) 2986.5 (3669.6) -> 2986.2 (3626.8) MB, 1090.5 / 0.0 ms (average mu = 0.018, current mu = 0.001) last resort; GC in old space requested
[2287:0x6fed8b0] 214007 ms: Mark-sweep (reduce) 2986.2 (3626.8) -> 2986.1 (3615.6) MB, 1147.6 / 0.0 ms (average mu = 0.009, current mu = 0.001) last resort; GC in old space requested
<--- JS stacktrace --->
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory
1: 0xb9c1f0 node::Abort() [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
2: 0xaa27ee [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
3: 0xd73950 v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
4: 0xd73cf7 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
5: 0xf3f18f v8::internal::HeapAllocator::AllocateRawWithRetryOrFailSlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
6: 0xf1f158 v8::internal::Factory::CodeBuilder::AllocateCode(bool) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
7: 0xf330cc v8::internal::Factory::CodeBuilder::BuildInternal(bool) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
8: 0xf33b1e v8::internal::Factory::CodeBuilder::Build() [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
9: 0x15ed38e v8::internal::RegExpMacroAssemblerX64::GetCode(v8::internal::Handle<v8::internal::String>) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
10: 0x12b1e86 v8::internal::RegExpCompiler::Assemble(v8::internal::Isolate*, v8::internal::RegExpMacroAssembler*, v8::internal::RegExpNode*, int, v8::internal::Handle<v8::internal::String>) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
11: 0x12d1db7 v8::internal::RegExpImpl::Compile(v8::internal::Isolate*, v8::internal::Zone*, v8::internal::RegExpCompileData*, v8::base::Flags<v8::internal::RegExpFlag, int>, v8::internal::Handle<v8::internal::String>, v8::internal::Handle<v8::internal::String>, bool, unsigned int&) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
12: 0x12d2532 v8::internal::RegExpImpl::CompileIrregexp(v8::internal::Isolate*, v8::internal::Handle<v8::internal::JSRegExp>, v8::internal::Handle<v8::internal::String>, bool) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
13: 0x12d30ee v8::internal::RegExpImpl::IrregexpPrepare(v8::internal::Isolate*, v8::internal::Handle<v8::internal::JSRegExp>, v8::internal::Handle<v8::internal::String>) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
14: 0x12d3293 v8::internal::RegExpImpl::IrregexpExec(v8::internal::Isolate*, v8::internal::Handle<v8::internal::JSRegExp>, v8::internal::Handle<v8::internal::String>, int, v8::internal::Handle<v8::internal::RegExpMatchInfo>, v8::internal::RegExp::ExecQuirks) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
15: 0x12f862e v8::internal::Runtime_RegExpExec(int, unsigned long*, v8::internal::Isolate*) [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
16: 0x17120b9 [/opt/hostedtoolcache/node/18.20.4/x64/bin/node]
Similar situation here, bumped @emotion/jest from 11.11.0 to 11.13.0 and now if I run my tests with --detectLeaks, they all fail as leaking memory. Going back to 11.11.0 solves it.
Unfortunately can't provide a small repo to reproduce.
Current behavior:
We're seeing a potential memory leak from the latest version of
@emotion
, possibly the@emotion/jest
library specifically: https://github.com/bbc/simorgh/actions/runs/10039435131/job/27743362024?pr=11779This behaviour can be reproduced locally by running this Dependabot update branch: bbc/simorgh#11779
I tried downgrading
@emotion/jest
back to11.11.0
and it appears to work and not crash out (although causes snapshot issues, probably due to the mismatch between versions of expected packages)Previously
11.12.0
of the other Emotion packages, apart from@emotion/jest
, also worked: bbc/simorgh#11776To reproduce:
yarn
to install dependenciesyarn test:unit
to run unit testsJavaScript heap out of memory
errorExpected behavior:
Environment information:
react
version: 18.3.1@emotion/react
version: 11.13.0The text was updated successfully, but these errors were encountered: