Throw away account to protect the guilty.
I have an ISV app that I'm helping someone attempt to package. One of it's components is a Connected App, and I researched the careful dance described here: (https://developer.salesforce.com/docs/atlas.en-us.232.0.sfdx_dev.meta/sfdx_dev/sfdx_dev_dev2gp_connected_app.htm) I have, to my understanding followed the process detailed there to the letter.
I have:
- Created an org (named 1gpPkg) using the environment hub, and registered the namespace
throwaway
. - Created a second org (named devHub) using Environment hub, and enabled it to be the devHub.
- Created a package in 1gpPkg org that is managed containing nothing but the connected app. Named the package OauthCreds
- uploaded a managed and released version of that package. full package name is
throwaway__OauthCreds
- waited an hour for the package to propagate.
- created metadata in force-app/main/default/connectedApps/throwaway__OauthCreds.meta-xml that looks like this:
<ConnectedApp xmlns="http://soap.sforce.com/2006/04/metadata">
<developerName>throwaway__OAuthCreds</developerName>
<label>A Connected App</label>
<version>1.0</version>
</ConnectedApp>
- I tripple checked the package version. it's 1.0 I swear. (insert picard saying there are 4 lights meme)
- Tried to create a new package version of the 2gp package containing the rest of the app.
When I run sfdx force:package:version:create -p MyAppName -x -w 20 -f config/project-scratch-def.json
I get this (useless) message back:
› Warning: Based on feedback from Salesforce Partners, we’re enhancing the package ancestry feature. Starting in Spring ‘22, the
› ancestor version field is required when you create a package version. Look for more details, including how to override the
› ancestry requirement, in the packaging section of the Spring ‘22 Salesforce Release Notes and in the Salesforce DX Developer
› Guide.
Request in progress. Sleeping 30 seconds. Will wait a total of 1200 more seconds before timing out. Current Status='Queued'
Request in progress. Sleeping 30 seconds. Will wait a total of 1170 more seconds before timing out. Current Status='Verifying features and settings'
Request in progress. Sleeping 30 seconds. Will wait a total of 1140 more seconds before timing out. Current Status='Verifying metadata'
ERROR running force:package:version:create: OAuthCreds: Installing an app (OAuthCreds) that has been deleted.
I'm helping a friend who initially submitted a support request about this, but it's been 28 days and 7 escalations without response... Help me SFSE, you're my only hope