SSO Example fails with UnhandledPromiseRejection
See original GitHub issueHello.
I used the following tutorial to create a Outlook-Addin with SSO and Microsoft Graph support enabled.
However, like it is also mentioned on the page, I configured the Addin using this tutorial, creating the entry in Azure AD and everything.
After doing all these steps and running npm, I get the following error message:
[0] [0] > office-addin-taskpane-sso@0.0.0 start:server C:\Desktop\Addin [0] > office-addin-sso start manifest.xml [0] [0] (node:10640) UnhandledPromiseRejectionWarning: false [0] (node:10640) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag
--unhandled-rejections=strict
(see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1) [0] (node:10640) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. [0] npm run start:server exited with code 0
I have followed the tutorial exactly as described, but still the error remains. I am using:
- Windows 10 Build 18363
- Node v12.16.3
- Yeoman v3.1.1
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
- ID: 3020ff5d-ee3b-976b-f1ad-0ed378fdb47b
- Version Independent ID: 5de0010a-6435-154b-a7fd-fd2ea05ebc0b
- Content: Use the Yeoman generator to create an Office Add-in that uses SSO (preview) - Office Add-ins
- Content Source: docs/quickstarts/sso-quickstart.md
- Product: non-product-specific
- Technology: add-ins
- GitHub Login: @o365devx
- Microsoft Alias: o365devx
Issue Analytics
- State:
- Created 3 years ago
- Comments:46 (14 by maintainers)
For anyone that wants to use
.env
file to store the CLIENT_SECRET and doesn’t want to fork the package or run the whole configure-sso script, I made a short script that only does the secret adding into windows credentials part using the ps1 script from the library.Just drop this script into the root of your project and anyone that will clone the project fresh can simply run it with a command like this:
@Chris2011 I created a Microsoft Learning module on this topic… I tried to be a bit more clean than the docs are on this credential store & how it works: https://docs.microsoft.com/en-us/learn/modules/office-add-ins-sso/7-exercise-outlook-sso
Jump down to the section Update project and developer workstation for the POSH (on Windows) or CLI (on macOS) options