OtherCompilationError (5) when compiling code plugin

I’m trying to get a code plugin to compile (using the “Recompile” button of the Modules window), and I keep getting this mysterious “OtherCompilationError (5)” error. Here’s the error log (open image in new tab to see better):

Also here’s an overview of my plugin’s files. Basically I’m trying to make a custom animation node:

I tried all kinds of combinations of deleting the ‘Intermediate’ folder of the plugin, rebuilding the project in Visual Studio, restarting the editor, hitting the “Refresh Visual Studio Project” button and recompiling, but it didn’t change anything.

Here’s the content of the .generated.h.conflict file mentioned in the log:

And here is some of the rest of my plugin’s code:

AnimNodeTest.Build.cs: http://pastebin.com/xPWXeZkY

AnimNode_TranslateWith.h: http://pastebin.com/iRnYZxQ4

AnimNode.TranslateWith.cpp: http://pastebin.com/MC98mjpG

What I notice in the .conflict file is that it says the .generated.h is already included, and it’s missing #pragma once. But #pragma once is there in the .h file… and if I remove the .generated.h include as it suggests, it gives me an error saying I need to include the .generated.h. I dunno what to make of this error message

And don’t mind the name “TranslateWith”. It’s just a name I got from following a tutorial on custom animation nodes, but then I changed all the code to try and copy AnimNode_Root which is already included in UE4. (just to see if I could get it working)

Hi,

UE4 believes that you have a made a change to the plugin that causes it to cretae different headers and you are then trying to hot reload it - this will not work with hot reload as the editor needs to be closed and compiled ‘offline’ in order to build those header changes back into the rest of the code.

If that’s not what you’re doing, then you may have found a bug, and we’d need a complete set of reproduction steps in order to fix it.

The intent with the .conflict file is that you compare it to the regular header (i.e. compare AnimNode_TranslateWith.generated.h and AnimNode_TranslateWith.generated.h.conflict to see what has changed). You will need to post both of those files if you are unable to make your own diagnosis.

Steve

Marking this as resolved because restarting the editor was indeed the only way to recompile the plugin, and there were also some other errors in my code that I have solved since then.

(separating the plugin in a runtime and editor module, missing includes in privatePCH.h, etc…)