Mattermost-server: slack-compatibility-layer seems to break results of MM-only interactive-message-button response

Created on 2 Mar 2020  路  2Comments  路  Source: mattermost/mattermost-server

Turns out: What happened to slash command responses, #12702 happens to interactive message buttons too :/

So here we go again...

Summary

When replying ephemeral_text as a result of an interactive message button, the slack-compatibility-layer will break the result as same as slash command responses did: #12702

Steps to reproduce

1: create a message with a button.
{"attachments":[{"actions": [{ "name":"text", "integration": {"url": self.URL+"/interactive", "context": {"action": "show_spoiler", "spoiler":" a < a | b > a "}} }] }]}
(full code: https://git.somenet.org/pub/jan/mattermost.git/blob/HEAD:/somebot/modules/CommandSpoiler.py)

2: click on the message button
3: let integration resturn the content of spoiler
4: get displayed a broken response

Expected behavior

Getting a < a | b > a as response.

Observed behavior (that appears unintentional)

Got broken response, see screenshot.

image

Possible fixes

add: "skip_slack_parsing" to PostActionIntegrationResponse and skip slack parsing if true.

I can look into it in the next few days and open a PR...

AreToolkit Help Wanted PR Exists TecGo

Most helpful comment

There you go :)

All 2 comments

Thanks for your interest in submitting a PR for this! I also opened a ticket for our dev team for tracking: https://mattermost.atlassian.net/browse/MM-22825.

There you go :)

Was this page helpful?
0 / 5 - 0 ratings