Commit Graph
100 Commits
Author SHA1 Message Date
Brandon ThomasandClaude Opus 5.5 7cf44d0fbb Integration and review fixes for #2367, #2369 and #2387
- #2369: its test joins the single ui-egui integration-test binary (tests/it), as main now builds them.
- #2367: a cell set to empty text is a blank entry and doesn't grow the AutoFilter (CodeRabbit).
- #2387: MOD's range check also covers the sign-corrected remainder (CodeRabbit).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 16:05:43 -04:00
NetterSilverandClaude Haiku 5.5 c746eea876 Fix MOD returning wrong sign and magnitude for tiny divisors
Found while testing crates/functions/src/math.rs:305-319

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-23 21:43:22 +02:00
Brandon Thomas d1399ff2ca Merge PR #2279 2026-10-23 10:11:12 -04:00
NetterSilverandClaude Opus 5.5 8307d3cb05 Treat empty instance_num in TEXTBEFORE/TEXTAFTER as 1
Found while testing crates/functions/src/text.rs:553

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 08:25:54 +00:00
Tyrel HavemanandClaude Opus 5.5 742a6e8535 functions: REGEXREPLACE bounds each replacement as it expands it (#2162)
From the local CodeRabbit review: the result was bounded per match, but
one match's expansion was built whole first, so a replacement repeating
$0 10,000 times over a 32,767-character match allocated about 330 MB
before the check. The replacement is now split into pieces as regex's
Captures::expand reads it (template_expands_like_regex checks they agree)
and appended piece by piece within the bound: 327 MB peak became 7 MB
(regexreplace_bounds_its_result).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019Nnsfu3QGqjD1aFZbBgUWP
2026-10-21 23:45:50 -07:00
Tyrel HavemanandClaude Opus 5.5 e177bf1c44 calc: hardening: overlong digits, NaN indexes, REGEXREPLACE output (#2163, #2162)
- Text coercion: digits too many for a finite number are not a number,
  and a fraction must come out finite, so "1 <400 digits>/<400 digits>"
  (inf/inf) no longer coerces to NaN (test overlong_digits_stay_text).
- VLOOKUP/HLOOKUP and the D-functions' field index refuse NaN, which
  passed their "< 1" checks and became index 0, then underflowed
  (test nan_index_is_a_value_error; hostile_inputs_never_panic now also
  passes NaN and infinity to every function).
- REGEXREPLACE replaces match by match and gives up once the result can
  only be too long, instead of building every replacement first: the
  32,767 x 32,767 worst case went from 1.05 GB peak to 7 MB
  (test regexreplace_bounds_its_result).

#2165 (MAP's size check) is already fixed on main by the broadcast cap
(836b2698, #2182), whose test covers MAP.

Also adds my contributors/people.toml entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019Nnsfu3QGqjD1aFZbBgUWP
2026-10-21 23:41:28 -07:00
aiongg a680ac59f0 Integration: track t07
# Conflicts:
#	crates/calc/src/tests.rs
#	docs/function-parity.md
2026-10-22 03:03:23 +00:00
aiongg 15dfbef548 Merge PR #2195: calc: cap LINEST-family regressor matrices (#2177) 2026-10-22 02:35:10 +00:00
aiongg 0cc4798ca9 Merge PR #1650: fix(ets): avoid repeated scans while interpolating gaps
docs/function-parity.md: status line takes this PR's change text with the newer review date; both history rows kept, newest first.
2026-10-22 02:34:55 +00:00
aiongg 2a3ea02e69 Merge PR #1526: functions: NETWORKDAYS.INTL accepts the all-weekend string "1111111" 2026-10-22 02:34:46 +00:00
aiongg 806a439efa Merge PR #1507: Read securities function dates in the workbook's date system 2026-10-22 02:34:46 +00:00
aiongg 011ae7266d Merge PR #1469: Let GROUPBY and PIVOTBY take a LAMBDA as their function 2026-10-22 02:34:45 +00:00
aiongg 941da33355 Merge PR #1432: Stop BINOM.INV/CRITBINOM hanging when trials exceed 2^53 2026-10-22 02:34:45 +00:00
aiongg a3baf552a1 Merge PR #1281: N() converts a computed array element by element, so it works inside SUMPRODUCT
crates/calc/src/tests.rs: kept both tests (union).
2026-10-22 02:34:42 +00:00
aiongg f55cbcd061 Merge PR #1237: BAHTTEXT: a final one after the millions reads เอ็ด 2026-10-22 02:34:35 +00:00
aiongg 91be133965 Merge PR #1114: Read date text arguments in the workbook date system (#1038) 2026-10-22 02:34:35 +00:00
aiongg a0a4b6a7d0 Merge PR #1105: Fix row keys merging distinct text rows in UNIQUE and grouping (#1012) 2026-10-22 02:34:35 +00:00
Higgs32584andClaude Opus 5.5 e1b8aad143 calc: cap LINEST-family regressor matrices (#2177)
LINEST, LOGEST, TREND and GROWTH built k x k normal-equation matrices
(plus two copies in sym_inverse, O(k^3)) with k taken straight from the
known_xs shape, so one formula could allocate gigabytes and abort on open.
More than 255 predictors is now #VALUE!, and more than 1e9 rows x k^2
multiply-adds is #NUM!, both checked before any allocation.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-21 20:07:30 -04:00
Eduardo GarciaandClaude Sonnet 5.5 0b4cc5618f fix #1458: one Excel sheet-name quoting rule for formulas, pivot sources and ADDRESS
Sheet names starting with '.' or reading as R1C1 (R, C, RC, R1C1...) were saved
unquoted, so Excel could not open the file; PivotTable sources and ADDRESS left
cell-like names (A1) bare. The quoting rule, unquoting and sheet splitting now
live once in gridcraft_core::addr and replace the copies in the formula printer,
pivot, ADDRESS, chart, xlsx, Solver, Go To and the Name Box (which now reads ''
as ').

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-19 17:36:40 -03:00
NetterSilverandClaude Haiku 5.5 e9ffc71c6a Search from the end for negative TEXTBEFORE/TEXTAFTER instances
Found while testing crates/functions/src/text.rs:511-552

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-19 12:27:46 +00:00
Mex c30fa3f1cf fix(functions): avoid overflow in median midpoints (#1579) (#1585) 2026-10-17 21:13:03 -06:00
harrisonoconnorhover 1131de97ff fix(ets): avoid repeated interpolation scans (#1042) 2026-10-16 08:12:47 -04:00
midasmatterhorn 3f9b73b927 functions: NETWORKDAYS.INTL accepts the all-weekend string "1111111"
weekend_mask rejected the all-weekend string outright for both
NETWORKDAYS.INTL and WORKDAY.INTL, but Microsoft documents them as
differing: NETWORKDAYS.INTL "Using 1111111 will always return 0",
WORKDAY.INTL "1111111 is an invalid string". The crate already
implements that split — workday_core's per_week == 0 guard — which was
unreachable dead code while the extra clause stood. Drop the clause:
NETWORKDAYS.INTL counts zero workdays as documented and WORKDAY.INTL
errors through the guard it already has.

The existing test asserted the old behaviour and is updated.
Regression: working_days — on main the NETWORKDAYS.INTL assertion fails
(#VALUE! where Excel returns 0); with the clause dropped it passes and
WORKDAY.INTL is asserted to error.
2026-10-15 17:12:41 +03:00
NetterSilverandClaude Haiku 5.5 e1902111d8 Read securities function dates in the workbook's date system
Fixes #1457

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 12:29:44 +00:00
NetterSilverandClaude Haiku 5.5 cdc8177fae Let GROUPBY and PIVOTBY take a LAMBDA as their function
Fixes #903

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 08:09:18 +02:00
NetterSilverandClaude Haiku 5.5 9b155c48f7 Stop BINOM.INV/CRITBINOM hanging when trials exceed 2^53
Found while testing crates/functions/src/stat.rs:1244

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 03:43:57 +00:00
Marco Arnulfo 531d292930 N() converts a computed array element by element, so it works inside SUMPRODUCT (fixes #1279) 2026-10-14 11:46:48 +02:00
Marco Arnulfo d1075c067b BAHTTEXT: a final one after the millions reads เอ็ด (fixes #1234) 2026-10-14 05:46:44 +02:00
MarekSpodBiedry e440c8bdc9 Read date text arguments in the workbook date system (#1038) 2026-10-13 18:06:29 +02:00
MarekSpodBiedry caa9fd0f48 Fix row keys merging distinct text rows in UNIQUE and grouping (#1012) 2026-10-13 18:02:34 +02:00
Brandon Thomas 80d282e7a5 Merge pull request #752 from marcoarnulfo:fix/function-excel-diffs-738 2026-10-13 01:39:44 -04:00
Brandon Thomas 5144bd5b17 Merge pull request #742 from marcoarnulfo:fix/edate-eomonth-1900 2026-10-13 01:39:43 -04:00
Brandon Thomas cc0b7c18d1 Merge main into #600
# Conflicts:
#	crates/calc/src/eval.rs
2026-10-13 00:49:39 -04:00
Brandon Thomas c888e81d71 Merge main into #593
# Conflicts:
#	crates/functions/src/text.rs
2026-10-13 00:48:34 -04:00
Marco Arnulfo 638cbab9a5 Merge remote-tracking branch 'origin/main' into fix/edate-eomonth-1900
# Conflicts:
#	crates/functions/src/date.rs
2026-10-13 06:29:36 +02:00
Marco Arnulfo ca8fc73281 Merge remote-tracking branch 'origin/main' into fix/function-excel-diffs-738
# Conflicts:
#	crates/calc/src/eval.rs
2026-10-13 06:29:34 +02:00
Brandon Thomas 727bd37983 Merge main into #751
# Conflicts:
#	crates/calc/src/tests.rs
2026-10-13 00:08:04 -04:00
Brandon Thomas d8561a9ed7 Merge pull request #755 from marcoarnulfo:fix/xludf-prefix 2026-10-12 23:49:23 -04:00
Brandon Thomas 45973a6804 Merge pull request #745 from marcoarnulfo:fix/mode-typed-text-bool 2026-10-12 23:49:12 -04:00
Brandon Thomas 705543521e Merge pull request #744 from marcoarnulfo:fix/roman-forms-2-3 2026-10-12 23:49:10 -04:00
Brandon Thomas 1d875bdf45 Merge pull request #686 from neilcawse:fix/criteria-over-255 2026-10-12 23:48:47 -04:00
Brandon Thomas ca9b3fbbe8 Merge pull request #586 from MarekSpodBiedry:issue-578 2026-10-12 23:35:32 -04:00
Brandon Thomas 2df8dd6392 Merge pull request #618 from MarekSpodBiedry:issue-540 2026-10-12 23:29:58 -04:00
Brandon ThomasandClaude Opus 5.5 4941bf8da0 ROUNDUP keeps #NUM! past the number range; only toward-zero rounding returns 0
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-12 23:29:56 -04:00
Brandon Thomas f6252418d9 Merge pull request #622 from MarekSpodBiedry:issue-536 2026-10-12 23:21:45 -04:00
Brandon Thomas 8474233335 Merge pull request #621 from MarekSpodBiedry:issue-537 2026-10-12 23:21:44 -04:00
Brandon Thomas c8f249fc97 Merge pull request #620 from MarekSpodBiedry:issue-538 2026-10-12 23:21:42 -04:00
Brandon Thomas 9e3a83464f Merge pull request #619 from MarekSpodBiedry:issue-539 2026-10-12 23:21:41 -04:00
Brandon Thomas 09c719623b Merge pull request #618 from MarekSpodBiedry:issue-540 2026-10-12 23:21:40 -04:00
neilcawse e5b12dab06 Functions: COUNTIF family counts the 255 criterion limit in UTF-16 units, as in Excel 2026-10-12 16:09:52 -04:00