Skip to content

fix: update stride validation error messages#11998

Merged
kgryte merged 3 commits into
developfrom
philipp/fix-commit-review-2026-05-08
May 10, 2026
Merged

fix: update stride validation error messages#11998
kgryte merged 3 commits into
developfrom
philipp/fix-commit-review-2026-05-08

Conversation

@Planeshifter
Copy link
Copy Markdown
Member

@Planeshifter Planeshifter commented May 8, 2026

Description

Follow-up fixes for commits merged to develop between 11fb87da (2026-05-07 13:37 -0500) and 5fd5c85c (2026-05-08 16:47 +0500). Two sibling-consistency fixes across recently-added blas/ext/base packages:

  • blas/ext/base/slast-index-of-row — The error message in lib/slast_index_of_row.js and lib/slast_index_of_row.native.js (03cd59e4) lacks the lower bound specification that sindex-of-row and sibling packages include; updated both files and their JSDoc @throws tags to use the form 'invalid argument. Fifth argument must be greater than or equal to max(1,%d). Value: \%d`.'with both stride andLDA` parameters.

  • blas/ext/base/glast-index-of-row7c02336d has incomplete stride validation messaging in lib/main.js: the runtime throw omits the required lower bound and the @throws tag lacks context. Aligned both the error format string and documentation with the sibling gindex-of-row implementation, which provides the full constraint max(1,N) for auditability.

Related Issues

No related issues.

Questions

No.

Other

Validation

What was checked:

  • stdlib code-style compliance for the four new blas/ext/base packages (cwhere, dindex-of-column, slast-index-of-row, glast-index-of-row) and supporting commits, comparing each against established sibling packages.
  • Bug scan over the diff (loop bounds, stride math, NaN/inf handling, N-API argument validation, row-major vs column-major branching, negative-stride paths, format-string arity, JSDoc/runtime contract agreement).

What was deliberately excluded:

  • Anything requiring interpretation, judgement calls, or context outside the diff window to validate.
  • The auto-generated REPL data dump (ddb2fb7e) and TypeScript declaration auto-updates (cecfaba8, 583a8336) — spot-checked only.
  • Subjective preferences, "could be cleaner" suggestions, and nitpicks.

Note on revisions

An earlier revision of this PR also included a documentation-wording change to blas/ext/base/dindex-of-column ("stride of the" → "stride length for the"). That commit was dropped after maintainer review: the original phrasing already matched the majority sibling convention (dindex-of-row, sindex-of-row, gindex-of-row), so the change was unwarranted.

Checklist

AI Assistance

  • Yes
  • No

If you answered "yes" above, how did you use AI assistance?

  • Code generation (e.g., when writing an implementation or fixing a bug)
  • Test/benchmark generation
  • Documentation (including examples)
  • Research and understanding

Disclosure

This PR was authored end-to-end by Claude Code as part of an automated 24-hour commit-review pass. Findings were produced by parallel reviewer agents, independently re-verified against sibling packages before any edit, and limited to high-signal sibling-consistency fixes. A maintainer should audit before promoting out of draft.


@stdlib-js/reviewers


Generated by Claude Code

@stdlib-bot stdlib-bot added the BLAS Issue or pull request related to Basic Linear Algebra Subprograms (BLAS). label May 8, 2026
@stdlib-bot
Copy link
Copy Markdown
Contributor

stdlib-bot commented May 8, 2026

Coverage Report

Package Statements Branches Functions Lines
blas/ext/base/glast-index-of-row $\color{green}555/555$
$\color{green}+0.00%$
$\color{green}56/56$
$\color{green}+0.00%$
$\color{green}3/3$
$\color{green}+0.00%$
$\color{green}555/555$
$\color{green}+0.00%$
blas/ext/base/slast-index-of-row $\color{green}575/575$
$\color{green}+0.00%$
$\color{green}50/50$
$\color{green}+0.00%$
$\color{green}4/4$
$\color{green}+0.00%$
$\color{green}575/575$
$\color{green}+0.00%$

The above coverage report was generated for the changes in this PR.

@Planeshifter Planeshifter changed the title Follow-up fixes for develop commits merged 2026-05-07/2026-05-08 style: align outliers with sibling packages in blas/ext/base May 8, 2026
@Planeshifter Planeshifter force-pushed the philipp/fix-commit-review-2026-05-08 branch from b73330b to 4cfe7c0 Compare May 10, 2026 21:10
@Planeshifter Planeshifter changed the title style: align outliers with sibling packages in blas/ext/base docs: update stride validation error messages May 10, 2026
@Planeshifter Planeshifter requested a review from kgryte May 10, 2026 21:28
@Planeshifter Planeshifter marked this pull request as ready for review May 10, 2026 21:28
@Planeshifter Planeshifter requested a review from a team May 10, 2026 21:28
Comment thread lib/node_modules/@stdlib/blas/ext/base/glast-index-of-row/lib/main.js Outdated
Co-authored-by: Athan <kgryte@gmail.com>
Signed-off-by: Athan <kgryte@gmail.com>
@kgryte kgryte changed the title docs: update stride validation error messages fix: update stride validation error messages May 10, 2026
@stdlib-bot stdlib-bot added the Needs Review A pull request which needs code review. label May 10, 2026
@kgryte kgryte removed the Needs Review A pull request which needs code review. label May 10, 2026
@stdlib-bot stdlib-bot added the Needs Review A pull request which needs code review. label May 10, 2026
@kgryte kgryte merged commit 8ad7ea2 into develop May 10, 2026
51 checks passed
@kgryte kgryte deleted the philipp/fix-commit-review-2026-05-08 branch May 10, 2026 21:56
@kgryte kgryte removed the Needs Review A pull request which needs code review. label May 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BLAS Issue or pull request related to Basic Linear Algebra Subprograms (BLAS).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants