Skip to content

The stream argument must implement #<<.#1959

Merged
ioquatix merged 3 commits into
mainfrom
stream-insertion-operator
Aug 31, 2022
Merged

The stream argument must implement #<<.#1959
ioquatix merged 3 commits into
mainfrom
stream-insertion-operator

Conversation

@ioquatix
Copy link
Copy Markdown
Member

This makes it easier to use the stream argument with template systems like ERB, Trenni, etc for real time template streaming/generation.

Copy link
Copy Markdown
Contributor

@jeremyevans jeremyevans left a comment

Choose a reason for hiding this comment

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

I originally thought it would best to only add this restriction on callable bodies (i.e. not for hijack), as that approach would not introduce backwards compatibility issues. However, I guess there is no really issue with also doing so for hijack, and there is an advantage in keeping things consistent between the two (callable bodies operating exactly the same as partial hijack currently).

@ioquatix
Copy link
Copy Markdown
Member Author

I understand. I've deliberately tried to keep rack partial hijack and rack streaming response semantics identical to make it easier for server implementor.

@ioquatix ioquatix merged commit 6aad539 into main Aug 31, 2022
@ioquatix ioquatix deleted the stream-insertion-operator branch August 31, 2022 02:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants