slack 메시지 변환하는 부분 작성중
This commit is contained in:
parent
660f85f145
commit
91e986b475
3 changed files with 37 additions and 8 deletions
6
main.py
6
main.py
|
|
@ -50,10 +50,10 @@ def lambda_handler(event: Dict[str, Any], context: Any) -> Dict[str, str]:
|
|||
return PARAM_ERROR
|
||||
menus = menu.menu(param.date)
|
||||
menus_without_img = [ x for x in menus if x.menu_image is None ]
|
||||
if len(menus) == 0:
|
||||
if param.count < MAX_RETRY and (len(menus) == 0 or len(menus_without_img) > 0):
|
||||
return retry(param, lambda_arn, schedule_role_arn)
|
||||
menus_without_img: List[menu.Menu] = [ x for x in menus if x.menu_image is None ]
|
||||
if len(menus_without_img) > 0 and param.count < MAX_RETRY:
|
||||
if len(menus) == 0:
|
||||
# 슬랙 메시지 전송( 오늘의 메뉴 존재 X )
|
||||
return retry(param, lambda_arn, schedule_role_arn)
|
||||
# Extract relevant data for your Slack message (adjust as needed)
|
||||
message_content: str = f"*Important Data from External API*\n"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue