How to apply gameplay effect instance in multiplayer, created from code or Instanced property specifier

Hi everyone! question about GAS. is it possible to apply an effect not from class or GameplayEffectSpec from a class, namely the spec created from UGameplayEffect*, for example, if I have effects stored in the UPROPERTY array with the Instances specifier or the effect is created inside the code, the problem is that HasDuration effects do not change and replicate attributes (everything else is basically available)
here is my overlay code

maybe problem with effect prediction

FActiveGameplayEffectHandle USkillSystemHelpersLibrary::ApplyGameplayEffectInstanceWithParams(
    UAbilitySystemComponent* Source, UAbilitySystemComponent* Target, UEffectBase* Effect, const TMap<FGameplayTag, float>& SetByCallerMagnitudes)
{
    if(Effect && Target && Source)
    {
        Effect->OnApply(Source, Target);
        FGameplayEffectContextHandle EffectContext = Source->MakeEffectContext();

        FGameplayEffectSpec EffectSpec = FGameplayEffectSpec(Effect, EffectContext, 0.f);

        EffectSpec.SetByCallerTagMagnitudes = SetByCallerMagnitudes;

        return Source->ApplyGameplayEffectSpecToTarget(EffectSpec, Target, Source->ScopedPredictionKey);
    }

    return FActiveGameplayEffectHandle();
}