Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot render Web Chat without store prop #4708

Closed
compulim opened this issue Apr 14, 2023 · 0 comments · Fixed by #4709
Closed

Cannot render Web Chat without store prop #4708

compulim opened this issue Apr 14, 2023 · 0 comments · Fixed by #4709
Labels
bug Indicates an unexpected problem or an unintended behavior. p0 Must Fix. Release-blocker
Milestone

Comments

@compulim
Copy link
Contributor

compulim commented Apr 14, 2023

Is it an issue related to Adaptive Cards?

No

Is this an accessibility issue?

No

What version of Web Chat are you using?

Development build

Which distribution are you using Web Chat from?

Bundle (webchat.js)

Which hosting environment does this issue primarily affect?

Web apps

Which browsers and platforms do the issue happened?

Browser: Edge (latest), Browser: Chrome (latest), Browser: Firefox (latest), Browser: Safari (latest), Browser: IE Mode (latest), Platform: Windows, Platform: macOS, Platform: iOS/iPadOS, Platform: Android

Which area does this issue affect?

Others or unrelated

What is the public URL for the website?

https://compulim.github.io/webchat-loader/

Please describe the bug

When rendering Web Chat with one of the following criteria, it failed:

Do you see any errors in console log?

Browsers without efficient script yielding proposal

webchat-es5.js:2  ReferenceError: clearImmediate is not defined
    at webchat-es5.js:2:291749
    at Object.useMemo (webchat-es5.js:2:3223324)
    at useMemo (webchat-es5.js:2:3283880)
    at c (webchat-es5.js:2:291485)
    at Wo (webchat-es5.js:2:3219785)
    at webchat-es5.js:2:3253054
    at Ba (webchat-es5.js:2:3257044)
    at Ha (webchat-es5.js:2:3257426)
    at Ss (webchat-es5.js:2:3264452)
    at Es (webchat-es5.js:2:3263832)

Without passing store prop

TypeError: Cannot read properties of undefined (reading 'getState')
    at webchat-es5.js:2:171933
    at Object.useMemo (webchat-es5.js:2:3223324)
    at useMemo (webchat-es5.js:2:3283880)
    at $ (webchat-es5.js:2:171851)
    at Wo (webchat-es5.js:2:3219785)
    at webchat-es5.js:2:3253054
    at Ba (webchat-es5.js:2:3257044)
    at Ha (webchat-es5.js:2:3257426)
    at Ss (webchat-es5.js:2:3264452)
    at Es (webchat-es5.js:2:3263832)

How to reproduce the issue?

  1. Navigate to ...
  2. Use the daily build
  3. Open in new window

What do you expect?

Web Chat should render and function normally.

What actually happened?

JavaScript error prevent Web Chat from rendering.

In our test harness, clearImmediate and setImmediate is polyfilled by core-js-pure/internals/task.js, thus, we are not catching it sooner.

Do you have any screenshots or recordings to repro the issue?

Browsers without efficient script yielding proposal

image

Without passing store prop

image

Adaptive Card JSON

No response

Additional context

This is a bug probably introduced by PR #4662.

@compulim compulim added bug Indicates an unexpected problem or an unintended behavior. customer-reported Required for internal Azure reporting. Do not delete. Bot Services Required for internal Azure reporting. Do not delete. Do not change color. p0 Must Fix. Release-blocker and removed customer-reported Required for internal Azure reporting. Do not delete. Bot Services Required for internal Azure reporting. Do not delete. Do not change color. labels Apr 14, 2023
@compulim compulim added this to the imminent milestone Apr 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Indicates an unexpected problem or an unintended behavior. p0 Must Fix. Release-blocker
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant