Skip to content

Call validate() only once when parsing via ParsableArguments.parse(_:) - #983

Merged
natecook1000 merged 1 commit into
mainfrom
fix/validate-called-twice
Oct 5, 2026
Merged

natecook1000 merged 1 commit into
mainfrom
fix/validate-called-twice

Conversation

@natecook1000

Copy link
Copy Markdown
Member

The implementation of this parsing point was re-calling the validate() method after parsing had completed, but validate() was already called within the parsing. This eliminates the extra call and adds a test to verify that validate() is only being called once regardless of entry point.

Checklist

  • I've added at least one test that validates that my change is working, if appropriate
  • I've followed the code style of the rest of the project
  • I've read the Contribution Guidelines
  • I've updated the documentation if necessary

The implementation of this parsing point was re-calling the validate()
method after parsing had completed, but validate() was already called
within the parsing. This eliminates the extra call and adds a test to
verify that validate() is only being called once regardless of entry
point.
@natecook1000
natecook1000 requested a review from rauhul as a code owner October 5, 2026 02:48
@natecook1000
natecook1000 enabled auto-merge (squash) October 5, 2026 02:48
@natecook1000
natecook1000 merged commit 0c8d2fc into main Oct 5, 2026
74 checks passed
@natecook1000
natecook1000 deleted the fix/validate-called-twice branch October 5, 2026 02:58
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