https://dagster.io/ logo
#dagster-support
Title
# dagster-support
a

Alec Koumjian

02/01/2023, 7:57 PM
Confused about resource defs for assets inside jobs. I have an asset with
io_manager_key="file_gcs_io_manager"
. This is defined in my
Definitions
under the resources section. I am generating that asset inside of a job using the @job decorator. However, at runtime it throws an error:
Copy code
dagster._core.errors.DagsterInvalidDefinitionError: io manager with key 'file_gcs_io_manager' required by
output 'result' of op '<function_name>'' was not provided. Please provide a <class
'dagster._core.storage.io_manager.IOManagerDefinition'> to key 'file_gcs_io_manager', or change the
required key to one of the following keys which points to an <class
'dagster._core.storage.io_manager.IOManagerDefinition'>: ['io_manager']
Do I have to pass it in as a resource_def to my job decorator as well? Seems odd that it's not finding it in the global resource defs.
j

jamie

02/01/2023, 8:21 PM
Hey @Alec Koumjian could you share a code snippet of what you have right now? feel free to dm it to me if needed
a

Alec Koumjian

02/01/2023, 8:22 PM
thanks, I'll send over a dm!
s

Seth Kimmel

02/06/2023, 3:49 AM
Were you able to get this resolved? Wondering if it's a bug with a recent release given this recent issue as well: https://dagster.slack.com/archives/C01U954MEER/p1674524054041209?thread_ts=1674523987.554649&amp;cid=C01U954MEER
a

Alec Koumjian

02/06/2023, 2:05 PM
I was able to make this working using the
define_asset_job
constructor.
s

Seth Kimmel

02/06/2023, 4:25 PM
Thanks! I actually wound up figuring this out. Was pointing my
dagit
instance to the wrong
Definitions
a

Alec Koumjian

02/06/2023, 4:35 PM
Just realized that is my colleague 😄
34 Views