question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error: DirectLineJS: It is connected, we cannot set user id.

See original GitHub issue

Screenshots

image

Version

<meta name="botframework-directlinespeech:version" content="4.12.1">
<meta name="botframework-webchat:bundle:variant" content="full">
<meta name="botframework-webchat:bundle:version" content="4.12.1">
<meta name="botframework-webchat:core:version" content="4.12.1">
<meta name="botframework-webchat:ui:version" content="4.12.1">

Describe the bug

Just updated from 4.10.1 to 4.12.1 Before the update we could pass userID into the ReactWebChat and in 4.12 we can call setUserID on the DirectLine object aswell. Doing both, either or neither of those, results in the error.

Steps to reproduce

  1. Make a class that extends React.Component
  2. In the render method return a ReactWebChat with relevant props: image

Expected behavior

No error.

Additional context

This error may be due to idiosyncrasy but I’d like to get to the bottom of that if it’s the case.

[Bug]

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:15 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
stevkancommented, Apr 9, 2021

@felixvanleeuwen, I spoke with a member of the Web Chat team and it was recommended that you try assigning the userId via the method shown here.

They were also wondering if you are passing in the userId with the secret with generating a token from the Direct Line API call. As I don’t remember from our online call, can you tell me if this is happening or not?

0reactions
stevkancommented, Apr 16, 2021

Closing due to inactivity. If the problem persists or you have new details to provide, please feel free to reopen the issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Using WebChat with Azure Bot Service's Authentication
This blog covers how to use Web Chat with the Azure Bot Service's built-in authentication capability to authenticate chat users with various ...
Read more >
botframework-directlinejs - npm
Client library for the Microsoft Bot Framework Direct Line 3.0 protocol. Latest version: 0.15.1, last published: 9 months ago.
Read more >
Direct Line Authentication in Azure Bot Service - Microsoft Learn
Azure Bot Service authentication enables you to authenticate users to and get access tokens from various identity providers such as Azure Active ...
Read more >
directline connection role and name not getting in BOT ...
You 're not getting a ConversationUpdate for the user, just the bot. You need to send a ConversationUpdate manually: const store = window....
Read more >
Botframework-directlinejs - npm.io
FAQ. Who is this for? Anyone who is building a Bot Framework JavaScript client who does not want to use WebChat. If you' ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found