Is it possible to yield a DataVersion for a Source...
# ask-community
c
Is it possible to yield a DataVersion for a SourceAsset from a sensor? Or do you have to run an op?
Use case: monitoring Google Sheets for updates. If the sensor detects that one of the sheets has been modified, I want it to update the DataVersion so that the downstream dbt asset will AutoMaterialize
o
hi @Charlie Bini! at the moment, you'll need to run an op. so one possible pattern would be an op that takes a list of modified sheets as config (emitting an AssetObservation for each of them), and have the sensor check for modified sheets and kick off a run with those sheets passed through the op's config. one thing to note is that right now, you'll still want to have observable source assets for each of the sources. those observable source assets don't need to do anything (you can manage the state purely with the sensor + op approach), but having those observable source assets tells Dagster to look for data versions for those assets. in the future, this would all be much more neatly handled by something like a multi_observable_source_asset
c
ahh didn't consider a straight op, been in asset land too long
🌈 1