Skip to content

Write binary to stdout buffer#16

Merged
ymarcon merged 14 commits intomasterfrom
bugfix/accept-binary
Dec 12, 2025
Merged

Write binary to stdout buffer#16
ymarcon merged 14 commits intomasterfrom
bugfix/accept-binary

Conversation

@kazoompa
Copy link
Member

No description provided.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds support for writing binary (non-JSON) responses directly to stdout's buffer, allowing the REST command to handle file downloads and other binary content types. Previously, the code only handled JSON responses.

Key Changes:

  • Added conditional logic to check the accept header and route binary responses to sys.stdout.buffer.write()
  • Preserved existing JSON response handling with formatting options

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@kazoompa kazoompa force-pushed the bugfix/accept-binary branch 2 times, most recently from 5f88a4f to 00ec66c Compare December 11, 2025 17:01
@kazoompa kazoompa requested a review from ymarcon December 11, 2025 17:06
@kazoompa kazoompa closed this Dec 11, 2025
@kazoompa kazoompa reopened this Dec 11, 2025
@ymarcon ymarcon merged commit e0f32a6 into master Dec 12, 2025
9 of 15 checks passed
@kazoompa kazoompa deleted the bugfix/accept-binary branch December 12, 2025 11:20
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.

3 participants