Fix(query-builder): avoid dirtying saved queries on execution - #8634
CarolineDenis wants to merge 1 commit into
Conversation
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
📒 Files selected for processing (5)
Included review availability: This review used your included allowance. Your plan provides up to 2 included reviews per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe query execution hook now tracks count-only mode separately from the saved query. The results components use that state to control export-button visibility and determine whether to fetch rows. ChangesQuery Builder Count Mode
Sequence Diagram(s)sequenceDiagram
participant useQueryExecution
participant Wrapped
participant QueryBuilderResults
participant ResultsWrapper
useQueryExecution->>useQueryExecution: Set isCountOnly for the selected mode
Wrapped->>QueryBuilderResults: Pass isCountOnly
QueryBuilderResults->>ResultsWrapper: Pass countOnly
ResultsWrapper->>ResultsWrapper: Resolve count-only mode
Suggested reviewers: Priority: ➖ Normal Change: Bug fix · Severity of issue fixed: Medium Merge Risk: ⚪ Minimal · up to No confirmed issue blocks merging this Query Builder change after normal checks. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to Separating execution mode from saved queries avoids unintended changes without weakening the inspected access checks. Remaining uncertainty concerns mode consistency when an open query is replaced or requests overlap, rather than demonstrated unauthorized access. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
🚥 Pre-merge checks | ✅ 6✅ Passed checks (6 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
rijulpoudel
left a comment
There was a problem hiding this comment.
Testing instructions
- Open or created & save any query
- Run the query
- Click "Batch Edit"
- See batch edit opens
Batch edit opens fine!
JDAM2k4
left a comment
There was a problem hiding this comment.
Testing instructions
- Open or created & save any query
- Run the query
- Click "Batch Edit"
- See batch edit opens
Looks good! I can access batch edit from a query again.
Fixes #8614
Checklist
self-explanatory (or properly documented)
specify7/specifyweb/specify/management/commands/run_key_migration_functions.py
Line 50 in ea04665
Testing instructions
Summary by CodeRabbit