Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Sort lists before calling itertools.groupby #1997

Merged
merged 1 commit into from
Jul 27, 2024

Conversation

cogk
Copy link
Contributor

@cogk cogk commented Jul 22, 2024

itertools.groupby returns consecutive groups only when the keys are consecutive. An input of aBaB will create 4 groups, not 2.

https://docs.python.org/3/library/itertools.html#itertools.groupby
https://stackoverflow.com/a/7286

@ruchamahabal ruchamahabal merged commit 0265ca9 into frappe:develop Jul 27, 2024
8 checks passed
mergify bot pushed a commit that referenced this pull request Jul 27, 2024
mergify bot pushed a commit that referenced this pull request Jul 27, 2024
ruchamahabal pushed a commit that referenced this pull request Jul 27, 2024
)

(cherry picked from commit 0265ca9)

Co-authored-by: Corentin Forler <[email protected]>
ruchamahabal pushed a commit that referenced this pull request Jul 27, 2024
)

(cherry picked from commit 0265ca9)

Co-authored-by: Corentin Forler <[email protected]>
frappe-pr-bot pushed a commit that referenced this pull request Jul 31, 2024
## [15.25.1](v15.25.0...v15.25.1) (2024-07-31)

### Bug Fixes

* Sort lists before calling itertools.groupby (backport [#1997](#1997)) ([#2009](#2009)) ([8cb16a0](8cb16a0))
frappe-pr-bot pushed a commit that referenced this pull request Jul 31, 2024
## [14.29.2](v14.29.1...v14.29.2) (2024-07-31)

### Bug Fixes

* Sort lists before calling itertools.groupby (backport [#1997](#1997)) ([#2008](#2008)) ([b2dbb0a](b2dbb0a))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants