fix(aggregate): include first row in SUM and coerce numeric strings - #9
Open
namannitr wants to merge 1 commit into
Open
fix(aggregate): include first row in SUM and coerce numeric strings#9namannitr wants to merge 1 commit into
namannitr wants to merge 1 commit into
Conversation
This was referenced Aug 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
src/aggregate.tsalready seededSUMfrom the first in-group value (PR Fix for #1 #3 / issue initial value of sum should be the first value instead of 0 #1), butdist/ecSimpleTransform.jswas never rebuilt, so npm and jsDelivr still shipSUM: function () { return 0; }. Singleton groups therefore SUM to0, and multi-row groups skip the first row.Number(...)so object-row sources like{ billAmount: '400' }add as numbers instead of concatenating strings (issue Sum method not giving correct result #6).dist/(including the min bundle jsDelivr points at) and addednpm testcoverage for both cases.Test plan
npm run release && npm test— covers singleton SUM, multi-row SUM including the first row, and the billAmount string fixture from Sum method not giving correct result #6 (Mar=1000,April=210,August=148)dist/ecSimpleTransform.min.js)Made with Cursor