-
Notifications
You must be signed in to change notification settings - Fork 195
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
Remove inputs
special keyword argument
#1790
Comments
I support this. |
@annawoodard I think the behavior I was naively expecting is exactly that which you rightly pointed out others might end up expecting - that any Anyway this is a breaking change (removing |
When we've removed features before, we've made them deprecated for one release, and then removed the code in the next release. What that would look like here, I think, is that from now until parsl (1.0.0 + 1 version) is released, the code should log a warning when inputs is used, such as " Perhaps that warning could be placed in Then this issue should be left open until sometime actually removes all the code, sometime after (1.0.0 + 1 version) is released |
I don't think this will be a breaking change? The change here would expand the way we introspect arguments such that any list/tuple would be treated the same way that inputs are currently treated. So those that want to use inputs can continue to do so. We can simply remove inputs from the documentation as a special keyword. |
I think @annawoodard 's proposal is to remove inputs, but not add in new deep data structure inspection for parsl-magic (that is, not do #1788, #1789). If so, that makes |
@kylechard Ben's summary of the proposal is correct. I favor logging a warning, changing docs, and removing code in next release. Alternatively we could retain the current behavior for backwards compatibility but just change the docs. @yadudoc @ZhuozhaoLi @danielskatz interested if you have any opinions on this |
We talked about this in the Parsl meeting Friday, and were leaning towards your
We also talked about removing |
Summarizing discussion from Friday:
Fixing |
Thanks for the summary, @yadudoc!
Yay! Really we should remove all special keyword args as they all suffer from the bug @makslevental reported in #1788.
I think inspecting some data structures and not others would be confusing to users. In my view, we should either only resolve bare
I am strongly against this proposal. I think properly implementing it, if it can be done at all, it would be a huge amount of work and even then would be riddled with bugs and unexpected behavior. And the only thing we gain is a bit of syntactic sugar. Users are always free to write an app which takes the component futures and returns their data structure of choice.
That proposal would need tweaking, as users would need a way to map the output passed as an argument to the returned DataFuture as is currently done with the index in the list: future = app(stderr='baz', outputs=[foo, bar])
foo, bar = future.outputs Instead, to solve the general problem with special keyword args, I favor a general class: future = app(RuntimeConfig(stderr='baz', outputs=[foo, bar]))
foo, bar = future.outputs But specifically for |
For
For |
@makslevental recently reported a serious bug #1788 and proposed a solution in #1789. One reservation I have with that approach is that it would change current Parsl behavior in a way that might be confusing for users: if a list or tuple of futures is passed as a positional arg, Parsl would wait for each component future to be resolved before executing the app. This might lead users to expect that other structures (like dicts, etc) would also be introspected.
@benclifford pointed out on Slack that because we now check args, keyword args, and the
inputs
special keyword arg for files to potentially stage in, theinputs
special keyword argument is redundant. Borrowing Max's example:could be replaced by:
And to clarify how this plays with other arguments and give a full example:
One advantage of removing
inputs
is that it would be more pythonic, and less Parsl-specific jargon for people to grok. Removing it would also be a fix for #1788.The text was updated successfully, but these errors were encountered: