FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

feat: add authorship arguments to say_stream by zimeg · Pull Request #1502 · slackapi/bolt-python · GitHub

feat: add authorship arguments to say_stream - #1502

Merged
mwbrooks merged 4 commits into
mainfrom
add-authorship-args-to-say-stream
May 20, 2026
Merged

feat: add authorship arguments to say_stream#1502
mwbrooks merged 4 commits into
mainfrom
add-authorship-args-to-say-stream

Conversation

zimeg commented May 19, 2026
edited
Loading

Copy link
Copy Markdown
Member

Summary

This PR adds icon_emoji, icon_url, and username authorship arguments to SayStream, AsyncSayStream, SetStatus, and AsyncSetStatus helpers to match the new authorship support added in slack_sdk v3.42.0 🚀

Testing

@app.event("assistant_thread_started")
def handle_thread(say_stream, set_status):
    set_status(
        status="thinking...",
        icon_emoji=":maple_leaf:",
        username="Charlie Brown",
    )
    stream = say_stream(icon_emoji=":maple_leaf:", username="Charlie Brown")
    stream.append(markdown_text="Dancing with snoopy dog!")
    stream.stop()

Category

  • slack_bolt.App and/or its core components
  • slack_bolt.async_app.AsyncApp and/or its core components

Requirements

  • I've read and understood the Contributing Guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've run ./scripts/install_all_and_run_tests.sh after making the changes.

zimeg and others added 2 commits May 18, 2026 21:06
The SDK now includes icon_emoji, icon_url, and username in
ChatStream._stream_args. Update assertions to expect these keys.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
Add icon_emoji, icon_url, and username parameters to say_stream()
call, matching the new authorship support in slack_sdk v3.42.0.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
zimeg added enhancement New feature or request area:async area:sync labels May 19, 2026

codecov Bot commented May 19, 2026
edited
Loading

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.30%. Comparing base (3319330) to head (0f85e13).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1502   +/-   ##
=======================================
  Coverage   91.30%   91.30%           
=======================================
  Files         228      228           
  Lines        7271     7271           
=======================================
  Hits         6639     6639           
  Misses        632      632           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Add icon_emoji, icon_url, and username parameters to set_status(),
matching the new authorship support in slack_sdk v3.42.0.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
zimeg self-assigned this May 19, 2026
zimeg marked this pull request as ready for review May 19, 2026 04:31
zimeg requested a review from a team as a code owner May 19, 2026 04:31
zimeg added this to the 1.29.0 milestone May 19, 2026

zimeg commented May 19, 2026

Copy link
Copy Markdown
Member Author

⚡ Similar changes might not be needed in Bolt JS with the subtracted arguments:

https://github.com/slackapi/bolt-js/blob/ba4deb6a8b39da43cef0452d7541bcfcc3f3527a/src/context/create-say-stream.ts#L5

WilliamBergamin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

This looks good 💯

I think I overlooked the assert statements in the original contribution for this, asserting against internal fields can lead to issues, we don't want this to become a pattern in the project 😅

We might want to set up a "mock server" make a request to it using say_stream and capture the arguments 🤔 there might also be a simpler way to do this as well

Comment on lines +40 to +49
"task_display_mode": None,
"icon_emoji": None,
"icon_url": None,
"username": None,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

I think I overlooked how these asserts are expecting internal arguments, if you find a better solution to please contribute it 🙏 We don't want this to become a pattern in the project 😅

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

We might need to set up a mock web server and capture the request sent to it 🤔

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

@WilliamBergamin I'll hold off on merging this to find these preferred patterns! Super appreciate the second thought toward this 🧠 💡

Copy link
Copy Markdown
Contributor

@zimeg I sent a commit on this branch to improve how we test say_stream configurations and not rely on the internals of our dependencies

mwbrooks left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

✅ Thanks for putting this together @zimeg!

mwbrooks merged commit f3eeefe into main May 20, 2026
16 checks passed
mwbrooks deleted the add-authorship-args-to-say-stream branch May 20, 2026 17:42
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL