OfficeDev / OfficeDev/Office-Addin-Scripts
office-addin-sso configure error
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 194
- Forks
- 117
- Avg merge
- 1d 32m
- Merged PRs (30d)
- 2
Description
Expected behavior
npm run configure-sso works.
Current behavior
Using Yeoman and generator-office I scaffold an Office addin
? Choose a project type: Office Add-in Task Pane project supporting single sign-on
? Choose a script type: (Use arrow keys)
? Choose a script type: TypeScript
? What do you want to name your add-in? foobar
? Which Office client application would you like to support? Outlook
Calling npm run configure-sso yields the following:
npm WARN config global `--global`, `--local` are deprecated. Use `--location=global` instead.
> office-addin-taskpane-sso@0.0.0 configure-sso
> office-addin-sso configure manifest.xml
Opening browser for authentication to Azure. Enter valid Azure credentials
Login was successful!
Registering new application in Azure
Application was successfully registered with Azure
Setting identifierUri
Attempt 1
Itendifier Set
Setting signin audience
Attempt 1
Sign In Audience Set
undefined:35
"displayName": "���� �\�Y",
^
SyntaxError: Unexpected token � in JSON at position 1189
at JSON.parse (<anonymous>)
at C:\Users\christian\Dev\Cotoha\yo\foobar\node_modules\office-addin-sso\lib\configure.js:185:40
at Generator.next (<anonymous>)
at C:\Users\christian\Dev\Cotoha\yo\foobar\node_modules\office-addin-sso\lib\configure.js:7:71
at new Promise (<anonymous>)
at __awaiter (C:\Users\christian\Dev\Cotoha\yo\foobar\node_modules\office-addin-sso\lib\configure.js:3:12)
at C:\Users\christian\Dev\Cotoha\yo\foobar\node_modules\office-addin-sso\lib\configure.js:179:95
at ChildProcess.exithandler (node:child_process:390:7)
at ChildProcess.emit (node:events:527:28)
at maybeClose (node:internal/child_process:1092:16)
Steps to Reproduce
Please provide detailed steps for reproducing the issue.
- install yo and generator-office
- scaffold project with the options above
- run
npm run configure-soo
Context
I am assuming that this error occurs while checking if I am a tenant admin.
It looks to me like an encoding problem. I am not sure what "displayName" the error above refers to,
but I assume it is my name from AAD.
That name contains Japanese characters (Katakana).
- Operating System: Windows 10 21H2 Japanese with English language pack
- Node version: 16.15.1
- Office version: MS365 Apps for Enterprise 2205 build
- Tool version:
- office-addin-sso@1.2.11
- azure-cli 2.37.0
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the failure with the stated Yeoman scaffold and npm run configure-sso command, then inspect node_modules/office-addin-sso/lib/configure.js around line 185 and the Azure CLI output. Done means the configure-sso flow completes and handles the Japanese displayName without the JSON.parse encoding error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, node.js, typescript
- Domain
- authentication, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100