Description

The new 'UncookedOnly' module type that was added in 4.24 is not visible to Blueprint nativization, and thus it does not know to exclude these module types from the generated Build.cs file when they are found to be a dependency of the Blueprint asset.

Current suggested workaround (from the forums):

To get around this you can manually set the package flags. PKG_EditorOnly or PKG_Developer should work. You can see where they're normally set under CodeGenerator.cpp

I did this during module startup and it seemed to work without issue.
Code:
void FYourEditorModule::StartupModule()
{
    const FString LongName = FPackageName::ConvertToLongScriptPackageName(TEXT("YourEditorModuleName"));
    if (UPackage* Package = Cast<UPackage>(StaticFindObjectFast(UPackage::StaticClass(), nullptr, *LongName, false, false)))
    {
        Package->SetPackageFlags(PKG_EditorOnly);
    }
Steps to Reproduce

N/A

Have Comments or More Details?

There's no existing public thread on this issue, so head over toAnswerHub just mention UE-86099 in the post.

1
Login to Vote

Fixed
ComponentGameplay - Blueprint
Affects Versions4.24
Target Fix4.25
Fix Commit10940572
CreatedDec 20, 2019
ResolvedJan 10, 2020
UpdatedJan 21, 2020