Commit 9327cd8
fix(analytics): dataset widgets degrade to empty when backing object/table is absent (#1851)
A dashboard/report dataset whose backing object isn't present in the kernel
hard-failed the widget with a 500. Concretely: the platform System Overview
dashboard (shipped by plugin-auth) charts `sys_audit_log` via the
`sys_audit_log_metrics` dataset; opened in an environment that never mounted
the audit object, every audit widget 500'd ("no such table: sys_audit_log").
Wrap the dataset execution in `queryDataset`: on a MISSING-SOURCE error
(table/object/relation absent — matched across sqlite/libsql, postgres,
mysql, and the framework's unknown-object signal) log a warning and return an
empty result, so the widget renders "no data" instead of crashing. Column/
syntax errors still throw so real query bugs surface. The list grid and
detail surfaces already tolerate absent data; datasets were the gap.
Co-authored-by: Jack Zhuang <277994282+os-zhuang@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 2a47a28 commit 9327cd8
2 files changed
Lines changed: 59 additions & 1 deletion
Lines changed: 19 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
56 | 75 | | |
57 | 76 | | |
58 | 77 | | |
| |||
Lines changed: 40 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
24 | 45 | | |
25 | 46 | | |
26 | 47 | | |
| |||
390 | 411 | | |
391 | 412 | | |
392 | 413 | | |
393 | | - | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
394 | 433 | | |
395 | 434 | | |
396 | 435 | | |
| |||
0 commit comments