Sp-dev-docs: SP REST API for removing an SPFx Solution Package doesn't remove entries from Client Side Component Manifests list

Created on 30 Oct 2019  路  5Comments  路  Source: SharePoint/sp-dev-docs

Category

  • [ ] Question
  • [ ] Typo
  • [x] Bug
  • [ ] Additional article idea

Expected or Desired Behavior

When manually removing an (SPFx) solution package from the tenant app catalog, the Webpart manifests are also removed from the _Client Side Component Manifests_ list.

When using the _PnP PowerShell_ App ALM command-lets to do the same thing, it works as expected, the package is removed and the Webpart manifests are also removed from the _Client Side Component Manifests_ list.

When using the SharePoint REST API to do the same thing (Retract/Remove), I would expect the solution package to be removed and also the Webpart manifests from the _Client Side Component Manifests_ list.

Original issue: https://github.com/pnp/office365-cli/issues/1177

Observed Behavior

When using the SharePoint REST API to Retract & Remove an SPFx solution package using;

https://<appcatalog siteurl>/_api/web/tenantappcatalog/AvailableApps/GetById('<solutionid>')/Remove

the solution package is removed as expected but the Webpart manifests are not removed from the _Client Side Component Manifests_ list.

Steps to Reproduce

Add an SPFx solution package to the tenant app catalog (doesn't matter how this is done), then retract and remove the package using the SharePoint REST API.

csorest bug-confirmed

Most helpful comment

That's odd... good find. I'm able to repro... investigating...

All 5 comments

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

Which PNP command are you referring to exactly? The Retract & Remove methods use the same underlying method that simply calls the same REST API... it doesn't do anything else to clean it up...

@andrewconnell It was the Remove-PnpApp command

After more investigation I've found that if you issue the _Retract_ request, then issue the _Remove_ request, the Webpart manifests _remain_ in the Client Side Component Manifests list.

If you just issue the Remove request, the Webpart manifests are removed from the Client Side Component Manifests list.

I see that the Remove-PnpApp command only issues _Remove_, in the referenced issue https://github.com/pnp/office365-cli/issues/1177, I was using the CLI to _Retract_ then _Remove_, if I change this to only _Remove_, then the solution and Webpart manifests are removed as expected.

This seems like unexpected behaviour, is it a bug?

That's odd... good find. I'm able to repro... investigating...

MSFT say looks buggy...

Was this page helpful?
0 / 5 - 0 ratings

Related issues

nanddeepn picture nanddeepn  路  3Comments

zerovectorspace picture zerovectorspace  路  3Comments

ken-harris picture ken-harris  路  3Comments

SteIvanov picture SteIvanov  路  3Comments

karishmaTCS picture karishmaTCS  路  3Comments