OfficeDev / office-js-docs-pr

Microsoft Office Add-ins Documentation
https://learn.microsoft.com/office/dev/add-ins
Creative Commons Attribution 4.0 International
399 stars 246 forks source link

SSO quick start has confusing unnecessary sideloading step #4688

Open Rick-Kirkham opened 1 month ago

Rick-Kirkham commented 1 month ago

In SSO quick start

The Outlook subheading of the Test your add-in header: Step 1 has the user run npm start. Step 2 tells the user to go to another article and sideload the add-in. This is not necessary. The npm start command sideloads the add-in.

image

AlexJerabek commented 1 month ago

@Rick-Kirkham,

I just tried running this quick start with the unified manifest. Running npm start produced the following errors:

--Error sideloading!--
Error: Error: Command failed: npx @microsoft/teamsapp-cli install --file-path "C:\Users\aljerabe\AppData\Local\Temp\manifest.zip"
(×) Error: M365.PackageServiceError: Request failed with status code 400 (tracingId: 00-9e85307771ef5a9990285633fb1ac6ea-16ea057f657f02c1-01) BadRequest: Manifest is not valid: [
  "String '{application GUID here}' does not match regex pattern '^[0-9a-fA-F]{8}-([0-9a-fA-F]{4}-){3}[0-9a-fA-F]{12}$'. Path 'webApplicationInfo.id', line 40, position 39."
]

STDERR:
(×) Error: M365.PackageServiceError: Request failed with status code 400 (tracingId: 00-9e85307771ef5a9990285633fb1ac6ea-16ea057f657f02c1-01) BadRequest: Manifest is not valid: [
  "String '{application GUID here}' does not match regex pattern '^[0-9a-fA-F]{8}-([0-9a-fA-F]{4}-){3}[0-9a-fA-F]{12}$'. Path 'webApplicationInfo.id', line 40, position 39."
]

Error: Unable to start debugging.
Error: Unable to sideload the Office Add-in.
Error: Command failed: npx @microsoft/teamsapp-cli install --file-path "C:\Users\aljerabe\AppData\Local\Temp\manifest.zip"
(×) Error: M365.PackageServiceError: Request failed with status code 400 (tracingId: 00-9e85307771ef5a9990285633fb1ac6ea-16ea057f657f02c1-01) BadRequest: Manifest is not valid: [
  "String '{application GUID here}' does not match regex pattern '^[0-9a-fA-F]{8}-([0-9a-fA-F]{4}-){3}[0-9a-fA-F]{12}$'. Path 'webApplicationInfo.id', line 40, position 39."
]
Rick-Kirkham commented 1 month ago

@AlexJerabek That's a side effect of one of the problems I've always had with the SSO templates and why I questioned a few months ago whether we should keep them. The generated project can't really be used unless the developer is working through the SSO quick start. In that quick start they find out that there is a step you have to take before you run npm start: you have to run npm run configure-sso first.

AlexJerabek commented 1 month ago

@Rick-Kirkham, Gotcha! Thank you for the clarification. So much for testing this without a test account :-)