CodeSign Failed, get-task-allow entitlement doesn't match

I have a very simple Unreal project which is being packaged without the plugin Apple ARKit. When I enable ARKit, it gives me an error:

Provisioning Profile doesn’t match the entitlements file’s value for the get-task-allow entitlement. Error: CodeSign Failed

It a blueprint only project for now, so there is no xcworkspace. Engine: UE4.27plus.

How do I resolve this?