You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now we are by default inheriting fields from the parent in declarative hooks. For instance in this hook:
<-:
foo: bar a_method<-:
exec:
p->: print {{foo}}
It works to call tackle a_method but this raises the question if this should be enabled by default which I think makes sense. It could potentially have a key to disable inheritance or do it selectively but this is up for opinions that can be settled later.
This was initially prompted by the help screen as for a bit, we were rendering the foo kwarg in the help for the a_method. In the unpack_hook function in help.py, we have this condition to render these vars as by the time this has reached the parser, it has already been instantiated.
elifisinstance(hook_field, dict):
help_arg=HelpInput(name=i, **hook_field)
elifisinstance(hook_field, ModelField):
# If enabling inheritance for base vars in to the help, then this will# need to be active.# help_arg = HelpInput(# name=i,# type=hook_field.type_.__name__,# # description=hook_field.d # TODO: Fix this# )continueelse:
raiseNotImplementedError
Right now it is disabled as I think this should be something that is toggleable but I don't really know what the right way to do that is.
The text was updated successfully, but these errors were encountered:
Right now we are by default inheriting fields from the parent in declarative hooks. For instance in this hook:
It works to call
tackle a_method
but this raises the question if this should be enabled by default which I think makes sense. It could potentially have a key to disable inheritance or do it selectively but this is up for opinions that can be settled later.This was initially prompted by the help screen as for a bit, we were rendering the
foo
kwarg in the help for thea_method
. In theunpack_hook
function in help.py, we have this condition to render these vars as by the time this has reached the parser, it has already been instantiated.Right now it is disabled as I think this should be something that is toggleable but I don't really know what the right way to do that is.
The text was updated successfully, but these errors were encountered: