wmill 1.441.1__tar.gz → 1.442.0__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {wmill-1.441.1 → wmill-1.442.0}/PKG-INFO +1 -1
- {wmill-1.441.1 → wmill-1.442.0}/pyproject.toml +1 -1
- {wmill-1.441.1 → wmill-1.442.0}/wmill/client.py +11 -0
- {wmill-1.441.1 → wmill-1.442.0}/README.md +0 -0
- {wmill-1.441.1 → wmill-1.442.0}/wmill/__init__.py +0 -0
- {wmill-1.441.1 → wmill-1.442.0}/wmill/py.typed +0 -0
- {wmill-1.441.1 → wmill-1.442.0}/wmill/s3_reader.py +0 -0
- {wmill-1.441.1 → wmill-1.442.0}/wmill/s3_types.py +0 -0
@@ -9,6 +9,7 @@ import os
|
|
9
9
|
import random
|
10
10
|
import time
|
11
11
|
import warnings
|
12
|
+
import json
|
12
13
|
from json import JSONDecodeError
|
13
14
|
from typing import Dict, Any, Union, Literal
|
14
15
|
|
@@ -629,6 +630,8 @@ class Windmill:
|
|
629
630
|
channel_id: str,
|
630
631
|
message: str = None,
|
631
632
|
approver: str = None,
|
633
|
+
default_args_json: dict = None,
|
634
|
+
dynamic_enum_json: dict = None,
|
632
635
|
) -> None:
|
633
636
|
"""
|
634
637
|
Request interactive Slack approval
|
@@ -657,6 +660,10 @@ class Windmill:
|
|
657
660
|
params["channel_id"] = channel_id
|
658
661
|
if os.environ.get("WM_FLOW_STEP_ID"):
|
659
662
|
params["flow_step_id"] = os.environ.get("WM_FLOW_STEP_ID")
|
663
|
+
if default_args_json:
|
664
|
+
params["default_args_json"] = json.dumps(default_args_json)
|
665
|
+
if dynamic_enum_json:
|
666
|
+
params["dynamic_enum_json"] = json.dumps(dynamic_enum_json)
|
660
667
|
|
661
668
|
self.get(
|
662
669
|
f"/w/{workspace}/jobs/slack_approval/{os.environ.get('WM_JOB_ID', 'NO_JOB_ID')}",
|
@@ -1018,12 +1025,16 @@ def request_interactive_slack_approval(
|
|
1018
1025
|
channel_id: str,
|
1019
1026
|
message: str = None,
|
1020
1027
|
approver: str = None,
|
1028
|
+
default_args_json: dict = None,
|
1029
|
+
dynamic_enum_json: dict = None,
|
1021
1030
|
) -> None:
|
1022
1031
|
return _client.request_interactive_slack_approval(
|
1023
1032
|
slack_resource_path=slack_resource_path,
|
1024
1033
|
channel_id=channel_id,
|
1025
1034
|
message=message,
|
1026
1035
|
approver=approver,
|
1036
|
+
default_args_json=default_args_json,
|
1037
|
+
dynamic_enum_json=dynamic_enum_json,
|
1027
1038
|
)
|
1028
1039
|
|
1029
1040
|
@init_global_client
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|