Dynamic convex mesh collider not working until moved in the editor

I’m creating a dynamic mesh collider that updates every frame. The issue is that the collider doesn’t seem to enable until I move it in the inspector. Any idea why it’s not enabled the frame the dynamic mesh is assigned?

video of problem

Apparently every frame you update the collider you need to set it to null first

// on new frame clear collider
 GetComponent<MeshCollider>().sharedMesh = null;

// do your stuff to change mesh

// set new mesh to collider
 GetComponent<MeshCollider>().sharedMesh = newSharedMesh;