x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Office Holiday

Epic Games' offices will be on holiday from June 22nd to July 7th. During this period support will be limited. Our offices will reopen on Monday, July 8th. 

Crash on closing PIE or BP

hello,

I'm having a crash every time I close a PIE session or closing my character BP window. this never happened in 4.9 and I haven't touched my code in months (probably since 4.7). just recently I converted it from 4.9 to 4.10 and now that I actually tried to play I get this crash.

so whenever I do PIE and close it, or open my character blueprint and close it, the engine will crash into this:

Assertion failed: ChildCount > AttachChildren.Num() [File:D:\BuildFarm\buildmachine_++depot+UE4-Releases+4.10\Engine\Source\Runtime\Engine\Private\Components\SceneComponent.cpp] [Line: 676] AttachChildren count increased while detaching 'None', likely caused by OnAttachmentChanged introducing new children, which could lead to an infinite loop.

this is the callstack for the PIE crash:

 UE4Editor-Engine.dll!USceneComponent::OnComponentDestroyed() Line 676    C++
 UE4Editor-Engine.dll!UActorComponent::BeginDestroy() Line 388    C++
 UE4Editor-Engine.dll!UPrimitiveComponent::BeginDestroy() Line 855    C++
 UE4Editor-CoreUObject.dll!UObject::ConditionalBeginDestroy() Line 659    C++
 UE4Editor-CoreUObject.dll!CollectGarbageInternal(EObjectFlags KeepFlags, bool bPerformFullPurge) Line 1362    C++
 UE4Editor-CoreUObject.dll!CollectGarbage(EObjectFlags KeepFlags, bool bPerformFullPurge) Line 1400    C++
 UE4Editor-UnrealEd.dll!UEditorEngine::EndPlayMap() Line 328    C++
 UE4Editor-UnrealEd.dll!UEditorEngine::Tick(float DeltaSeconds, bool bIdleMode) Line 978    C++

and this is the callstack for closing my character BP:

 UE4Editor-Engine.dll!USceneComponent::OnComponentDestroyed() Line 676    C++
 UE4Editor-Engine.dll!AActor::MarkComponentsAsPendingKill() Line 3722    C++
 UE4Editor-Engine.dll!UWorld::DestroyActor(AActor * ThisActor, bool bNetForce, bool bShouldModifyLevel) Line 640    C++
 UE4Editor-Engine.dll!UWorld::EditorDestroyActor(AActor * ThisActor, bool bShouldModifyLevel) Line 471    C++
 UE4Editor-Kismet.dll!FBlueprintEditor::DestroyPreview() Line 7863    C++

in both cases it crashes into USceneComponent::OnComponentDestroyed(), on this line:

 checkf(ChildCount > AttachChildren.Num(), TEXT("AttachChildren count increased while detaching '%s', likely caused by OnAttachmentChanged introducing new children, which could lead to an infinite loop."), *Child->GetName());

I checked with the debugger and ChildCount is 1, and AttachChildren.Num() is also 1. and the scenecomponent definately looks like it's owned by my Character.

maybe it's worth pointing out that I use several other custom-made C++ Components that I attach to my Character.

any ideas of something new that could introduce this?

Product Version: UE 4.10
Tags:
more ▼

asked Nov 19 '15 at 08:14 AM in Bug Reports

avatar image

Chosker
376 13 20 28

avatar image Pseudocorpus Nov 19 '15 at 09:02 PM

Similar thing happens for me in a packaged multiplayer project. The error pops up when the server goes offline/closes or sometimes even when the last remaining client disconnects. The Log-file says the following:

 Assertion failed: ChildCount > AttachChildren.Num() [File:D:\BuildFarm\buildmachine_++depot+UE4-Releases+4.10\Engine\Source\Runtime\Engine\Private\Components\SceneComponent.cpp] [Line: 676] 
 AttachChildren count increased while detaching 'StaticMeshComponent0', likely caused by OnAttachmentChanged introducing new children, which could lead to an infinite loop.

avatar image Sean L ♦♦ STAFF Nov 20 '15 at 04:29 PM

Hello,

I have a few questions in order to gather the information we need to attempt a repro on this crash:

  • Could you provide the logs from your crash?

  • Could you provide your Machine ID from the Crash Reporter window? Also, ensure that you hit send on the Crash Report.

  • Are you able to reproduce the issue in a clean project?

avatar image Pseudocorpus Nov 20 '15 at 06:03 PM

Hello,

thank you for your response.

  • I'll attach the log files for the packaged game. The files with the suffixes "_2" and "_3" are the logs from the clients, the one without suffix is the server one: http://www.struggleofmages.com/files/Logs.zip

  • The machine ID is the following: 695E24FB4D4B6838B5EACD9651F02A91

  • I could not reproduce this issue with a clean third person c++ project.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

Hello,

This issue has been entered into our system (UE-23366) and has been fixed internally. The fix will be available in a later version. For now, if you are still experiencing the crash, I recommend using the hotfix that Cø provided.

Have a great day,

Sean Flint

more ▼

answered Dec 02 '15 at 01:29 PM

avatar image

Sean L ♦♦ STAFF
43.6k 485 152 441

avatar image Chosker Dec 02 '15 at 02:19 PM

great, thanks!

do you know if this fix will make it to a theoretical 10.1, or do we have to wait until 11.0?

avatar image Sean L ♦♦ STAFF Dec 02 '15 at 02:31 PM

Currently, the fix is scheduled for a possible 4.10 hotfix. We cannot guarantee that the fix will be available at that time, so please let us know if you are still experiencing issues after that hotfix is released. Thank you.

avatar image Pseudocorpus Dec 03 '15 at 05:08 PM

Sounds good, thank you!

avatar image Chosker Dec 13 '15 at 02:17 PM

hello,

UE-23366 was indeed fixed by 4.10.1 as per the release notes. howeverwith 4.10.1, I still have the crash every time I close PIE

hence, the issue isn't really fixed, and UE4 is still broken for me :(

the link I sent you on the forums via PM with my project should still work, and it will help you reproduce it 100%

I hope you guys can fix it for the next release

avatar image Sean L ♦♦ STAFF Dec 14 '15 at 04:58 PM

Hello Chosker,

Thank you for the update regarding this issue. I have updated UE-23366 to reflect that it is still occurring as of 4.10.1.

avatar image Pseudocorpus Dec 15 '15 at 04:51 PM

Same here. When a client window is being closed (in the packaged version) during a multiplayer game, the error window pops up.

avatar image windkey_kao Dec 17 '15 at 05:58 AM

I have reached similar crash and post a new information here: https://answers.unrealengine.com/questions/348138/trash-components-cause-ue4101-crash.html Maybe you can print your sub components in crashed blueprint.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Hi, we had the exact same issue while upgrading to 4.10.

In void USceneComponent::OnComponentDestroyed() while looping on children one of them has its AttachParent null (we didn't found how it is even possible to be in AttachChildren list without having any AttachParent).

We hot fixed our engine sources to handle this case:

     int32 ChildCount = AttachChildren.Num();
     while (ChildCount > 0)
     {
         if (USceneComponent* Child = AttachChildren.Last())
         {
             if (AttachParent)
             {
                 Child->AttachTo(AttachParent);
             }
 //EDIT BEGIN: fix assertion when Child->AttachParent is null and so Child->DetachFromParent(); does nothing
             else if (nullptr != Child->AttachParent)
             {
                 Child->DetachFromParent();
             }
             else
             {
                 AttachChildren.Pop(false);
             }
 //EDIT END
             checkf(ChildCount > AttachChildren.Num(), TEXT("AttachChildren count increased while detaching '%s', likely caused by OnAttachmentChanged introducing new children, which could lead to an infinite loop."), *Child->GetName());
         }
         else
         {
             AttachChildren.Pop(false);
         }
         ChildCount = AttachChildren.Num();
     }

Hope it helps.

more ▼

answered Nov 20 '15 at 06:20 PM

avatar image


1.4k 47 32 103

avatar image Pseudocorpus Nov 21 '15 at 12:09 PM

Hey Cø and thank you for your help. Sounds like a good solution to check the "AttachParent = NULL"-Case.

However I'm using the binary version and I'd rather not touch the source code, since I would have to consider the changes on every engine upgrade.

Maybe the Epic-guys could have a look at Cø's solution?

avatar image Sean L ♦♦ STAFF Nov 23 '15 at 02:12 PM

Testing the solution would require a project with a similar setup to the one that you are using in your project. Could you provide repro steps so that I can attempt to reproduce the issue on our end, and then test the fix to see if it is indeed working? If you are unsure of what steps you took to get the crash to occur, could you submit your project so that I can test the fix? Thank you.

avatar image Pseudocorpus Nov 24 '15 at 07:14 PM

Thanks for your response, Sean. I've send you a PM on the forums with the project folder.

avatar image Doug E ♦♦ STAFF Nov 25 '15 at 08:37 PM

Hey Braindrain85-

Sean Flint and I are looking at the project you sent him. We've packaged the project and are able to start a server from the button in the upper left corner. For testing purposes, is there a simple way to connect multiple clients or will it require going through the Sign Up process?

avatar image Chosker Dec 01 '15 at 09:37 AM

hello,

any update on this?

avatar image Sean L ♦♦ STAFF Dec 01 '15 at 03:19 PM

Hello Chosker,

I would recommend giving Cø's hotfix a try and seeing if that prevents the crash from occurring in your project. Otherwise, we will need more information regarding what exactly is causing the crash, and how we can reproduce the issue.

avatar image Chosker Dec 01 '15 at 03:23 PM

well I don't have the source set up, nor do I have time to do so. but I thought you had enough to reproduce the issue by using Braindrain85's project

if you still can't reproduce it I can send you my project, there it happens 100% of the times that I close PIE.

avatar image Sean L ♦♦ STAFF Dec 01 '15 at 03:31 PM

We are awaiting a response from BrainDrain85 as far as how to reproduce the crash using his project. As far as what you can do, if you'd like to send your project we can take a look at it.

avatar image Chosker Dec 01 '15 at 10:31 PM

I sent you a PM on the forums with my project files. a lot of files are missing so you'll have some missing references, but it should still allow you to play and reproduce the issue.

repro steps:

  1. load the project

  2. open eTestMap

  3. play in a new editor window

  4. close the game window

  5. pull your hair out as it crashes every time :D

let me know if it works for you

avatar image Pseudocorpus Dec 01 '15 at 10:40 PM

Sorry, I didn't receive a message for this thread until now. You don't have to sign up since I've sent you two account infos with which you can login. You can also open the console by pressing PageUp and type in "open 127.0.0.1", but I wasn't able to reproduce the issue with this method.

avatar image Chosker Dec 24 '15 at 05:27 AM

hello,

just checking in to report that this crash still occurs in 4.11 Preview 1

cheers

avatar image Stefan Lundmark Mar 21 '16 at 11:03 PM

Still occurs in 4.10.1 as well.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question