Error: Java heap space - Lightrun

文章推薦指數: 80 %
投票人數:10人

Comparing the screenshot step is failing with an error: Java heap space Further, look into gives: When org.gradle.jvmargs=-Xmx1024m is set , the java heap ... Error:Javaheapspace(OriginalURL)Comparingthescreenshotstepisfailingwithanerror:Javaheapspace Further,lookintogives: Whenorg.gradle.jvmargs=-Xmx1024misset,thejavaheaperrorwasconsistent Whenincreasedorg.gradle.jvmargs=-Xmx4608misset,thefrequencyoferrorhasdroppeddowntoalmost20%. Comparingscreenshotswithpreviousones. [02:14:07]:▸>Task:sample:phoneDebugExecuteScreenshotTestsFAILED [02:14:07]:▸FAILURE:Buildfailedwithanexception. [02:14:07]:▸*Whatwentwrong: [02:14:07]:▸Executionfailedfortask':sample:phoneDebugExecuteScreenshotTests'. [02:14:07]:▸>Javaheapspace [02:14:07]:▸*Try: [02:14:07]:▸Runwith--infoor--debugoptiontogetmorelogoutput.Runwith--scantogetfullinsights. [02:14:07]:▸*Exceptionis: [02:14:07]:▸org.gradle.api.tasks.TaskExecutionException:Executionfailedfortask':sample:phoneDebugExecuteScreenshotTests'. [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.lambda$executeIfValid$1(ExecuteActionsTaskExecuter.java:207) [02:14:07]:▸atorg.gradle.internal.Try$Failure.ifSuccessfulOrElse(Try.java:263) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeIfValid(ExecuteActionsTaskExecuter.java:205) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:186) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.CleanupStaleOutputsExecuter.execute(CleanupStaleOutputsExecuter.java:114) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.FinalizePropertiesTaskExecuter.execute(FinalizePropertiesTaskExecuter.java:46) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.ResolveTaskExecutionModeExecuter.execute(ResolveTaskExecutionModeExecuter.java:62) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:57) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:56) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:36) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.executeTask(EventFiringTaskExecuter.java:77) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:55) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:52) [02:14:07]:▸atorg.gradle.internal.operations.DefaultBuildOperationExecutor$CallableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:409) [02:14:07]:▸atorg.gradle.internal.operations.DefaultBuildOperationExecutor$CallableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:399) [02:14:07]:▸atorg.gradle.internal.operations.DefaultBuildOperationExecutor$1.execute(DefaultBuildOperationExecutor.java:157) [02:14:07]:▸atorg.gradle.internal.operations.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:242) [02:14:07]:▸atorg.gradle.internal.operations.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:150) [02:14:07]:▸atorg.gradle.internal.operations.DefaultBuildOperationExecutor.call(DefaultBuildOperationExecutor.java:94) [02:14:07]:▸atorg.gradle.internal.operations.DelegatingBuildOperationExecutor.call(DelegatingBuildOperationExecutor.java:36) [02:14:07]:▸atorg.gradle.api.internal.tasks.execution.EventFiringTaskExecuter.execute(EventFiringTaskExecuter.java:52) [02:14:07]:▸atorg.gradle.execution.plan.LocalTaskNodeExecutor.execute(LocalTaskNodeExecutor.java:41) [02:14:07]:▸atorg.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:356) [02:14:07]:▸atorg.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:343) [02:14:07]:▸atorg.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:336) [02:14:07]:▸atorg.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:322) [02:14:07]:▸atorg.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.lambda$run$0(DefaultPlanExecutor.java:127) [02:14:07]:▸atorg.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.execute(DefaultPlanExecutor.java:191) [02:14:07]:▸atorg.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.executeNextNode(DefaultPlanExecutor.java:182) [02:14:07]:▸atorg.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.run(DefaultPlanExecutor.java:124) [02:14:07]:▸atorg.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:64) [02:14:07]:▸atorg.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:48) [02:14:07]:▸atorg.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:56) [02:14:07]:▸Causedby:java.lang.OutOfMemoryError:Javaheapspace [02:14:07]:▸atscala.collection.mutable.ResizableArray.ensureSize(ResizableArray.scala:106) [02:14:07]:▸atscala.collection.mutable.ResizableArray.ensureSize$(ResizableArray.scala:96) [02:14:07]:▸atscala.collection.mutable.ArrayBuffer.ensureSize(ArrayBuffer.scala:49) [02:14:07]:▸atscala.collection.mutable.ArrayBuffer.$plus$eq(ArrayBuffer.scala:85) [02:14:07]:▸atscala.collection.mutable.ArrayBuffer.$plus$eq(ArrayBuffer.scala:49) [02:14:07]:▸atscala.collection.generic.Growable.$anonfun$$plus$plus$eq$1(Growable.scala:62) [02:14:07]:▸atscala.collection.generic.Growable$$Lambda$2154/0x0000000801378040.apply(UnknownSource) [02:14:07]:▸atscala.collection.Iterator.foreach(Iterator.scala:943) [02:14:07]:▸atscala.collection.Iterator.foreach$(Iterator.scala:943) [02:14:07]:▸atcom.sksamuel.scrimage.AwtImage$$anon$1.foreach(AwtImage.scala:52) [02:14:07]:▸atscala.collection.generic.Growable.$plus$plus$eq(Growable.scala:62) [02:14:07]:▸atscala.collection.generic.Growable.$plus$plus$eq$(Growable.scala:53) [02:14:07]:▸atscala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:105) [02:14:07]:▸atscala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:49) [02:14:07]:▸atscala.collection.TraversableOnce.to(TraversableOnce.scala:366) [02:14:07]:▸atscala.collection.TraversableOnce.to$(TraversableOnce.scala:364) [02:14:07]:▸atcom.sksamuel.scrimage.AwtImage$$anon$1.to(AwtImage.scala:52) [02:14:07]:▸atscala.collection.TraversableOnce.toBuffer(TraversableOnce.scala:358) [02:14:07]:▸atscala.collection.TraversableOnce.toBuffer$(TraversableOnce.scala:358) [02:14:07]:▸atcom.sksamuel.scrimage.AwtImage$$anon$1.toBuffer(AwtImage.scala:52) [02:14:07]:▸atscala.collection.TraversableOnce.toArray(TraversableOnce.scala:345) [02:14:07]:▸atscala.collection.TraversableOnce.toArray$(TraversableOnce.scala:339) [02:14:07]:▸atcom.sksamuel.scrimage.AwtImage$$anon$1.toArray(AwtImage.scala:52) [02:14:07]:▸atcom.sksamuel.scrimage.AwtImage.pixels(AwtImage.scala:43) [02:14:07]:▸atcom.karumi.shot.screenshots.ScreenshotsComparator.imagesAreDifferent(ScreenshotsComparator.scala:51) [02:14:07]:▸atcom.karumi.shot.screenshots.ScreenshotsComparator.compareScreenshot(ScreenshotsComparator.scala:33) [02:14:07]:▸atcom.karumi.shot.screenshots.ScreenshotsComparator.$anonfun$compare$1(ScreenshotsComparator.scala:13) [02:14:07]:▸atcom.karumi.shot.screenshots.ScreenshotsComparator$$Lambda$2254/0x000000080141a840.apply(UnknownSource) [02:14:07]:▸atscala.collection.parallel.AugmentedIterableIterator.flatmap2combiner(RemainsIterator.scala:133) [02:14:07]:▸atscala.collection.parallel.AugmentedIterableIterator.flatmap2combiner$(RemainsIterator.scala:130) [02:14:07]:▸atscala.collection.parallel.immutable.ParVector$ParVectorIterator.flatmap2combiner(ParVector.scala:66) [02:14:07]:▸atscala.collection.parallel.ParIterableLike$FlatMap.leaf(ParIterableLike.scala:1074) [02:14:07]:▸*Getmorehelpathttps://help.gradle.org/ [02:14:07]:▸DeprecatedGradlefeatureswereusedinthisbuild,makingitincompatiblewithGradle7.0. [02:14:07]:▸Use'--warning-modeall'toshowtheindividualdeprecationwarnings. [02:14:07]:▸Seehttps://docs.gradle.org/6.5/userguide/command_line_interface.html#sec:command_line_warnings [02:14:07]:▸BUILDFAILEDin14m14s [02:14:07]:▸79actionabletasks:79executed SnapshottestsonPhone Version:5.13.0 TryLightruntocollectproductionstacktraceswithoutstoppingyourJavaapplications!Comments(5)+1IgetthiswhenIhaveasignificantnumberofdifferences.(AndIknowtoleranceisappliedaftergatheringdifferences).Fromlookingatthecodeoftheimagecomparisonlibrary,theAWTimagesareneverflushed.Maybeaddingthiswillhelp? FormePR#314helps I’malsoreproducingtheissuewithShot5.14.1. Ihave22screenshotswhichhavearesolutionof1080x2400.IfIrunthemonadifferentdevicewithatoleranceof1.0,sotheyallpasswithawarning,IhaveanOOMexceptionifXmxissetat2G,butpassifIchangeitto4G. I’mhavingthesameissue.Itseemstohappenonlywhenacertainamountofdifferencesaredetected(e.g.250+changedscreenshotsorso). 🤔@NassirFfxthesampleprojectswehavearenotabletoreproducethiserror.canyoupleaseuploadasampleprojectwecanusetoreproducethisbug?I’malsowonderingifthisisrelatedtothenumberofimagesyouhaveorthesizeofsomeimages. PreviousissueRepeaterforSCHEDULEDkeyword-autoadvancingintothefutureNextissuecreateresourcedirectory



請為這篇文章評分?