And terminate it with an ellipsis if the user-provided state string is
too long. (It's a bit annoying that Slack returns an error rather than
just doing this same thing itself, but whatever.)
This satisfies a TODO item since users had encountered this error
during our last hunt.
• Decide a good plan for audio/video calls for puzzles and integrate
that into Turbot.
-• Inspect the CloudWatch logs for our Turbot AWS Lambda during the time
- period of the active hunt, (October 24-31), find and diagnose any
- errors that occurred during that period. Users reported seeing
- "Trouble connecting" (probably during new-puzzle dialog submission)
- as well as "dispatch_failed during /state command (perhaps due to a
- state string that was very long).
-
• Think about some way to express solve priority
Lower priority
if state:
description += " {}".format(state)
+ # Slack only allows 250 characters for a topic
+ if len(description) > 250:
+ description = description[:247] + "..."
+
turb.slack_client.conversations_setTopic(channel=channel_id,
topic=description)