Repository navigation
Conversation
…ormat_library fix: handle `escaped forward slashes` by `fast-json-format` library upgrade
…eadme docs: add farsi translation
…tting fix: update json request and response formatting logic
…-button-in-api-url-bar feat: add stop request button in api url bar
…rt-fails-for-custom-content-types bugfix(usebruno#5939): curl import fails for custom content-types
…fter streaming result
There was a problem hiding this comment.
Pull Request Overview
This pull request adds HTTP streaming support to Bruno, enabling real-time handling of Server-Sent Events (SSE) and other streaming HTTP responses. The implementation includes stream detection, data buffering, UI components for displaying streaming status and data, and proper lifecycle management for streaming connections.
- Stream detection via
text/event-streamcontent-type header and conditional response handling - Real-time stream data display with hexdump visualization and connection lifecycle tracking
- UI enhancements including a stopwatch timer for active streams and visual streaming indicators
Reviewed Changes
Copilot reviewed 13 out of 14 changed files in this pull request and generated 10 comments.
Show a summary per file
| File | Description |
|---|---|
| packages/bruno-electron/src/ipc/network/index.js | Core streaming logic: adds stream detection, promisification helper, response type handling, deferred post-script execution for streams, and collection runner stream support |
| packages/bruno-app/src/utils/network/index.js | Propagates stream information from backend to frontend response objects |
| packages/bruno-app/src/providers/ReduxStore/slices/collections/index.js | Stream state management: handles stream data reception, cancellation with duration calculation, and prevents response clearing for active streams |
| packages/bruno-app/src/providers/App/useIpcEvents.js | Registers IPC event listeners for stream data updates and stream end events |
| packages/bruno-app/src/components/ResponsePane/index.js | Conditionally renders stream message list for streaming responses and adds stopwatch component |
| packages/bruno-app/src/components/ResponsePane/WsResponsePane/WSMessagesList/index.js | Adds proper key prop using timestamp to prevent React warnings |
| packages/bruno-app/src/components/ResponsePane/StatusCode/index.js | Displays "STREAMING" indicator for active stream responses |
| packages/bruno-app/src/components/ResponsePane/ResponseStopWatch/index.js | New component providing real-time duration display for active streams |
| packages/bruno-app/src/components/ResponsePane/ResponseStopWatch/StyledWrapper.js | Styled wrapper for stopwatch component |
| packages/bruno-app/src/components/ResponsePane/ResponseBookmark/index.js | Disables bookmark functionality for streaming responses |
| packages/bruno-app/src/components/RequestTabPanel/index.js | Enables request cancellation when stream is active |
| packages/bruno-app/src/components/RequestPane/QueryUrl/index.js | Shows cancel button for active streams |
| packages/bruno-app/package.json | Adds hexy dependency for hexdump visualization |
| package-lock.json | Lock file update for hexy dependency |
Comments suppressed due to low confidence (4)
packages/bruno-app/src/components/ResponsePane/ResponseBookmark/index.js:16
- Operands !isStreamingResponse and !isStreamingResponse are identical.
if (!isStreamingResponse && !isStreamingResponse) {
packages/bruno-app/src/components/RequestPane/QueryUrl/index.js:8
- Unused import IconX.
import { IconDeviceFloppy, IconArrowRight, IconCode, IconX, IconSquareRoundedX } from '@tabler/icons';
packages/bruno-app/src/components/ResponsePane/ResponseBookmark/index.js:16
- This negation always evaluates to true.
if (!isStreamingResponse && !isStreamingResponse) {
packages/bruno-app/src/components/ResponsePane/ResponseBookmark/index.js:19
- This use of variable 'isStreamingResponse' always evaluates to true.
if (isStreamingResponse) {
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Cleaned up formatting and improved readability of the post-response script execution logic. - Consolidated parameters in function calls for consistency.
* feat: add stop request button in api url bar * docs: add farsi translation * fix: handle escaped forward slashes by fast-json-format library upgrade * refactor: change ui to use one from Websockets * chore: cleanup * fix: lint issues * Replace IconPlayerStop with IconSquareRoundedX * update json request and response formatting logic * chore: format changes * chore: remove un-needed diffs * chore: sanitize * bugfix(usebruno#5939): curl import fails for custom content-types * chore: remove un-needed diffs * chore: enhance response handling for streaming * fix: disable requestid check for tests and assertions to be updated after streaming result * chore: housekeeping * fix: streamline loading and cancel request icon logic * chore: formatting * fix: multiple co-pilot changes * fix: handle in folders * feat: add WaitGroup utility for managing concurrent tasks * refactor: remove WaitGroup utility and clean up network IPC logic * refactor: remove unused setTimeout import and clean up post script execution * refactor: clean up post-response script execution logic * undiff * re-align * refactor: streamline post-response script execution - Cleaned up formatting and improved readability of the post-response script execution logic. - Consolidated parameters in function calls for consistency. * fix: keep original dataBuffer for saving response --------- Co-authored-by: adarshajit <[email protected]> Co-authored-by: sajadoncode <[email protected]> Co-authored-by: lohit-bruno <[email protected]> Co-authored-by: Bijin A B <[email protected]> Co-authored-by: Pragadesh-45 <[email protected]> Co-authored-by: Anoop M D <[email protected]> Co-authored-by: Anoop M D <[email protected]> Co-authored-by: Dawid Góra <[email protected]>
Description
Extends the orginal PR with any needed improvements
Contribution Checklist:
Note: Keeping the PR small and focused helps make it easier to review and merge. If you have multiple changes you want to make, please consider submitting them as separate pull requests.
Publishing to New Package Managers
Please see here for more information.