Page MenuHomeElementl

feat: add support for dict of ins and outs
ClosedPublic

Authored by cdecarolis on Jun 18 2021, 6:49 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Jul 19, 11:06 PM
Unknown Object (File)
Tue, Jul 19, 8:59 PM
Unknown Object (File)
Tue, Jul 19, 8:08 AM
Unknown Object (File)
Tue, Jul 19, 12:06 AM
Unknown Object (File)
Mon, Jul 18, 3:35 PM
Unknown Object (File)
Sun, Jul 17, 4:09 PM
Unknown Object (File)
Sun, Jul 17, 2:42 PM
Unknown Object (File)
Jul 15 2022, 2:26 PM
Subscribers
None

Details

Summary

This diff adds support for supplying ins and outs as dictionary arguments

Test Plan

unit

Diff Detail

Repository
R1 dagster
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

unclear if inheritance is the way to go with In and Out once there is this behavior difference. Might be best to have a simple value object and interpret it in to the underlying def, maybe with a scheme like [1]

Getting the type inference to work on MultiOut might inform which path is preferable

python_modules/dagster/dagster/core/definitions/output.py
190–216

[1]

316

copy pasta

python_modules/dagster/dagster_tests/core_tests/definitions_tests/decorators_tests/test_op.py
45–156

would still like to see the types that the inputs & outputs have resolved with here in these tests

python_modules/dagster/dagster_tests/core_tests/definitions_tests/decorators_tests/test_op.py
45–156

input and output types are Any, unfortunately

Super messy and awful rn but here's the idea

Cleaned up implementation a bit

Do Ins/Outs need to have names if we're going with the dict approach?

Do Ins/Outs need to have names if we're going with the dict approach?

If we're going with the pure dict approach then no - but if we're not sure if we want to support dicts or lists, I think it makes sense to keep it for now.

This revision was not accepted when it landed; it landed in state Needs Review.Jun 23 2021, 4:02 PM
This revision was automatically updated to reflect the committed changes.