node-slack-sdk icon indicating copy to clipboard operation
node-slack-sdk copied to clipboard

cli-test(fix): wait for cli run start trace instead of activity output

Open zimeg opened this issue 4 months ago • 3 comments

Summary

This PR uses SLACK_TRACE_PLATFORM_RUN_START variable as a signal of an active running app instead of the exact output:

Connected, awaiting events

Fixes an issue where bolt apps were not detected as running.

Requirements

zimeg avatar Aug 28 '25 22:08 zimeg

Codecov Report

:white_check_mark: All modified and coverable lines are covered by tests. :white_check_mark: Project coverage is 92.77%. Comparing base (06a3dcf) to head (6f90edf). :white_check_mark: All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2355   +/-   ##
=======================================
  Coverage   92.77%   92.77%           
=======================================
  Files          39       39           
  Lines       10693    10693           
  Branches      692      692           
=======================================
  Hits         9920     9920           
  Misses        761      761           
  Partials       12       12           
Flag Coverage Δ
cli-hooks 95.23% <ø> (ø)
cli-test 94.80% <100.00%> (ø)
oauth 77.39% <ø> (ø)
socket-mode 61.87% <ø> (ø)
web-api 97.99% <ø> (ø)
webhook 96.66% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

:rocket: New features to boost your workflow:
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Aug 28 '25 22:08 codecov[bot]

LGTM! Like the more reliable detection of running Slack apps 👏 👏

ewanek1 avatar Aug 29 '25 16:08 ewanek1

@ewanek1 @mwbrooks Thanks both for the kind reviews. And never worries on a rushed review for this! 👾

Just checking if I understand correctly - are you thinking that the CLI would print the SLACK_TRACE_PLATFORM_RUN_READY trace for sdk-managed socket connections?

Exactly this! I'm not finding such printed at this time, but I'm also not sure if that'd be possible to know for SDK managed connections...

Somewhat following that, I'm hesitant to release this change since it might disrupt our E2E tests if workflows are started after "PLATFORM_RUN_START" and before "PLATFORM_RUN_READY" but we can perhaps wait for the second trace in an explicit step?

zimeg avatar Sep 18 '25 19:09 zimeg