Charlie Bini
06/01/2022, 4:03 PMcontext.log
access to a resource?Charlie Bini
06/01/2022, 4:08 PM@resource
decoratorowen
06/01/2022, 4:13 PM@resource(...)
def my_resource(context):
return MyClass(..., logger=context.log)
should work!owen
06/01/2022, 4:14 PMfrom dagster import get_dagster_logger
, and inside the body of the resource call get_dagster_logger().info("foo")
Charlie Bini
06/01/2022, 4:14 PMCharlie Bini
06/01/2022, 4:15 PMcontext
param on the resource def is the same one that contains config_schema
right?owen
06/01/2022, 4:17 PMresource_config
property (this is the resolved config value)owen
06/01/2022, 4:17 PMconfig_schema
is the schema for that config blob, and will be inside the argument to the @resource
decoratorCharlie Bini
06/01/2022, 4:18 PM