I tried to upgrade my project from expo SDK 29 to 31 and did all the steps correctly and got this error.
We actually had the same error when we tried it on one of my coworkers projects (His was SDK 30 → 31). Both projects are detached and we receive this error on iOS.
I saw a similar thread in expo forums but no good answer was given and topic was closed.