microsoft / AL

Home of the Dynamics 365 Business Central AL Language extension for Visual Studio Code. Used to track issues regarding the latest version of the AL compiler and developer tools available in the Visual Studio Code Marketplace or as part of the AL Developer Preview builds for Dynamics 365 Business Central.
MIT License
719 stars 242 forks source link

This Extension cannot be published as it has the same App ID and Version as a previously published Extension #7721

Closed RodrigoPuelma closed 2 months ago

RodrigoPuelma commented 2 months ago

Please include the following with each issue:

1. Describe the bug When trying to publish an extension via VS Code to a clean sandbox, I get the following error:

"The request for path [] failed with code UnprocessableEntity. Reason: This Extension cannot be published as it has the same App ID and Version as a previously published Extension."

The sandbox is created in a tenant where the Production environment has current version 23.5.16502.16589 while the sandbox is created with the next version 24.0.16410.17628.

The extension versions are different as we are trying to do some testing for the next version of Business Central. This has never been an issue before.

2. To Reproduce

  1. Create new sandbox environment with version: AU Business Central 24.0 (Platform 24.0.18532.0 + Application 24.0.16410.17628)
  2. Run to publish app.

3. Expected behavior No errors when publishing app via VS Code.

4. Actual behavior Error message: "The request for path [] failed with code UnprocessableEntity. Reason: This Extension cannot be published as it has the same App ID and Version as a previously published Extension."

5. Versions: AU Business Central 24.0 (Platform 24.0.18532.0 + Application 24.0.16410.17628)

Final Checklist

Please remember to do the following:

RodrigoPuelma commented 2 months ago

Update: After removing other sandbox environments and publishing again, I instead get the error below:

Reason: No published extensions match the specified parameter values.

When logging in I can see the extension published but not installed in the extension management. If I try to publish yet again, I continue getting the same error above.

YvesDesrumaux commented 2 months ago

we encounter exactly the same issue.

cghasvi commented 2 months ago

same issue here too

ENDO261985 commented 2 months ago

Same thing happens to me too, even if in the development sandbox you try to load the app with the load extensions. If you compile from vs code the app is only published and not installed and if you do the manual installation operation it works. This is a Microsofts bug.

EmilDamsbo commented 2 months ago

Hello, can you please provide some context on the state of your sandbox as you are trying to publish from VSCode?

  1. Is the currently installed version installed as a global app, a PTE, or a DEV extension?
  2. Does this happen only when publishing from VSCode as a DEV extension, and not via the extension management page?
  3. What happens if you uninstall the currently installed version, then re-install it, and then publish from VScode?

We recommend you to open a support case in order to get the necessary information about your environment. Please refer customer support to this GitHub issue if you do open the support case.

ENDO261985 commented 2 months ago

Hi, if I'm publishing from vs code it means I'm developing on a sandbox, not a PRODUCTION. Even with the loading extensions I have problems, even if I unpublish the app and have a higher version of the app. Business central SAAS 24 wave 1.

cghasvi commented 2 months ago

I did this test to reproduce:

  1. Create new, fresh Sandbox - version 24.0.16410.17628 lang: NO
  2. Create new extension in Visual Code with AL:GO!
  3. Try to publish the new extension to new Sandbox with CTR+F5 or F5
  4. Error in VB Code . failed with code UnprocessableEntity. Reason: Ingen publiserte utvidelser samsvarer med de angitte parameterverdiene. (last part in Norwegian for some reason but same error as stated before)
  5. Extension is published to environment, but not installed
  6. I can install the published extension within BC "Installed Extension" page
  7. Main problem for me is that I cannot debug in version 24 now
KarelKoncel commented 2 months ago

We have same issue from friday and hoping. but we can't even install from extension page. I hope that it will be fixed soon, this is really big error.

RodrigoPuelma commented 2 months ago

Hello, can you please provide some context on the state of your sandbox as you are trying to publish from VSCode?

  1. Is the currently installed version installed as a global app, a PTE, or a DEV extension?
  2. Does this happen only when publishing from VSCode as a DEV extension, and not via the extension management page?
  3. What happens if you uninstall the currently installed version, then re-install it, and then publish from VScode?

We recommend you to open a support case in order to get the necessary information about your environment. Please refer customer support to this GitHub issue if you do open the support case.

Hello,

Thank you for your reply.

  1. The extension is installed from VS Code. The version installed in the PROD is a published, previous version (23).
  2. Impossible to know as I am pushing to a version that is a later version (24) and not available for production (I believe it is today 22/04/2024).
  3. It never gets installed, so there is nothing to uninstall.
  4. I have raised a question in Yammer. Considering no development cant be done by devs there is quite an urgency in having this issue solved.
thloke commented 2 months ago

Hi, we have identified an issue with publishing in BC24 that will cause this. We're currently working on a hotfix and will deploy it to all clusters once ready.

Unfortunately, there is no workaround for this. It's non-deterministic, and eventually retrying will succeed.

RhipeDynamics commented 2 months ago

I'm getting the same issues too.

Suggestion: For deployment use the Extension Management interface Just for Debugging, you can add a configuration for Attach in the launch.json, Example below { "name": "Attach: Microsoft cloud sandbox", "type": "al", "request": "attach", "environmentType": "Sandbox", "environmentName": "sandbox", "breakOnError": "All", "breakOnRecordWrite": "None", "enableSqlInformationDebugger": true, "enableLongRunningSqlStatements": true, "longRunningSqlStatementsThreshold": 500, "numberOfSqlStatements": 10, "breakOnNext": "WebClient" }

cvicq commented 2 months ago

The same issue since 18/04 for me.

cghasvi commented 2 months ago

Thank you @RhipeDynamics . The "attach" workaround is working and helps with debugging.

RDJ202V commented 2 months ago

same issue facing since yesterday and after upgrading app id and version it shows image

StijnBt commented 2 months ago

Same here....

ManishKutar commented 2 months ago

I believe this is the same error -> #7726

nick-webbgh commented 2 months ago

The same issue for me.

bricetaullee commented 2 months ago

Exactly the same issue for me.

frankjanssenwewo commented 2 months ago

Same issue here, right now different/new error: image

ashishsharmainecta commented 2 months ago

Same Issue for me, I am publishing the app as PTE and still it errored with "Deployment failed. Errors: App ID : ** Message : { An app with package ID '' is already published for tenant 'msft1a6720t93294803' } - Job Id : *****" . On extension management it is published, but not installed. Then I am able to install it successfully from there.

tristancliffe commented 2 months ago

Same problem for me, deploying as Dev - never works. Deleted Sandbox and re-copying production, and now THAT is giving similar errors about package IDs already being published...

Very frustrating!

frottke commented 2 months ago

Same issue for us, is there an workaround? That is not acceptable...

JorgeCarlos commented 2 months ago

I already tested this problem in 3 different customer tenants running version 24 and all of them has the same problem. I tested in version 23.5 and there are no issues. I recommend that you don't upgrade to version 24 until this critical issues is fixed. If you need to do an upgrade execute a backup or copy your 23.5 version to a sandbox before an upgrade.

tristancliffe commented 2 months ago

I had a preview environment that worked fine. I initially upgraded our Sandbox to V24 and didn’t have any issues updating extensions via VS Code.

It was only AFTER I committed to V24 on Production that the problem started. I could roll back, but it’s a hassle having to set up external data links and synchronise with online shops that I won’t for something this non-serious.

RhipeDynamics commented 2 months ago

Same issue for us, is there an workaround? That is not acceptable... Workaround: https://github.com/microsoft/AL/issues/7721#issuecomment-2071421265

kalberes commented 2 months ago

@tristancliffe do you have a version number for your preview environment where things have worked?

ENDO261985 commented 2 months ago

23.5 SAAS

tristancliffe commented 2 months ago

@kalberes Erm...

DmitryKatson commented 2 months ago

Same issue for my US saas sandbox environment of v24

tinfisterNP commented 2 months ago

Same issue here, DK 24 sandbox.

ForceSync not working on 24 sandbox. We have tested, it's still working on 23.5 sandbox

PABerrill commented 2 months ago

Same issue in GB 24.0.16410.17628 It was working with preview SaaS sandbox in V24 and V23 is still ok.

developerchristiaens commented 2 months ago

Same issue

jmarinLaberit commented 2 months ago

Also getting the same issue here.

In addition: cannot Copy a Sandbox environment into production (obviously not yet a working company). Resulting production environment has only 'Cronus' and 'My comany' companies. Not the ones in the original sandbox environment.

thegaet commented 2 months ago

Same here

POG2I commented 2 months ago

Same

EBCPKA commented 2 months ago

Same here . After Unpublish the App Extension, (without delete data), i could install the next App version , after this, same error again Deployment failed. Errors: App ID : ***** Message : { An app with package ID 'xxxxxxxxxxxxx' is already published for tenant 'msweua1602t23294033' } - Job Id : 12345-4f8a-44bb-9c81-a88c74f21d3d

CBIZGIT commented 2 months ago

Thanks for placing a notice to acknowledge on AL Home.

Have same issue with VSCode dev, and API PTE /extensionUpload(0)/content

Publish phase succeeds , Install phase gets error... { An app with package ID 'xxxxxxxxxxxxx' is already published for tenant...

Subsequent manual install from extensions page OK.

Affected Sandbox and Production deployments. BC24 and for me BC23.5 following BC24 failed update. (we are GB)

Look forward to fix - Thanks

pratamarendi-apac commented 2 months ago

Alt Solution : for workaround (waiting until stable version) , if on your production still v23, i think u need copy from your production to sandbox then you can continue with v23 until v24 stable or another version that already stable from Microsoft.

frankjanssenwewo commented 2 months ago

Finally this anoying issue made it to Microsofts attention and got "Issue" Status: ;) https://admin.microsoft.com/AdminPortal/Home#/servicehealth/:/alerts/DN784551

frankjanssenwewo commented 2 months ago

It´s alive: https://admin.microsoft.com/AdminPortal/Home#/servicehealth/:/alerts/DN784551 Deployment is on the way, Hopefully completed over the weekend.

EmiPellic commented 2 months ago

Same issue here, and the problem is when you publish an app with dependencies. in that case the workaround doesn't work and also publishing phase is failing: _[2024-04-27 07:26:34.64] The request for path /v2.0/ADVDEMO/dev/apps?tenant=xxxxxxxxxxxxxxxxxxxxxxxxxxxxx&SchemaUpdateMode=forcesync&DependencyPublishingOption=default failed with code UnprocessableEntity. Reason: This Extension cannot be published as it has the same App ID and Version as a previously published Extension.

cghasvi commented 2 months ago

I am now able to publish and debug again

frankjanssenwewo commented 2 months ago

Yeah, seems to work for me, too. I was able to publish and debug from VS Code. Also manual installation of extension via extension management works again. Hope it will last :)

BazookaMusic commented 2 months ago

An update here, as mentioned we are releasing a hotfix for the issue and it has already been partly deployed. We have verified that it works and should soon be deployed everywhere.

We recognize the impact it has had on AL developers and the publishing story and sincerely apologize for the disruption this issue caused. Unfortunately, the root cause was a race condition caused due to a database configuration change. It was an issue that was very hard to debug and reproduce due to appearing only on specific database configurations and only intermittently, which is why it took so long to fix.

We will take steps to avoid such situations in the future by strengthening our testing scenarios and gating such changes more effectively in the future.

BazookaMusic commented 2 months ago

I'm closing the issue as completed since this is an issue with the service itself and not the AL compiler. We will also release an update through the official channels for when the fix is completely deployed

RSMNishant commented 2 months ago

I am still seeing the issue with this reason while publishing from VS code

failed with code UnprocessableEntity. Reason: This Extension cannot be published as it has the same App ID and Version as a previously published Extension.

jackgentle commented 2 months ago

I am still seeing the errors too. I've tried with three of my customers' BC tenants. All the same behavior.

BazookaMusic commented 2 months ago

As mentioned, we are still releasing the hotfix. The issue will be resolved when the hotfix reaches all environments.

cghasvi commented 2 months ago

error: Reason: This Extension cannot be published as it has the same App ID and Version as a previously published Extension.

This could be a side effect of the error that I also got several times. Try incrrease version number in your app.json.

RSMNishant commented 2 months ago

any estimated time frame for hotfix to be deployed.