Editor crashes when changed component class and assign skeletal mesh asset

it blocks the workflow of change component class in editor.

(Note: looks like compile the blueprint after changing the component class could avoid the crash.)

[Attachment Removed]

Steps to Reproduce

  1. create a blueprint from ACharacter and SAVE it
  2. create TWO blueprint component classes from USkeletalMeshComponent: “BP_SkeletalComponentTypeA” and “BP_SkeletalComponentTypeB”
  3. change the component class of Mesh to BP_SkeletalComponentTypeB
  4. change the component class of Mesh to BP_SkeletalComponentTypeA
  5. assign a SkeletalMesh asset to it
  6. editor should be crashed

the call stack should looks like:

Script Stack (0 frames) :

Fatal error: [File:D:\U\Engine\Source\Runtime\CoreUObject\Private\UObject\UObjectGlobals.cpp] [Line: 3673]

Cannot replace existing object of a different class.

New Object: /Game/Folder/BP_SkeletalComponentTypeB.BP_SkeletalComponentTypeB_C /Engine/Transient.World_8:PersistentLevel.BP_NewCharacter_C_0.CharacterMesh0

Existing Object: /Game/Folder/BP_SkeletalComponentTypeA.BP_SkeletalComponentTypeA_C /Engine/Transient.World_8:PersistentLevel.BP_NewCharacter_C_0.CharacterMesh0 (0x00040040 0x00004000)

[Attachment Removed]

Hello [mention removed]​

Thank you for reaching out.

I’ve been assigned your case and will look into it.

All the best,

[mention removed]​

[Attachment Removed]

Hello [mention removed]​

I was able to reproduce the crash.

I’ll investigate some more and get back to you.

All the best,

[mention removed]​

[Attachment Removed]

Hello [mention removed]​

Sorry for the delayed response, I’m still working on it.

I noticed that this issue happens in earlier versions of the engine as well - it reproduces in 5.5, the earlier version I have installed.

I also noticed that, if you set a Mesh after swapping the component class the first time, the behavior does not reproduce - the second change of the component class and setting a Mesh later does not cause a crash.

Interestingly, it looks like the cause of the bug is the thumbnail generation of the Mesh asset.

Let me know if you are blocked by this issue.

All the best,

[mention removed]​

[Attachment Removed]

Hi, [mention removed]​

> the second change of the component class and setting a Mesh later does not cause a crash.

> Let me know if you are blocked by this issue.

No, I think I could avoid it by not setting the mesh after swapping the component class for the first time.

Thanks for keeping working on it. Hope it could be resolved in the next engine release.

I was worried about this workflow is not properly supported by the engine.

Have a nice day,

[mention removed]​

[Attachment Removed]

Hello [mention removed]​

I’m glad you are not blocked by this issue.

I’ll open a ticket and share the public link once I have it.

All the best,

[mention removed]​

[Attachment Removed]

Hello [mention removed]​

I’ve made a JIRA report at: Unreal Engine Issues and Bug Tracker (UE\-361673)

Please note that it can take some time to be made publicly accessible.

We don’t provide updates on EPS, but if you would like to track the resolution, check the link for the status.

Please let me know if I can assist you with anything else or if I can proceed with closing this ticket.

All the best,

[mention removed]​

[Attachment Removed]