c# - Microsoft Bot Framework IDialogContext.Call() not working when using Slack -


i have simple child dialog call in bot using idialogcontext.call(). when user types "new project" following code called:

... context.call(new newprojectdialog(), newprojectconfirmed); ... 

newprojectdialog() asks project name , saves before returning newprojectconfirmed()

[serializable] public class newprojectdialog : idialog<project> {     public async task startasync(idialogcontext context)     {         await context.postasync("what name of project?");         context.wait(this.messagereceivedasync);     }      public virtual async task messagereceivedasync(idialogcontext context, iawaitable<imessageactivity> result)     {         var message = await result;         project p = new project();                 //saving project here...          await context.postasync($"ok. project '{message.text}' created.");         context.done(p);     } } 

when bot called emulator, skype or webchat works expected. user asks new project typing "new project", bot asks name, waits , once project name entered user bot confirms new project creation.

enter image description here

but when call same slack, when user ask new project typing "new project" text "new project" passed newprojectdialog. asks project name, without waiting passes "new project" further , saves name project.

enter image description here

not sure missing. either idialogcontext.wait() works differently slack or call() function seem post message child dialog forward() should.

thanks howdy developers found issue.

it happens when bot has been authorized team, , else comes in , authorizes bot again. when happens, seems there 2 bots running use same rtm connection post channel twice.

i don't know how got 2 bots in same slack client. once removed , reinstalled bot started working expected.

same issue causing other symptom: microsoft bot framework bot duplicate responses in slack


Comments

Popular posts from this blog

resizing Telegram inline keyboard -

command line - How can a Python program background itself? -

php - "cURL error 28: Resolving timed out" on Wordpress on Azure App Service on Linux -