2017-06-29 12 views
2

私はbotアプリケーションにskypeクライアントを使用しています。 サーバーが最初のメッセージを受信すると、サーバーログに(内部)エラーが見つかりました。Skypeインテグレーションエラー - [TypeError:未定義の 'logger'プロパティを読み取れません]

例コード

var restify = require('restify'); 
var builder = require('botbuilder'); 
var calling = require('botbuilder-calling'); 

//========================================================= 
// Bot Setup 
//========================================================= 

// Setup Restify Server 
var server = restify.createServer(); 
server.listen(process.env.port || process.env.PORT || 3978, function() { 
    console.log('%s listening to %s', server.name, server.url); 
}); 

// Create chat bot 
var chatConnector = new builder.ChatConnector({ 
    appId: process.env.MICROSOFT_APP_ID, 
    appPassword: process.env.MICROSOFT_APP_PASSWORD 
}); 
var chatBot = new builder.UniversalBot(chatConnector); 
server.post('/api/messages', chatConnector.listen()); 

// Create calling bot 
var connector = new calling.CallConnector({ 
    callbackUrl: 'https://<your host>/api/calls', 
    appId: process.env.MICROSOFT_APP_ID, 
    appPassword: process.env.MICROSOFT_APP_PASSWORD 
}); 
var callingBot = new calling.UniversalCallBot(connector); 
server.post('/api/calls', connector.listen()); 

//========================================================= 
// Chat Dialogs 
//========================================================= 
// Add root dialog 
chatBot.dialog('/', function (session) { 
    session.send('Hi... Please call me to interact with me.'); 
}); 

callingBot.dialog('/', function (session) { 
    session.send('Watson... come here!'); 
});; 

私は、このノードのファイル

node app.js 

予想される動作しますが起こることを期待したもの

を実行すると。私はSkypeクライアントはチャットボットからの応答を受信し、callingBotう

実績

は、次のエラーが、私は

bot.use(builder.Middleware.dialogVersion({ version: 1.0, resetCommand: /^reset/i })); 

などを追加し、問題を解決してきました

/home/marcus/advbot/node_modules/botbuilder/node_modules/promise/lib/done.js:10 
     throw err; 
    ^

TypeError: Cannot read property 'logger' of undefined 
    at UniversalBot.Library.findActiveDialogRoutes (/home/marcus/advbot/node_modules/botbuilder/lib/bots/Library.js:135:20) 
    at /home/marcus/advbot/node_modules/botbuilder/lib/bots/Library.js:243:31 
    at /home/marcus/advbot/node_modules/botbuilder/node_modules/async/lib/async.js:718:13 
    at async.forEachOf.async.eachOf (/home/marcus/advbot/node_modules/botbuilder/node_modules/async/lib/async.js:233:13) 
    at _parallel (/home/marcus/advbot/node_modules/botbuilder/node_modules/async/lib/async.js:717:9) 
    at Object.async.parallel (/home/marcus/advbot/node_modules/botbuilder/node_modules/async/lib/async.js:731:9) 
    at /home/marcus/advbot/node_modules/botbuilder/lib/bots/Library.js:241:23 
    at UniversalBot.Library.recognize (/home/marcus/advbot/node_modules/botbuilder/lib/bots/Library.js:68:13) 
    at UniversalBot.Library.defaultFindRoutes (/home/marcus/advbot/node_modules/botbuilder/lib/bots/Library.js:236:14) 
    at UniversalBot.Library.findRoutes (/home/marcus/advbot/node_modules/botbuilder/lib/bots/Library.js:85:18) 
[email protected]:~/advbot/calling$ A 

答えて

1

を発生した期待 私は読んだhttps://github.com/Microsoft/BotBuilder/issues/2846

+0

私はすでにusiだった私のファイルにはこの行のコードがありますが、運とスカイプとFBクライアントは私のABCアカウントで同じエラーを出していますが、別のアカウントで作業していません。 –

関連する問題