There is a bug on the way the Mentions are managed in Skype that is linked to the <at> tag that is added in the text of the message.
When you want to get the text of a message without the recipient mention by calling RemoveRecipientMention, the mention will not be removed from the text.
The following code is used for the demo below:
```C#
var incomingMessage = context.Activity.AsMessageActivity();
var mentionFound = (incomingMessage.Entities?.Where(entity => String.Compare(entity.Type, "mention", ignoreCase: true) == 0).Select(e => e.Properties.ToObject
if (mentionFound != null)
{
await context.PostAsync($"Activity.Text= {incomingMessage.Text}" +
$"\n\nMention.Text= {mentionFound.Text}" +
$"\n\nAfter RemoveRecipientMention()= { incomingMessage.RemoveRecipientMention() }" +
$"\n\n\n\nChannelData= { Newtonsoft.Json.JsonConvert.SerializeObject(incomingMessage.ChannelData).Replace("<", "<").Replace(">", ">") }" +
$"\n\nMention json= {Newtonsoft.Json.JsonConvert.SerializeObject(mentionFound).Replace("<", "<").Replace(">", ">")}"
);
}
```
RemoveRecipientMention() on the messageTextThe Text should not contain the bot name mentioned on Skype when using RemoveRecipientMention() on the message text.
Demo:
Valid on Slack (mention removed successfully):

Invalid on Skype:

The problem seems to be the mismatch between the Activity.Text where the <at> tag is not present and the Mention.Text which contains it.
As a consequence, the method Regex called in RemoveRecipientMention cannot do its work.
I have a doubt on where this bug should be fixed: can you confirm that it is more a Bot Connector problem than on Bot Builder side?
This seems to be an issue with the Node SDK as well. I can not get the bot to work as expected in a group conversation on Skype. The bot recieves messages with the "@botname" prepended and changing the text property of the session/context in a middleware does not help.
Sorry, my bad. I was actually able to strip the mention after all.
Closing the issue assuming it as resolved. Please reopen a new issue if it still persists.
Why should it be resolved without testing and verifying it is?
Please, issues should not be closed if issue is not checked
This is NOT resolved. I can reproduce this issue.
Edit [12 July, 2018]:
Here's more information I've gathered.
This usually happens on UWP Skype. When you first add the bot to your contact. The mention name would be shown as a long string of uuid, something like this: c0074553-463e-4056-ad3b-1d5a51541618. The uuid has not been removed.
After a while, it would sometimes be the bot's resource name. The resources name is also not replaced. It looked something like this: test_AADnLytkwbB3YXKf
This error still occurs on Skype. RemoveRecipientMention does not work as intended.
Any fix?
Thank you for opening an issue against the Bot Framework SDK v3. As part of the Bot Framework v4 release, we鈥檝e moved all v3 work to a new repo located at https://github.com/microsoft/botbuilder-v3. We will continue to support and offer maintenance updates to v3 via this new repo.
From now on, https://github.com/microsoft/botbuilder repo will be used as hub, with pointers to all the different SDK languages, tools and samples repos.
As part of this restructuring, we are closing all tickets in this repo.
For defects or feature requests, please create a new issue in the new Bot Framework v3 repo found here:
https://github.com/microsoft/botbuilder-v3/issues
For Azure Bot Service Channel specific defects or feature requests (e.g. Facebook, Twilio, Teams, Slack, etc.), please create a new issue in the new Bot Framework Channel repo found here:
https://github.com/microsoft/botframework-services/issues
For product behavior, how-to, or general understanding questions, please use Stackoverflow.
https://stackoverflow.com/search?q=bot+framework
Thank you.
The Bot Framework Team
Ok, sorry to read that as this bug is more than a year old and it looks like it will not be fixed.
By the way, for your information, your link about channels is not working (404 not found for https://github.com/microsoft/botbuilder-channels/issues)
Most helpful comment
Why should it be resolved without testing and verifying it is?
Please, issues should not be closed if issue is not checked