NateV03/31/2023, 1:34 PM
definition returns an Output with a pandas Dataframe for its value. Then I try to pass it to an
that takes a dataframe and does some work to send emails based on the contents of the dataframe. But when I write a
like the one in this example , I get a type error
. And at runtime, i get an error from the
Argument of type "SourceAsset" cannot be assigned to parameter "df" of type "DataFrame
. So the
'SourceAsset' object has no attribute 'to_string'
is getting a SourceAsset, not the value of the asset. All the
examples just show the asset value getting passed directly as a parameter. So ... Do I need to do something in the
to get the Dataframe from the
returned from my
? Or does the
need to take a
instead of a
and do something to get the DataFrame out of the SourceAsset?
? is it the asset's value, like a dataframe or list, or is it a SourceAsset that the
needs to ... materialize or something?
@op def send_emails(emails) -> None: ...
decorator on the email-sending op. but it also turns out the coercion of a SourceAsset to the asset value means I can't pass other non-source assets to the op function (like strings or whatever). Not sure what that means me. Maybe i need to some sort of OpBuilder currying thing to make an op dynamically