Document on_output option in Bash.run/3 - #9
Merged
dbernheisel merged 1 commit intoApr 12, 2026
Conversation
The on_output streaming callback was supported through opts passthrough to Session.execute/3 but not documented in the Bash.run/3 docstring. Add it to the options list with a usage example.
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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Bash.run/3passes opts through toSession.execute/3, which supports:on_outputfor streaming output as it's produced. The streaming works, butBash.run/3's docstring doesn't mention it. The only documentation for:on_outputis onSession.execute/3directly. Users of the convenience API have no way to know streaming is available without diving into internals, which leads to bypassingBash.run/3entirely and callingBash.parse/1+Bash.Session.execute/3directly.Requirements
:on_outputtoBash.run/3's@docas a supported option, with the same description asSession.execute/3.on_outputis intentionally unsupported throughrun/3, document that and raise if passed.Validations
Purely a documentation change — the code already works.