botframework-components icon indicating copy to clipboard operation
botframework-components copied to clipboard

Update Adaptive Card: 'activityId' cannot be null.

Open dawwa opened this issue 3 years ago • 2 comments

Describe the bug

Trying to update a sent Adaptive Card, supplied the Activity Id and confirmed the Activity Id has value. e.g., 1631259369932, however, the update card action throws 'activityId' cannot be null. exception.

image image

Version

2.1.1

Browser

  • [ ] Electron distribution
  • [X] Chrome
  • [ ] Safari
  • [ ] Firefox
  • [X] Edge

OS

  • [ ] macOS
  • [X] Windows
  • [ ] Ubuntu

dawwa avatar Sep 10 '21 07:09 dawwa

@dawwa, First, you probably want to use a property bucket other than turn to store a property. Properties/values assigned to the turn object only last for the duration of the turn and then are cleared. A better option would be to use the dialog bucket.

As for the actual issue, I have been able to repro it. In the Send an Adaptive Card action, I set the Activity ID Property to dialog.setId. Following that, I use Send a response just to verify the id is getting captured. When running, I am able to see the value of the activity id returned in the response. In the Update an existing Adaptive Card action, I tried setting Activity ID to dialog.setId, =dialog.setId, and ${dialog.setId}. However, all instances resulted in the error "Operation returned an invalid status code 'NotFound'".

I will work on getting this assigned to one of the devs so a fix can be worked on and published.

stevkan avatar Sep 16 '21 00:09 stevkan

This is in regards to: https://github.com/microsoft/botframework-components/tree/main/packages/AdaptiveCards

GitHub
The repository for components built by Microsoft for the Azure Bot Framework. - botframework-components/packages/AdaptiveCards at main · microsoft/botframework-components

dmvtech avatar Sep 16 '21 16:09 dmvtech