Property with default getting cleared on uasset duplication

I thought I put a bandaid on this issue awhile back: but it came back and I am not sure what the correct fix is. Our issue is the AttributeSet object on our root level C++ character is getting cleared on duplication or copy paste (and possibly new asset creation not sure how it occurred the first time). I thought this was just a weird one off bug a few weeks ago, because somehow the un-assignable default only character attributeset object got set to nullptr for some new characters, so I made the uproperty editable and manually reset it and all the blueprints up the hierarchy back to the defaults - seemed to fix all the cases except for copy-pasting assets as we found out today.

Names adjusted for simplicity:


UPROPERTY(EditAnywhere, BlueprintReadOnly)
UMyProjectAttributeSet* AttributeSet;


AttributeSet = CreateDefaultSubobject<UMyProjectAttributeSet>(TEXT("AttributeSet"));

Used to not be exposed to blueprint, but did so after it somehow nulled itself. Another interesting symptom is if I go through and manually set everything back to defaults on entire tree (tons of characters); then copy paste one of the character classes it copies correctly and the fields dont have the yellow → denoting a non- default value. If I then checkin these changes and close and open the editor all of the values are marked as not defaults, and the copy paste error returns. Kind of makes sense with this being of pointer type, but how these relate to the base classes CDO not entirely sure.

RPG example uses the setup as I have above, but the GASDocumentation sample uses TWeakObjectPtr AttributeSetBase.This smells like a bug, but perhaps I shouldnt be CreateDefaultSubobject-ing the attribute set like this as a pointer type?

I’m having the same problem and it also looks like a bug to me.