Skip to content

Query Records Refactor Architecture Review & Frappe Native Capability Alignment#277

Open
Sendipad wants to merge 1 commit into
frappe-api-investigation-4618067210051392575from
jules-18303454897825349676-e2d021d3
Open

Query Records Refactor Architecture Review & Frappe Native Capability Alignment#277
Sendipad wants to merge 1 commit into
frappe-api-investigation-4618067210051392575from
jules-18303454897825349676-e2d021d3

Conversation

@Sendipad

Copy link
Copy Markdown
Owner

This secondary engineering review addresses the Query Records refactor architecture alignment. It compares the previous migration proposal against native Frappe v15+ APIs and outlines a design that minimizes custom FlexiRule logic and maximizes reuse of Frappe's native capabilities.

Key Alignments Identified:

  1. Filter Normalization: Move dotted key parsing responsibility completely to the frontend config layer, generating standard native 4-value Frappe filter formats at configuration time rather than recreating recursive metadata parsers in the backend execution path.
  2. Child Table Queries: Leverage native frappe.get_list(..., parent_doctype=X) instead of implementing parent discovery inside the backend execution path.
  3. DISTINCT: Pass distinct=True directly to get_list() from the frontend toggle without custom backend deduplication logic.
  4. Aggregates: Secure aggregate evaluations under user context by replacing get_all with get_list and setting limit_page_length=0, avoiding manual backend permission wrappers.
  5. Separation of Concerns: Maintain a clear boundary between UI configuration, runtime context variable resolution, and SQL generation.

PR created automatically by Jules for task 18303454897825349676 started by @Sendipad

Created the secondary engineering review report 'reports/query_records_architecture_alignment.md' identifying redundant/duplicated code patterns and aligning FlexiRule's Query Records action handler with native Frappe Framework v15+ capability.
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

1 participant