Friday, February 27, 2015

Error occurred in deployment step 'Install app for SharePoint': The provided App differs from another App with the same version and product ID

When you try to debug a SharePoint App from Visual Studio you may receive this error: "Error occurred in deployment step 'Install app for SharePoint': The provided App differs from another App with the same version and product ID" which means that your app is still on SharePoint somehow even if you can't see it in the Site Contents page.

To solve the issue you can check one or all of these steps:

  1. Make sure that the App is removed from the site it is installed to. Go to Site Contents and find if it is there in an error state waiting for you to click on "Try again" to be deleted.
  2. Remove the App from the site collection recycle bin if it is there (by default it will stay in the recycle bin for 93 days). This will move it to the Second-Stage recycle bin if you clicked on "Empty Recycle Bin" and will delete it if you selected the app and clicked on "Delete". (in all cases you will only find the App in the site collection recycle bin but the web site created for the App will be in the Second-Stage recycle bin, so every time you remove an App there will be one part in the first recycle bin and another part in the Second-Stage recycle bin, and restoring any of these parts will restore the other part).
  3. Remove the App from the Second-Stage recycle bin.
  4. If you still can't upload your App, repeat step 2 & 3 :)
  5. If after step #4 you can't upload your App, go to the AppManifest.xml and change the Version (or the ProductID if you are still in the development)
You can get more information about Recycle Bin here : https://support.office.com/en-us/article/Manage-the-Recycle-Bin-of-a-SharePoint-Online-site-collection-5fa924ee-16d7-487b-9a0a-021b9062d14b?ui=en-US&rs=en-US&ad=US