Meta BlueprintThreadSafe not working as specified

I have a method decorated with the meta BlueprintThreadSafe and BluprintPure which i would like to use in the state transition node on the anim blueprint. However unreal still gives a warning that it is not thread-safe. i call it on a component of the character. The reference to this component is aquired in the event graph of the anim blueprint. Although the blueprint warning points to the method GetCoverComponent as non thread-safe, it doesn’t do so if i only read a value of a variable from the same component.

UFUNCTION(BlueprintPure, Category = "Cover", meta = (BlueprintThreadSafe))
bool IsLeaveCoverRequest() const { return CoverIdleAction == ECoverIdleAction::LEAVE_COVER; }

This is quite bothersome, is there any solution to this?

Yes. I too would like a solution to this. It has plagued me for days.

Bump, I’m having the same problem.

UFUNCTION(BlueprintCallable, BlueprintPure, Meta = (BlueprintThreadSafe), Category = “State”)
bool WantToDoSomethingElse() const;

Working with this declaration and version 4.18.1

This is a method of the MyAnimInstance class.

Tried it again on 4.18.2 and it still doesn’t work. Does it also work for you if when it’s a method of the actor’s component?

can confirm, it does not work for us either in 4.18.2. I think it stopped working sometime at the end of last year, so it can be the update to 4.18.2 from 4.17 for us. Not sure in which version between 4.17 and 4.18.2 it broke, though.

According to Class Specifiers | Unreal Engine Documentation the meta tag BlueprintThreadSafe can only be used with functions in a Blueprint Function Library class, UBlueprintFunctionLibrary.
Those functions needs to be static to work.

Basically, this is all you need UFUNCTION(BlueprintCallable, BlueprintPure, Meta = (BlueprintThreadSafe), Category = “MyCategory”) and whatever else your function needs to be called with.

Unreal Docs Class Specifiers | Unreal Engine Documentation

Only valid on Blueprint function libraries. This specifier marks the functions in this class as callable on non-game threads in animation Blueprints."

As everything that has a “Warning!” Label, Use with caution, Was having this issue in following a tutorial on YT, Hope this helps another vigilant seeker, Happy Deving!