I'm have the same problem in Xcode 14.1 (14B47b). AnatolyMazkun, how these "pending agreements" are looks like? There are a lot of agreements in my account page on Apple developer portal, but they are just PDF documents, there are no "agree" buttons, switches or something to do an agreement.
Tried to remove/add my account in Accounts page in Xcode settings, then restart Xcode — nothing changed.