Hi All. Is there a way to access event metadata of...
# ask-community
g
Hi All. Is there a way to access event metadata of the AssetMaterialization event inside of the
asset_sensor
? I tried doing this, but it didn't work (dagster_event doesn't have
metadata
field):
Copy code
@asset_sensor(asset_key=AssetKey("my-asset-key"), job=my_job)
def my_asset_sensor(context, asset_event):
    yield RunRequest(
        run_key=context.cursor,
        run_config={
            "ops": {
                "my_op": {
                    "config": {
                        "txt_metadata_from_asset": asset_event.dagster_event.metadata["txt_field"]
                    }
                }
            }
        }
    )
👀 1
🤖 1
a
I was looking for the same information, and searching Slack for
asset_event
I found some existing threads on this topic. I hope it helps you, @Grigoriy Sterin. 🙏
g
Thank you!
s
Just a note that this is on our radar and we are already tracking it here: https://github.com/dagster-io/dagster/issues/7384