Commit fd9ef87
[webserver] accept user-provided tags on report_asset_materialization + report_asset_observation
The Python SDK supports arbitrary tags on runless asset events
(AssetMaterialization/AssetObservation tags=...), but the REST endpoints
silently drop any field outside their allowlists — so external (non-Python)
writers reporting events over REST cannot attach data-version provenance
tags like dagster/input_data_version/<upstream>. This adds an optional
'tags' param to both endpoints (json body, or json-encoded query param
mirroring 'metadata' handling). Validation is unchanged: tags flow into the
existing event construction, where validate_asset_event_tags already exempts
system asset event tags and strict-validates the rest, surfacing errors via
the existing 400 path. The dedicated data_version param takes precedence
over a conflicting dagster/data_version tag. Also fixes a copy-paste typo in
the observation handler's construction-error message (said
AssetMaterialization).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>1 parent b8c776f commit fd9ef87
2 files changed
Lines changed: 162 additions & 2 deletions
File tree
- python_modules/dagster-webserver
- dagster_webserver_tests/webserver
- dagster_webserver
Lines changed: 55 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
90 | 90 | | |
91 | 91 | | |
92 | 92 | | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
93 | 119 | | |
94 | 120 | | |
95 | 121 | | |
| |||
297 | 323 | | |
298 | 324 | | |
299 | 325 | | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
300 | 352 | | |
301 | 353 | | |
302 | 354 | | |
| |||
313 | 365 | | |
314 | 366 | | |
315 | 367 | | |
316 | | - | |
| 368 | + | |
317 | 369 | | |
318 | 370 | | |
319 | 371 | | |
| |||
334 | 386 | | |
335 | 387 | | |
336 | 388 | | |
| 389 | + | |
337 | 390 | | |
338 | 391 | | |
339 | 392 | | |
| |||
359 | 412 | | |
360 | 413 | | |
361 | 414 | | |
| 415 | + | |
Lines changed: 107 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
130 | 130 | | |
131 | 131 | | |
132 | 132 | | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
133 | 197 | | |
134 | 198 | | |
135 | 199 | | |
| |||
141 | 205 | | |
142 | 206 | | |
143 | 207 | | |
| 208 | + | |
144 | 209 | | |
145 | 210 | | |
146 | 211 | | |
| |||
171 | 236 | | |
172 | 237 | | |
173 | 238 | | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
174 | 245 | | |
175 | 246 | | |
176 | 247 | | |
| |||
181 | 252 | | |
182 | 253 | | |
183 | 254 | | |
184 | | - | |
| 255 | + | |
185 | 256 | | |
186 | 257 | | |
187 | 258 | | |
| |||
322 | 393 | | |
323 | 394 | | |
324 | 395 | | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
325 | 424 | | |
326 | 425 | | |
327 | 426 | | |
| |||
332 | 431 | | |
333 | 432 | | |
334 | 433 | | |
| 434 | + | |
335 | 435 | | |
336 | 436 | | |
337 | 437 | | |
| |||
359 | 459 | | |
360 | 460 | | |
361 | 461 | | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
362 | 468 | | |
363 | 469 | | |
364 | 470 | | |
| |||
0 commit comments