Skip to content

Honor the no_aggs parameter when searching#248

Merged
chosak merged 1 commit into
mainfrom
fix/honor-no-aggs
Jul 21, 2026
Merged

Honor the no_aggs parameter when searching#248
chosak merged 1 commit into
mainfrom
fix/honor-no-aggs

Conversation

@chosak

@chosak chosak commented Jul 21, 2026

Copy link
Copy Markdown
Member

The search API includes a "no_aggs" parameter which is supposed to determine whether aggregations are included in the output, but it is currently ignored.

The API accepts that parameter and validates it, but ignores it. Aggregations are always computed, no matter what. Computing aggregations is an expensive part of the search, and requires grouping every complaint by company, issue, and sub-issue.

This change properly checks no_aggs before adding aggregations to the search query.

The search API includes a "no_aggs" parameter which is supposed to
determine whether aggregations are included in the output, but it is
currently ignored.

The API accepts that parameter and validates it, but ignores it.
Aggregations are always computed, no matter what. Computing aggregations
is an expensive part of the search, and requires grouping every
complaint by company, issue, and sub-issue.

This change properly checks no_aggs before adding aggregations to the
search query.

@higs4281 higs4281 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

A great catch.

@chosak
chosak merged commit 885ba0d into main Jul 21, 2026
2 checks passed
@chosak
chosak deleted the fix/honor-no-aggs branch July 21, 2026 19:25
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.

2 participants