Skip to content

Recover select.group_by value counts from #1114 - #1129

Merged
ebhills merged 1 commit into
mainfrom
codex/recover-pr-1114-group-by-counts
Aug 14, 2026
Merged

Recover select.group_by value counts from #1114#1129
ebhills merged 1 commit into
mainfrom
codex/recover-pr-1114-group-by-counts

Conversation

@ebhills

@ebhills ebhills commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator

Summary

Recovers the select.group_by counts aggregation from #1114 onto current main. The original PR was accidentally merged into the legacy dev branch; this PR carries only that logical two-file feature and does not merge dev.

What changed

  • Adds a counts aggregation to select.group_by.
  • Returns a dictionary mapping each distinct value to its frequency.
  • Converts dictionary keys to JSON-safe strings.
  • Represents missing values as "null" and booleans as lowercase "true" / "false".
  • Preserves existing per-column output renaming and auto_rename_columns behavior.

Example:

wrangles:
  - select.group_by:
      by: Group
      counts:
        - Selection: Selection Counts
      auto_rename_columns: false

Compatibility and risk

This is an additive aggregation option. Existing select.group_by operations and naming behavior are unchanged.

Validation

  • Complete TestGroupBy class: 30 passed.
  • wrangles/recipe_wrangles/select.py compiles successfully.
  • git diff --check origin/main...HEAD passes.
  • Branch is exactly one commit ahead and zero commits behind current origin/main.

The full repository suite is left to GitHub Actions.

@ebhills
ebhills marked this pull request as ready for review August 14, 2026 20:20
@ebhills
ebhills merged commit 5c3f7bc into main Aug 14, 2026
13 checks passed
@ebhills
ebhills deleted the codex/recover-pr-1114-group-by-counts branch August 14, 2026 20:39
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.

1 participant