BotFramework-Composer icon indicating copy to clipboard operation
BotFramework-Composer copied to clipboard

duplicate completions in LG editors

Open beyackle opened this issue 6 years ago • 1 comments

Describe the bug

Swapping between tabs in the form editor can cause multiple copies of completions to stack up.

Browser

Edge 80.0

OS

Windows 10

To Reproduce

Steps to reproduce the behavior:

  1. Go to the Bot Composer, and open a bot.
  2. Move to or create an "Ask a Question" box (of any type other than OAuth Login).
  3. Start typing "- if" in the Bot Asks box, and notice that it brings up autocomplete suggestions.
  4. Move to the "Other" tab in the form editor, then back to "Bot Asks".
  5. Start typing "- if" in the box again, and notice that there are now 5 copies of the same one. Moving to Other adds 3 (one for each of the LGEditor boxes there), and then moving back to Bot Asks adds one more.
  6. Note that continuing to switch tabs stacks more and more copies up.

Expected behavior

There should only be one instance of every possible completion no matter how many times we switch tabs.

Screenshots

image

beyackle avatar Mar 31 '20 21:03 beyackle

@a-b-r-o-w-n found an easy fix for this, and I've verified that it works. I'll put up a PR for it.

beyackle avatar Apr 01 '20 19:04 beyackle