In my case, I had just updated XCode and iOS, so I ended up getting logged out of XCode.
I just had to log back in and everything went fine.