PCG Graph don't generate in runtime or uses old graph parameter

Hello! I need to generate pcg on start the game depends on values in some config. For example, I want to set density value and generate points with this value.
Here the graph scheme.

In my C++ class I get values from config, set to graph parameter and call Generate() in BeginPlay().

GraphIns->SetGraphParameter(FName("TreeDensity"), tree_density_);
PCGComp->Cleanup();
PCGComp->GenerateLocal(true);

Graph Parameters correctly change (i checked by GetGraphParameter), but the result during simulation level or playing the package seems like it has some old cached parameters, or like Generate() really not regenerate anything. Sometimes in editor Hot Compile helps (but not everytime). In package it looks like it bakes parameteres during building and uses them.
Generation Trigger is Generate on Demand (or Generate at Runtime with the same result)

I debugged the source code of the plugin and found out that the problem is that when the editor (or the package) starts, a graph generation task is created, which doesn’t have time to finish by the time BeginPlay() is called. So, when Generate() is called, nothing happens because such a task already exists. The solutions I see are:

  1. (I think this is more correct) wait until IsGenerating() becomes false and then call GenerateLocal(bForce=true);
  2. (A bad solution, but it will do as a temporary measure) since I don’t see any reason to create the graph at startup if I’m going to create a new one anyway, I added a condition in the source code of plugin: GenerationTrigger != EPCGComponentGenerationTrigger::GenerateOnDemand for generation on startup. This solution looks bad for real projects, but it allows me to win few time on the launch.