On Editor start: Failed to import ObjectProperty

Branch: Source
Build version: 4.5.1
Description:

In our project we faced a complex problem which was roughly as follows:

  1. I created a base actor and several children based on it.
  2. At some point in time, child blueprint had an actor variable attached to it", “MyParent”
  3. I then moved that “MyParent” variable from child to parent actor
  4. I spawned one of those children and immediately set (using actor reference pin from spawn node) MyParent variable in that child
  5. At that point game runs just fine, but once editor is restarted “Failed to import ObjectProperty” error message showed up.
  6. In child object blueprint, “MyParent” variable was greyed out. In blueprint that contains “Spawn from class” node which spawns that child, there were error messages on both spawn node and “Set MyParent” node.
  7. I managed to fix those errors by repeatedly recompiling several or all of those 3 blueprints and recreating Spawn and Set “MyParent” nodes
  8. game ran fine then, but when I restarted editor, it crashed. We were unable to recover project and had to revert respective changelists.
  9. I managed to “permanently” fix problem by creating a temporary variable which briefly holds actor reference from “Spawn from Class” node, which is then immediately retrieved and cast to parent, from whose pin then “MyParent” variable can be set without problems.

I tried to reproduce this bug in a simpler environment, but only partially succeeded. I was able to recreate “Failed to import ObjectProperty” part. Hopefully fixing that may help with larger problem as well.

It can be created as follows:

  1. Create a fresh project (“TwinStick Shooter” works just fine)
  2. Create three blueprints:
  3. A parent blueprint, which has a variable of type “Actor” and a function “ShowMyPosition”
  4. A child of that blueprint, which on event “ShowMyPosition” shows a debug sphere at position of that actor
  5. Another third actor blueprint, which spawns child blueprint, then immediately sets “actor” variable to “player pawn” and executes “ShowMyPosition”
  6. Spawn third blueprint in level script
  7. Start game and see how debug sphere is shown at player position
  8. Now save everything and restart editor
  9. On startup error message “Failed to import ObjectProperty” will be shown.

Here are some pictures to help out

Hey abeccu,

I wasn’t able to reproduce this error message using steps you listed above. Have you made any changes to source code? Please and attach crash log for project from crash you got, we may find a clue about what happened in there. Thanks!

Hi , thanks for quick reply. I’ll try to get you those logs.

Meanwhile I recreated problem once more in another fresh 4.5.1 Binary build. (I should probably mention repro from yesterday was also 4.5.1 binary, though original crash bug was 4.5 source)

I got “Failed to import object property” once again, though this time another error on top, “Failed to import event”. I’ll attach another screen shot.

blueprint code was same:

  1. Create a new twinstick shooter blueprint project
  2. Create 3 blueprints
  3. first one is parent and contains an actor variable and an empty function
  4. second one is a child of first. On event of parent’s function, it displays a sphere at location of actor in actor variable
  5. third is a blueprint that on BeginPlay simply spawns child and immediately overwrites actor variable with “player pawn” and executes function, triggering event (both using pin coming out of spawn node)
  6. That third actor I dragged into world. On start-up, sphere shows up.
  7. I then save everything and restart editor. error messages shown in 5th screenshot pop up.

Hi , here are log and a crash dump.

I attempted to reproduce this error again in a fresh project, also in 4.5.1 binary, but I still don’t get any errors on restarting project. Since you were able to get it in a new project, would you mind uploading test project somewhere and sending me a link? Thanks!

Hi , here’s a minimal project in which error occurs (in this case, only variable fails to import - event is fine once more).

Okay, I can see error in your project, though it seems identical in every way to mine. I’m going to dive into this and see what may be causing error. Thanks!

Thanks abeccu,

We believe this may be a circular dependency issue. I have entered a bug report (UE-5134) with a copy of project you provided as a test case, and I will let you know when I see an update on that. Thanks for detailed report and test project, that was really helpful!


i’m having a similar problem. been fine till I restarted client today and now it gives me this error when I start everytime

Hi,

This is a very old report and if you are seeing a similar issue now, it is likely a different cause. Could you create a new bug report that has exact repro steps and/or a small test project that has issue?

Thanks,

TJ

We just ran into this exact error on a project in 4.22, additionally I could not find a bug labeled UE-5134 in issues database. It seems reparenting a uasset with internal redirectors doesn’t always save updated references in uasset. After closing editor the ‘failed to import properties’ error appears and all we had to do was open and re-save affected uassets.