Fail to upload to App Store - Invalid Provisioning Profile

I'm getting the following error when trying to upload to the App Store after updating to Xcode 14.2 on macOS Ventura (13.1).

Asset validation failed (90161).
Invalid Provisioning Profile. The provisioning profile included in the bundle my-app-identifier-here [Payload/Runner.app] is invalid. [Missing code-signing certificate]. A Distribution Provisioning profile should be used when submitting apps to the App Store. For more information, visit the iOS Developer Portal. (ID: 078f5f94-0375-491f-9c00-8dfd7dc90bc4)

I've tried the following solutions and none of them have made any difference so far:

Solution #1

  1. Regenerate Provisioning Profiles by going to developer.apple.comCertificates, Identifiers & ProfilesProfiles → click on the ProfileEditSave
  2. Delete ~/Library/MobileDevice/Provisioning Profiles
  3. Open XcodeSettingsAccounts → select your Apple ID → select your TeamDownload Manual Profiles

Solution #2

Go to Xcode → SettingsAccounts → select your Apple ID → select your TeamManage Certificates → click on + on the left bottom, and click Apple Distribution, then click Download Manual Profiles.

Solution #3

  1. Revoke the existing Distribution Certificate at https://developer.apple.com/account/resources/certificates/list
  2. Generate a new Distribution Certificate, download it and install it.

Does anyone have a different one?

I did have an issue recently with my certificates or something. The only way I could get it to work was to refresh the certificate by adding a new new entitlement under the 'Signing and capabilities' for my app target. Then it downloaded a new certificate, then delete the thing you just added?. If you have automatically manage signing, and you click the little I for information, it gives you the date of the certificate. Make sure the date is today.

Fail to upload to App Store - Invalid Provisioning Profile
 
 
Q