We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d75db02 commit b6ebeedCopy full SHA for b6ebeed
chaosslack/control.py
@@ -1,7 +1,6 @@
1
import json
2
import os
3
import platform
4
-from secrets import token_hex
5
from typing import Any, Dict, List, Optional
6
7
import yaml
@@ -311,14 +310,15 @@ def send(
311
310
),
312
)
313
elif in_thread and thread_data:
+ state_content = yaml.safe_dump(thread_data or {}, indent=2)
314
r = client.files_upload_v2(
315
- filename=f"{token_hex(8)}.yaml",
316
- channels=channel,
+ channel=current_msg.get("channel"),
317
thread_ts=current_msg.get("ts"),
318
initial_comment=message,
319
- content=yaml.safe_dump(thread_data or {}, indent=2),
+ snippet_type="yaml",
+ content=state_content,
320
+ length=len(state_content),
321
title="state.yaml",
- filetype="yaml",
322
323
elif in_thread:
324
r = client.chat_postMessage(
0 commit comments