Skip to content
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

Minor bug/usability fixes for 1.22.1 #140

Merged
merged 5 commits into from
Apr 14, 2023

Conversation

elijahbenizzy
Copy link
Collaborator

[Short description explaining the high-level reason for the pull request]

Changes

How I tested this

Notes

Checklist

  • PR has an informative and human-readable title (this will be pulled into the release notes)
  • Changes are limited to a single goal (no scope creep)
  • Code passed the pre-commit check & code is left cleaner/nicer than when first encountered.
  • Any change in functionality is tested
  • New functions are documented (with a description, list of inputs, and expected output)
  • Placeholder code is flagged / future TODOs are captured in comments
  • Project documentation has been updated if adding/changing functionality.

This ensures that they can only be ParameterizedDependency (source or
value).
@elijahbenizzy elijahbenizzy force-pushed the add-helpful-validate-message branch from 4ee94e3 to 7e446d5 Compare April 13, 2023 22:25
@elijahbenizzy elijahbenizzy requested a review from skrawcz April 13, 2023 23:31
@elijahbenizzy elijahbenizzy force-pushed the add-helpful-validate-message branch from 456757c to 4f23776 Compare April 14, 2023 20:14
@elijahbenizzy elijahbenizzy force-pushed the add-helpful-validate-message branch from 4f23776 to cb5385f Compare April 14, 2023 20:15
@elijahbenizzy elijahbenizzy changed the title Add helpful validate message Minor bug/usability fixes for 1.22.1 Apr 14, 2023
hamilton/function_modifiers/dependencies.py Outdated Show resolved Hide resolved
hamilton/function_modifiers/dependencies.py Outdated Show resolved Hide resolved
@@ -173,26 +200,10 @@ def __init__(
self.inputs = inputs if inputs is not None else {}
self.config = config if config is not None else {}
self.external_inputs = external_inputs if external_inputs is not None else []
self._validate_config_inputs(self.config, self.inputs)
_validate_config_inputs(self.config, self.inputs)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably want a try catch here to then contextualize that it's a subdag decorator for node FOO?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep good idea

Copy link
Collaborator

@skrawcz skrawcz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah so looks alright -- we might want to think about how to ensure when an error occurs it provides the right context of the decorator and node name.

@elijahbenizzy elijahbenizzy force-pushed the add-helpful-validate-message branch from f76cd85 to 9dd521e Compare April 14, 2023 22:36
@elijahbenizzy elijahbenizzy merged commit 323c4ea into main Apr 14, 2023
@elijahbenizzy elijahbenizzy deleted the add-helpful-validate-message branch April 14, 2023 22:43
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.

2 participants