Skip to content

remove: presets and response var - #6195

Merged
sid-bruno merged 4 commits into
usebruno:mainfrom
pooja-bruno:rm/presets-and-response-vars
Dec 2, 2025
Merged

sid-bruno merged 4 commits into
usebruno:mainfrom
pooja-bruno:rm/presets-and-response-vars

Conversation

@pooja-bruno

@pooja-bruno pooja-bruno commented Nov 25, 2025 •

Copy link
Copy Markdown
Collaborator

Description

JIRA

What Changed

  • Presets:

    • Removed Presets tab from Collection Settings
    • Removed preset usage when creating new requests (now defaults to HTTP with empty URL)
  • Post-Response Variables:

    • Removed "Post Response" section from Vars tab (Request, Collection, and Folder levels)
    • Disabled runtime execution of vars.res in both Electron app and CLI

Contribution Checklist:

  • The pull request only addresses one issue or adds one feature.
  • The pull request does not introduce any breaking changes
  • I have added screenshots or gifs to help explain the change if applicable.
  • I have read the contribution guidelines.
  • Create an issue and link to the pull request.

Summary by CodeRabbit

  • Refactor

    • Removed Presets feature from Collection Settings.
    • Removed Post Response variables support across the application. Variable management now focuses exclusively on Pre Request variables.
  • Tests

    • Updated variable persistence tests to reflect simplified variable handling.

✏️ Tip: You can customize this high-level summary in your review settings.

@pooja-bruno
pooja-bruno force-pushed the rm/presets-and-response-vars branch from 77c852d to 67a84a2 Compare November 27, 2025 08:29
sid-bruno
sid-bruno previously approved these changes Dec 2, 2025
@coderabbitai

coderabbitai Bot commented Dec 2, 2025 •

Copy link
Copy Markdown
Contributor

Walkthrough

The changes remove the Presets feature and Post Response variables functionality across the application stack. This includes deletion of the PresetsSettings UI component, StyledWrapper, the Redux updateCollectionPresets action, and all post-response variable aggregation and processing logic from CLI, Electron, and UI components. ActiveVarsCount calculations are simplified to track only request variables.

Changes

Cohort / File(s) Summary
Preset Feature Removal
packages/bruno-app/src/components/CollectionSettings/Presets/StyledWrapper.js, packages/bruno-app/src/components/CollectionSettings/Presets/index.js
Deleted PresetsSettings component and its StyledWrapper UI component entirely. Removes preset radio inputs, URL field, and deprecation warning.
Preset Tab & Logic Removal
packages/bruno-app/src/components/CollectionSettings/index.js, packages/bruno-app/src/components/Sidebar/NewRequest/index.js
Removed Presets tab and related logic; eliminated preset-derived defaulting for requestType and requestUrl; now hardcoded to 'http-request' and empty string.
Redux Action Removal
packages/bruno-app/src/providers/ReduxStore/slices/collections/index.js
Deleted updateCollectionPresets reducer and exported action; removes draft.brunoConfig.presets mutation capability.
Post Response Vars UI Removal
packages/bruno-app/src/components/CollectionSettings/Vars/index.js, packages/bruno-app/src/components/FolderSettings/Vars/index.js, packages/bruno-app/src/components/RequestPane/Vars/index.js
Removed Post Response VarsTable sections, DeprecationWarning imports, and response variable rendering; retained request vars UI only.
Post Response Vars Count Simplification
packages/bruno-app/src/components/FolderSettings/index.js, packages/bruno-app/src/components/RequestPane/HttpRequestPane/index.js
Simplified activeVarsCount to count only enabled request vars; removed response vars aggregation.
Post Response Vars Runtime & CLI Removal
packages/bruno-cli/src/runner/run-single-request.js, packages/bruno-cli/src/utils/collection.js
Deleted post-response variable processing blocks; removed resVars aggregation from collection utility; request.vars.res no longer populated.
Post Response Vars Electron Removal
packages/bruno-electron/src/ipc/network/index.js, packages/bruno-electron/src/utils/collection.js
Removed VarsRuntime.runPostResponseVars execution and IPC updates for response vars; removed resVars aggregation logic.
Test Updates
tests/request/newlines/newlines-persistence.spec.ts
Removed Post Response variable block assertions; simplified DOM selectors and row counting to single Pre Request var entry.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

  • Verify no orphaned imports or calls to removed PresetsSettings, StyledWrapper, or updateCollectionPresets elsewhere in the codebase
  • Confirm activeVarsCount simplification in multiple files doesn't break tab activity indicators or conditional UI
  • Check Redux store—ensure no dispatch calls to deleted updateCollectionPresets action remain
  • Cross-package coordination: verify collection utility changes (bruno-cli and bruno-electron) don't leave broken aggregation paths
  • Validate test coverage adequately reflects removal of Post Response functionality

Poem

✨ The Presets fade and responses rest,
Post variables pack their bags and quest,
Request vars reign supreme and true,
With simpler counts and cleaner view! 🚀

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title directly summarizes the main changes: removal of presets and response variables, which aligns with the comprehensive deletions across UI components, Redux logic, and runtime execution.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Comment @coderabbitai help to get the list of available commands and usage tips.

@sid-bruno
sid-bruno merged commit 786a341 into usebruno:main Dec 2, 2025
@coderabbitai coderabbitai Bot mentioned this pull request Dec 2, 2025
5 tasks
naman-bruno pushed a commit to naman-bruno/bruno that referenced this pull request Dec 2, 2025
sid-bruno added a commit that referenced this pull request Dec 4, 2025
* Partial Revert "remove: presets and response var (#6195)"

This reverts commit 786a341 while keeping code related to presets deleted

* revert: remove global environment variables assignment
maxenceleblanc pushed a commit to maxenceleblanc/curly_cats2 that referenced this pull request Jul 20, 2026
maxenceleblanc pushed a commit to maxenceleblanc/curly_cats2 that referenced this pull request Jul 20, 2026
* Partial Revert "remove: presets and response var (usebruno#6195)"

This reverts commit 7580c50 while keeping code related to presets deleted

* revert: remove global environment variables assignment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants