-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve xtrigger validation #60
Conversation
Integration test failures unrelated - cylc#5977 |
ebff083
to
51438cf
Compare
bound_args.apply_defaults() | ||
try: | ||
xtrig_validate_func(bound_args.arguments) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With this approach, people writing xtrigger validate functions don't have to worry about whether an argument is positional and/or keyword (the original xrandom.validate
example was flawed because it didn't account both cases under the previous system)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, I like it.
* Xtrigger function arg validation. * Add integration tests for xtrigger validation, which provides simple examples for each of the built in xtriggers. - Xrandom validate function - Init test xrandom validate function - Add unit tests for validation of built in xtriggers - Automatically validate xtrigger function signature --------- Co-authored-by: Hilary James Oliver <[email protected]> * Apply suggestions from code review Co-authored-by: Ronnie Dutta <[email protected]> * fix flake8 * Improve xtrigger validation (#60) * Improve xtrigger validation * wall_clock: use placeholder function for signature validation & autodocs * Fix docstring for autodoc [skip ci] --------- Co-authored-by: Hilary Oliver <[email protected]> Co-authored-by: Ronnie Dutta <[email protected]>
Enhancement for cylc#5955