You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you have a top-level function running locally, and it takes longer than 15 seconds to run, it will be timed out by the Slack backend. However, when running locally, the function process would still be executing. This can lead to odd behaviours.
As soon as the 15 second local timeout is hit, the Slack CLI process / activity logs will output:
2024-06-03 10:07:47 [info] [Fn05HKNRE370] (Trace=Tr0767DPGA69) Function 'Approval' (app function) started
2024-06-03 10:08:03 [error] [Fn05HKNRE370] (Trace=Tr0767DPGA69) Function 'Approval' (app function) failed
event_dispatch_failed
2024-06-03 10:08:03 [error] [Wf05HURTRXTN] (Trace=Tr0767DPGA69) Workflow step 'Approval' failed
2024-06-03 10:08:03 [error] [Wf05HURTRXTN] (Trace=Tr0767DPGA69) Workflow 'Approval Workflow' failed
Function failed to execute
2024-06-03 10:08:03 [error] [Fn05HPEXTU5B] (Trace=Tr0767DPGA69) Function 'Approval Workflow' (workflow function) failed
Function failed to execute
At this point, however, the locally-running function is still executing. The SDK should, instead, kill the function. Otherwise, if the function continues to execute after this point and e.g. tries to return an error or complete the function, you will likely see the following in the CLI output:
functions.completeError response payload: { ok: false, error: "token_revoked" }
💌 We would love to know how things are going
Survey your development experience with slak feedback --name platform-improvements
The CLI process will also hang at this point, forcing the dev to Ctrl+C to kill it. This is likely a CLI bug (you can see the feedback prompt at the end, but the process itself has not completed).
Additionally: the deployed function behaviour / logging / experience will log out the following right after the deployed function times out:
error: function execution exceeded 60.0s timeout
Desired Fixes
It would be good to provide a similar "function executed exceeded X timeout" error message in the local-run experience.
It would be good if we could kill the function after this timeout, then we could eliminate the class of bugs regarding using a revoked token and possibly short circuit the CLI hung process as well.
The text was updated successfully, but these errors were encountered:
Problem
If you have a top-level function running locally, and it takes longer than 15 seconds to run, it will be timed out by the Slack backend. However, when running locally, the function process would still be executing. This can lead to odd behaviours.
As soon as the 15 second local timeout is hit, the Slack CLI process / activity logs will output:
At this point, however, the locally-running function is still executing. The SDK should, instead, kill the function. Otherwise, if the function continues to execute after this point and e.g. tries to return an error or complete the function, you will likely see the following in the CLI output:
The CLI process will also hang at this point, forcing the dev to Ctrl+C to kill it. This is likely a CLI bug (you can see the feedback prompt at the end, but the process itself has not completed).
Additionally: the deployed function behaviour / logging / experience will log out the following right after the deployed function times out:
Desired Fixes
The text was updated successfully, but these errors were encountered: