Pass `inputs` through to Result class
See original GitHub issueI would like to be able to access a tasks inputs when reading/writing results. This allows properly caching based on the different inputs to a function, for example by templating a filename as experiment;m=5
.
Current behavior
Please describe how the feature works today
The prefect.context
is passed to the read/write(exists?) methods of the Results class
Proposed behavior
Please describe your proposed change to the current behavior Please pass the inputs also.
Example
Please give an example of how the enhancement would be useful This would allow something like the following
@task(result=GCSResult(bucket='bucket', location='{task_name};m={inputs["multiplier"].txt'))
def experiment(multiplier=1):
# do something
return
Issue Analytics
- State:
- Created 3 years ago
- Reactions:7
- Comments:20 (13 by maintainers)
Top Results From Across the Web
Python class input argument - Stack Overflow
I know, that is not possible, but how can I pass an input-argument into an instance of a class? python · oop ·...
Read more >Passing Information to a Method or a Constructor
Arguments are the actual values that are passed in when the method is invoked. ... A parameter can have the same name as...
Read more >Passing Arguments by Reference | ObjectScript Tutorial
Passing arguments to a class method by reference only works if you precede these arguments with a dot. Passing an array to a...
Read more >Get input to pass into server script for a service portal widget
I'm trying to get the user input from my widget and pass it into my server script to get a result. HTML. <div...
Read more >24. Passing Arguments | Python Tutorial
In call-by-value, the argument expression is evaluated, and the result of this evaluation is bound to the corresponding variable in the function ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@marwan116 Yes it will be!
Hi @pedromachados :
target
is a keyword you should only use if you intend to affect the way the pipeline runs as described above.target
andlocation
are mutually exclusive at the task level, and if both are providedtarget
will be used.