microsoft / BotFramework-Composer

Dialog creation and management for Microsoft Bot Framework Applications
https://docs.microsoft.com/en-us/composer/
MIT License
869 stars 372 forks source link

Generated skill manifest contains non-existing event #8357

Open gabog opened 3 years ago

gabog commented 3 years ago

Describe the bug

I generated a skill manifest for an empty bot and noticed the manifest contains a "Empty event" and there are no events declared for my bot

  "activities": {
    "Empty_2": {
      "type": "event",
      "name": "Empty_2"
    }
  }

Version

Version: 2.0.0-nightly.258070.287a4dc Electron: 8.2.4 Chrome: 80.0.3987.165 NodeJS: 12.13.0 V8: 8.0.426.27-electron.0

To Reproduce

Steps to reproduce the behavior:

  1. Create a bot using the empty template
  2. Configure a publishing profile for the bot so you can publish the manifest
  3. Select export as a skill and enter the required values: image
  4. Select the root dialog in the next screen: image
  5. Don't select any triggers in the next screen: image
  6. Don't add any allowed callers image
  7. Click on generate a publish

It will generate a manifest that looks like this:

{
  "$schema": "https://schemas.botframework.com/schemas/skills/v2.1/skill-manifest.json",
  "$id": "Empty_2-bca6cba5-0f89-400d-bed8-ca604a61ab4b",
  "endpoints": [
    {
      "protocol": "BotFrameworkV3",
      "name": "ComposerBugBash01",
      "endpointUrl": "https://XXXXXXXXXXXXXXXXXXXXXXXX.azurewebsites.net/api/messages",
      "description": "<description>",
      "msAppId": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
    }
  ],
  "name": "Empty_2",
  "version": "1.0",
  "publisherName": "Gabo",
  "activities": {
    "Empty_2": {
      "type": "event",
      "name": "Empty_2"
    }
  }
}

Expected behavior

The generated manifest should not have any events in it, not sure where the one there come from

luhan2017 commented 3 years ago

This is a known issue for R14, @vivekkshankar had a proposal to disable the dialog selection page, but we didn't get a conclusion yet. @cwhitten, Do we want to fix it in R14?

JonathanFingold commented 3 years ago

I've been very frustrated with this workflow. I've never been able to design a skill and publish it in a way that didn't force me to go back and hand edit the manifest. My go to "hello world" test for a skill is to create an echo skill, yet I have to jump through many hoops to get it to work as expected, with a greeting being triggered appropriately when called from another bot.

boydc2014 commented 3 years ago

@luhan2017 can you link the issue with more context or solutions

luhan2017 commented 3 years ago

Here are the list of triggers which are supported/not-supported in composer for now: image

I have following questions which I want to clarify with you:

The above comments are copied from this issue https://github.com/microsoft/BotFramework-Composer/issues/7014

JonathanFingold commented 3 years ago

The confusing bit is that the manifest describes the activities (not the triggers) the skill agrees to receive when a consumer starts a conversation. The primary activities a skill might describe are message, invoke (with the name included), and event (with the name included). Other activity types are allowed by the skills manifest schema.

In theory, one could work backward from a trigger to the activity to add to the manifest, but for event and invoke activities, you'd need to check on additional conditions attached to OnInvoke or OnEvent trigger to capture the relevant name.

vivekkshankar commented 3 years ago

@mareekuh FYI for design backlog