dffml icon indicating copy to clipboard operation
dffml copied to clipboard

df: base: op: Support single output without auto-defined I/O

Open pdxjohnny opened this issue 2 years ago • 0 comments

 478                     if auto_def_outputs and len(self.parent.op.outputs) == 1:
 479                         if inspect.isasyncgen(result):
 480
 481                             async def convert_asyncgen(outputs):
 482                                 async for yielded_output in outputs:
 483                                     yield {
 484                                         list(self.parent.op.outputs.keys())[
 485                                             0
 486                                         ]: yielded_output
 487                                     }
 488
 489                             result = convert_asyncgen(result)
 490                         elif result is not None and valid_return_none:
 491                             result = {
 492                                 list(self.parent.op.outputs.keys())[0]: result
 493                             }

pdxjohnny avatar Apr 01 '22 14:04 pdxjohnny