Skip to content

SPFx Extension app package periodically fails to load JavaScript files #3802

@sionjlewis

Description

@sionjlewis

Category

  • [] Question
  • Bug
  • [] Enhancement

Expected or Desired Behavior

SPFx Extension to load when page is requested.
Steps:

  • Upload SPFx Extension to the App Catalog and select Tenant wide deployment
  • Run the Add-PnPCustomAction PowerShell CommandLet (for a specific site)
  • Load a modern site page ALL OK

Observed Behavior

The SPFx Extension will load OK for weeks and then "out of the blue" if fails with errors like:

GET https://[tenent].sharepoint.com/sites/apps/ClientSideAssets/[guid]/extention-name-application-customizer_[guid].js net: ERR_ABORTED 404
HEAD https://[tenent].sharepoint.com/sites/apps/ClientSideAssets/[guid]/extention-name-sp-page-assembly_[guid].js 404

Steps to Reproduce

Not sure how we can reproduce this problem?

  • The problem:
    • Occur generally on or just after a Tuesday (New Zealand time)
    • Occurs for multiple tenants, but generally not all at the same time
    • Affect all SPFx Extensions (when it happens)
    • Does not affect SPFx Webparts
  • The JavaScript files appears to be from an older versions of the App Package (we have started a log to confirm this assumption)
  • When an error occurs, the SPFx Extension does not load
  • Opening the Browser Console locate the error:
    • Copy and past the JavaScript's URL into a browser window will also show a 404 error
    • Remove the File name & extension from the URL will open the container folder (no errors)
  • This may not be an SPFx Extension bug but rather an Office 365 update issue?

Possible solution:

I assume the GUIDs used within the file names as for cache-busting purposes. Why not remove the GUID from file name and apply it to the requesting code as a query string parameter?

Ideas and suggestions are welcome :)

#sp-dev-fx-extensions

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs: Attention 👋Original poster responded to request for feedback, awaiting attention from Microsoft / community.area:cdnCategory: Office 365 Content Delivery Networkarea:spfxCategory: SharePoint Framework (not extensions related)area:spfx-extensionsCategory: SharePoint Framework Extensionsstatus:trackedCurrently tracked with Microsoft’s internal issue tracking system. DO NOT ADD/REMOVE (MSFT managed)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions