Factory.generated.h can't be found when including Factory.h from a plugin

Nope, it seems to be a bug on UE’s side, I’ve tried the same setup, but with the code setup as a different module instead of a plugin and the same error happens, however, from within the main game module everything works fine. Seems like there are problems including editor files from outside the main module.