-
Notifications
You must be signed in to change notification settings - Fork 51
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
Do not require input value for start_new, call_activity, etc #91
Comments
Good observation, I'll take this on |
I fixed self.call_activity = lambda n, i=None: call_activity_task(
state=self.histories,
name=n,
input_=i)
self.call_activity_with_retry = \
lambda n, o, i=None: call_activity_with_retry_task(
state=self.histories,
retry_options=o,
name=n, Please let me know what you think |
Just triple checked, and this ( You can reproduce this yourself by modifying the The new def main(name: str="Bob") -> str:
"""Activity function performing a specific step in the chain
Parameters
----------
name : str
Name of the item to be hello'ed at
Returns
-------
str
Returns a welcome string
"""
return f'Hello : {name}!' The new import logging
import azure.functions as func
import azure.durable_functions as df
def orchestrator_function(context: df.DurableOrchestrationContext):
"""This function provides the core function chaining orchestration logic
Parameters
----------
context: DurableOrchestrationContext
This context has the past history
and the durable orchestration API's to chain a set of functions
Returns
-------
final_result: str
Returns the final result after the chain completes
Yields
-------
call_activity: str
Yields at every step of the function chain orchestration logic
"""
# Chained functions - output of a function is passed as
# input to the next function in the chain
# Note, in this case, there's no actual chaining
final_result = yield context.call_activity("DurableActivity")
return final_result
main = df.Orchestrator.create(orchestrator_function) I'll close this issue, for now. Please feel free to re-open it if necessary 😄 |
Currently, for all client and context functions that take an input, we must pass
None
if we don't want to pass an input value at all. We should make the input value parameter optional instart_new
,call_activity
, etc.For example,
should be
@davidmrdavid @priyaananthasankar
The text was updated successfully, but these errors were encountered: