Comments (8)
You mentioned data.address
a few times in the event handler, but it doesn't look like that's defined in the activity sent, which should be the source of the immediate issue from the looks of things.
That said, I'll take a look into why the callback is not returning the error out of loadSession
from botbuilder-v3.
@nyxsys as the activity enters the bot it has some additional data/properties, one of which is the address property (implementing the botbuilder IAddress interface). Here is an example of a data object:
{
"type":"event",
"timestamp":"2018-11-03T08:47:30.4687371Z",
"name":"connect",
"text":"",
"attachments":[],
"entities":[],
"address":{"id":"6uhHKBSxVUC13WBYlzrJGR|0000000","channelId":"webchat","user":{"id":"Agent01","name":"Agent01"},"conversation":{"id":"6uhHKBSxVUC13WBYlzrJGR"},"bot":{"id":<botId>,"name":<botNAme>},"serviceUrl":"https://directline.botframework.com/"},
"source":"webchat",
"agent":"botbuilder",
"user":{"id":"Agent01","name":"Agent01"}
}
from botbuilder-v3.
For the moment I'm setting up a PR to at least add a try catch for error handling to the location that should throw the exception. I am going to dig deeper and try and find out why this is occurring at all after that.
from botbuilder-v3.
So the error "Cannot read property 'loadSessionWithOptionalDispatch' of undefined"
suggests that something is wrong with the initialization of the universal bot. Could you post your code where you initialize the bot
itself so I can see if anything there could do it? Additionally do the other methods from universal bot like send
work at this point in your bot?
from botbuilder-v3.
This is the code:
const bot = new builder.UniversalBot(connector)
.set('localizerSettings', {
botLocalePath: path.join(process.cwd(), 'locale'),
defaultLocale: 'en'
})
.set('persistConversationData', true)
.set('autoBatchDelay', 0)
.set('storage', new builder.MemoryBotStorage());
I've used other methods (like send
, on
, beginDialog
...) and everything works. loadSession
is the only exception.
PS. If there was something wrong with the bot
it would never even trigger the event
and enter the handler.
from botbuilder-v3.
I tried bot.loadSession
on a bot on the same version of botbuilder you've listed in three locations. bot.on()
as well as bot.dialog()
and bot.use()
but I have not been able to recreate the error you are seeing, both with and without including the same bot.set() config calls you've posted. Could you try and see if you get a different result out of putting the bot.loadSession()
call into middleware using bot.use()
?
If that doesn't work, it might be good to see if you could put together a minimum version of your bot that can reproduce this issue.
from botbuilder-v3.
@filipjakov, have you tried the suggestion from @nyxsys or is the issue resolved? Thx.
from botbuilder-v3.
Closing as resolved not repro
from botbuilder-v3.
Related Issues (20)
- Link to BotBuilder example is not available anymore HOT 1
- POST to 'https://facebook.botframework.com/v3/conversations/9838851111469094-906008411166152/activities/lOdKu9yrLed5iyVk3vbBaQJ5mCJPyp12345678fd2Ta0xQ3R_I12345678pmlNxrQ' failed: [400] Bad Request HOT 9
- Hostname/IP does not match certificate's altnames HOT 34
- Question: Will bot services (written with NodeJS SDK v3.14, using DirectLine v3 APIs) stop working after Dec 31, 2019? HOT 2
- Error: Refresh access token failed with status code: 400 HOT 3
- problem when try to call an another Rest-api at Botframework-V3+C#.net HOT 2
- MessageReceivedAsync will not get called sometimes HOT 7
- Extend v3 SDK to support Skills (DotNet) HOT 3
- Extend v3 SDK to support Skills (JS) HOT 1
- Enable SignIn from a Skill HOT 1
- IDialog method execution finished with multiple resume handlers specified through IDialogStack. invalid need: expected Call, have Wait (Microsoft.Bot.Builder.Internals.Fibers.InvalidNeedExceptio) HOT 18
- Microsoft.Bot.Builder - "Object reference not set to an instance of an object" HOT 5
- [Question, bug] Bot framework fails to save state to Doc DB in Teams 1:1 conversation (and errors dialogue) HOT 8
- Message card rendering issue in bot framework v3 HOT 14
- Port: "Enable multiple scopes for single serviceUrl host" to javascript v3 sdk HOT 1
- Can we send adaptive card to particular group instead of channel HOT 1
- How can get Activity after user submit action in adaptive card using java HOT 1
- System.ArgumentNullException: Value cannot be null. (Parameter 'clientId') in bot V 3.30.0 HOT 1
- Data breach observed when two concurrent send message requests are made to different tenants HOT 8
- This repo is missing important files
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from botbuilder-v3.