Skip to content

Failed to deploy SPFx with PS Add-PnPApp - getting error Value of: [CSPConfig] cannot exceed: [100000]. #10412

@kat3ryna-vovk

Description

@kat3ryna-vovk

Target SharePoint environment

SharePoint Online

What SharePoint development model, framework, SDK or API is this about?

💥 SharePoint Framework

Developer environment

Windows

What browser(s) / client(s) have you tested

  • 💥 Internet Explorer
  • 💥 Microsoft Edge
  • 💥 Google Chrome
  • 💥 FireFox
  • 💥 Safari
  • mobile (iOS/iPadOS)
  • mobile (Android)
  • not applicable
  • other (enter in the "Additional environment details" area below)

Additional environment details

  • browser version
  • SPFx version
  • Node.js version
  • etc

Describe the bug / error

It's not possible to deploy an SPFx to the site collection App catalog on one of our tenants anymore. It started to fail on 22.09.25 and then any deployment is possible - with PnP PS command Add-PnPApp or with ALM PnP.
"Value of: [CSPConfig] cannot exceed: [100000]."
I assume the problem is with Content Security Policy and Trusted Script Sources that reached 582 entries on this environment. And I can't delete them anymore.

Image From the UI on the Site Collection App Catalog it's possible to deploy an app with 'Deploy' button.

Steps to reproduce

  1. Create SPFx solution
  2. Add & Publish SPFx to Site Collection App Catalog with PnP Powershell:
    Add-PnPApp -Path ./myapp.sppkg -Publish

Expected behavior

Deployment should not fail.

Metadata

Metadata

Assignees

Labels

area:pnp-librariesCategory: PnP Libraries (may be moved to appropriate project repo)sharepoint-developer-supportsharepoint-developer-supporttype:bug-suspectedSuspected bug (not working as designed/expected). See “type:bug-confirmed” for confirmed bugs.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions