Skip to content

fix(core): report every invalid action input property - #254

Open
DevMello wants to merge 1 commit into
oomol-lab:mainfrom
DevMello:fix/validation-report-all-errors
Open

fix(core): report every invalid action input property#254
DevMello wants to merge 1 commit into
oomol-lab:mainfrom
DevMello:fix/validation-report-all-errors

Conversation

@DevMello

@DevMello DevMello commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

Calling an action with several invalid inputs only reports the first bad field, so a caller fixes its input one field per round trip.

input:   { first: 1, second: "two", third: "three" }
before:  1 error   (first)
after:   3 errors  (first, second, third)

Validation stopped at the first failure. It now collects them all.

Validation stopped at the first bad property, so a caller fixed its input
one field per round trip. It now collects every failure.
@coderabbitai

coderabbitai Bot commented Aug 2, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: c556a6e0-9ac0-4e1a-ac9b-0d6b94d0f0ce

📥 Commits

Reviewing files that changed from the base of the PR and between deadc1c and a1549bb.

📒 Files selected for processing (2)
  • src/core/validation.test.ts
  • src/core/validation.ts

Summary by CodeRabbit

  • Bug Fixes

    • Validation now reports all invalid properties in a single check instead of stopping after the first error.
  • Tests

    • Added coverage to verify that multiple validation errors are reported together.

Walkthrough

validatorFor now disables short-circuiting. Validation returns errors for all invalid properties. A test covers invalid string, number, and boolean values and checks all three error locations.

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title follows the required format and clearly describes the core validation change.
Description check ✅ Passed The description explains that validation now reports all invalid input properties in one response.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
✨ Simplify code
  • Create PR with simplified code

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

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