semantic-kernel icon indicating copy to clipboard operation
semantic-kernel copied to clipboard

copilot-chat-app sample deosnt work (Cannot read properties of undefined (reading 'title'))

Open kborowiec-mag opened this issue 2 years ago • 1 comments

Describe the bug After star of WebApp - yarn start. Application returns in browser:

Cannot read properties of undefined (reading 'title') TypeError: Cannot read properties of undefined (reading 'title') at ChatWindow (http://localhost:3000/static/js/bundle.js:1648:46) at renderWithHooks (http://localhost:3000/static/js/bundle.js:181908:22) at mountIndeterminateComponent (http://localhost:3000/static/js/bundle.js:185194:17) at beginWork (http://localhost:3000/static/js/bundle.js:186490:20) at HTMLUnknownElement.callCallback (http://localhost:3000/static/js/bundle.js:171500:18) at Object.invokeGuardedCallbackDev (http://localhost:3000/static/js/bundle.js:171544:20) at invokeGuardedCallback (http://localhost:3000/static/js/bundle.js:171601:35) at beginWork$1 (http://localhost:3000/static/js/bundle.js:191475:11) at performUnitOfWork (http://localhost:3000/static/js/bundle.js:190722:16) at workLoopSync (http://localhost:3000/static/js/bundle.js:190645:9)

To Reproduce Steps to reproduce the behavior:

  1. Go to (https://github.com/microsoft/semantic-kernel/tree/main/samples/apps/copilot-chat-app)
  2. Follow instruction
  3. Start webAPP with yarn start'
  4. See error

Expected behavior Sample works as described

Screenshots image

kborowiec-mag avatar Apr 17 '23 13:04 kborowiec-mag

If you are running the webapi already, please try switching the useHttp config flag in appsettings.json (then restart we api).

we may have a default mismatch between the scheme (http/https) that gives a poor first run experience

craigomatic avatar Apr 17 '23 16:04 craigomatic

This should now be fixed with PR #497

This was due to a superfluous scope being requested in auth.

Please try again with the latest from main and the problem should be gone. You may have to clear your cache in order for the fix to be effective.

glahaye avatar Apr 18 '23 02:04 glahaye

@glahaye it works like a charm! Thank you for your help!

kboro avatar Apr 18 '23 08:04 kboro