← Model losses

Head-to-head comparison

openai / gpt-6-luna / max / max effort preferred over openai / gpt-6-luna / high / high effort · clear win.

Primary judge: Sol 6.1, requested Low. Effective provider effort and internal attempts were not verified. A close win is still a scored preference; it does not establish a material defect.

Reviewed public evidence

Task goal

Review runtime compatibility and error containment for persisted dashboard layouts after the shared parseLayout envelope guard. Trace accepted-but-malformed nested title, config/localFilters, and query payloads, plus finite but grid-invalid positions, through DashboardPage and its grid/per-widget boundary and through DashboardBuilderPage, BuilderCanvas, WidgetRenderer, and WidgetConfigEditor/DataSourcePicker. Check how unknown or legacy custom widget types and extra fields behave. Determine whether the dashboard Reset to default and builder Start fresh recovery flows change only selection/draft state or can overwrite persisted layouts. Report only source-proven crashes, misleading recovery behavior, or destructive overwrite paths, with exact file/line evidence and the smallest safe mitigation. Do not claim that database records are malformed, do not broaden the parser contract or reject custom types without proof, and state clearly if no remaining defect is established.

openai / gpt-6-luna / max / max effort answer

**Direct, read-only source analysis:** remaining crashes and data-loss paths are established. No database contents are inferred.

### Findings

1. **An object-valued title can crash the builder.** `parseLayout` checks `id`, `type`, and position, but not `title` (`parseLayout.ts:21–27`). `BuilderCanvas` renders `widget.title` directly (`BuilderCanvas.tsx:139–142`), and `WidgetRenderer` does too (`WidgetRenderer.tsx:119–121`). A JSON object title is therefore accepted but is not a valid React child. The dashboard wraps each `WidgetCard` in `WidgetErrorBoundary` (`DashboardPage.tsx:572–574`), so the failure is contained to that widget there; the supplied builder code has no corresponding boundary around its canvas or editor. **Mitigation:** render a safe fallback string at these display sites; do not reject custom widget types in the parser.

2. **Malformed nested filters and query metrics can crash a widget—or the builder editor.** `WidgetCard` spreads `config.localFilters` as an iterable without checking it (`WidgetCard.tsx:44–47`); an object value throws during render. With non-empty query results, missing/null `query.metrics` can throw in the `progress_bullet`/`coverage_meter` transforms, and non-iterable metrics can throw in `stacked_bar` (`WidgetCard.tsx:245–246, 281–295, 297–320`). A non-iterable `query.filters.conditions` can also throw when filters are merged (`WidgetCard.tsx:50–58`). Dashboard widget boundaries contain these render failures; query-result behavior depends on the API response, which is outside this packet. Separately, the editor seeds `metrics` from the saved query (`WidgetConfigEditor.tsx:32–34`), and `DataSourcePicker` calls `metrics.includes` (`DataSourcePicker.tsx:63–75`); an object-valued `metrics` crashes when a matching dataset is selected. No builder-local boundary is shown around the editor (`DashboardBuilderPage.tsx:496–505`). **Mitigation:** validate these shapes at their consumers and show a widget/editor-level configuration error rather than allowing the render to throw or silently dropping filters.

3. **Editing can discard persisted query and position extras.** `WidgetConfigEditor` rebuilds the query with only dataset, metrics, dimensions, limit, and offset (`WidgetConfigEditor.tsx:37–45`). The builder replaces the widget’s query with that result (`DashboardBuilderPage.tsx:121–124`); saving an existing dashboard then sends the whole layout through the update path (`DashboardBuilderPage.tsx:171–178`). Thus query fields such as filters, sort, or custom extras can be lost after editing and saving. Also, the parser test explicitly accepts and preserves `position.extra` (`parseLayout.test.ts:41–49`), but `BuilderCanvas` rebuilds position with only `x`, `y`, `w`, and `h` when its layout-change callback runs (`BuilderCanvas.tsx:56–63`). **Mitigation:** merge edited query fields into the existing query, and merge changed coordinates into the existing position.

4. **Dashboard “Reset to default” can leave the displayed error in place.** The action says it recovers the invalid layout, but only mutates `default_dashboard_id` (`DashboardPage.tsx:417–433`). A URL-addressed dashboard takes precedence over preferences (`DashboardPage.tsx:144–153`), so clearing the preference does not change the currently displayed invalid dashboard. If the selected default is also the matching persona clone, clearing the default can select that same config again (`DashboardPage.tsx:158–179`). **Mitigation:** make this action selection-aware—leave a URL-addressed dashboard or avoid presenting the same broken persona clone as the fallback; otherwise label it as clearing the saved selection, not repairing the layout.

### Recovery and boundaries

Builder **Start fresh** itself does not overwrite the saved layout: for parser errors, Save is blocked (`DashboardBuilderPage.tsx:58–60, 306–309`), and Start fresh clears local draft state and `configId` without calling a mutation (`DashboardBuilderPage.tsx:154–166, 431–435`). A subsequent save follows the create path, not the update path (`DashboardBuilderPage.tsx:177–183`). However, nested malformed values that pass `parseLayout` do not set `layoutError`; in particular, an object title can prevent the builder from rendering before its Start fresh UI is usable.

Finite but grid-invalid positions are accepted (the tests include negative, fractional, zero, and negative-size values: `parseLayout.test.ts:41–49`). The dashboard uses them in grid calculations and CSS placement (`DashboardPage.tsx:514–520, 523–538, 556–574`), and the builder passes them to `GridLayout` with size constraints but no explicit normalization (`BuilderCanvas.tsx:40–52`). **No additional crash or destructive overwrite from these positions is established by this snapshot**; the grid-library behavior is not included.

Unknown widget types alone are not shown to crash: the renderer uses a placeholder (`WidgetRenderer.tsx:102–104`), and the parser does not apply the editor/drop allowlist. Extra top-level widget fields survive the builder’s object spreads; the query and position losses above are the demonstrated exceptions.

**Next useful action:** add focused tests for object titles, non-array filters/metrics, editor round-tripping of query extras, position extras after layout changes, and reset behavior on URL-addressed and persona-cloned dashboards.

openai / gpt-6-luna / high / high effort answer

**Conclusion:** The shared envelope guard leaves nested payloads permissive, but most dashboard rendering failures are contained at the individual-widget boundary. I found one clear builder crash path and one misleading dashboard recovery path. Neither recovery action directly overwrites a persisted layout.

- **Builder crash on malformed nested query:** `parseLayout` accepts any `query` value after checking only the widget envelope and finite position coordinates (`parseLayout.ts:21–27`). When a widget has a dataset and `query.metrics` is a non-array object, `WidgetConfigEditor` seeds `metrics` from that value (`WidgetConfigEditor.tsx:32–34`), and `DataSourcePicker` calls `metrics.includes(m)` while rendering (`DataSourcePicker.tsx:70–74`). That value has no `includes` method, so opening the editor with a matching selected dataset can crash the builder. **Smallest safe mitigation:** normalize editor state to arrays before passing it to the picker, or guard the picker’s metrics input.
- **Misleading Reset to default on a URL-addressed dashboard:** `DashboardPage` gives the URL-selected config priority and parses that config directly (`DashboardPage.tsx:144–152`). The error action only clears `default_dashboard_id` (`DashboardPage.tsx:428–433`), so on a malformed `/dashboards/:id` route it leaves the URL-selected dashboard in place and the error remains. **Smallest safe mitigation:** make this action navigate away from the named-dashboard URL as well as clearing the preference, or provide route-specific recovery wording/action.

**Containment and recovery behavior**

- A malformed `config.localFilters` value that is non-iterable can throw when `WidgetCard` spreads it into `allConditions` (`WidgetCard.tsx:40–47`). The card is inside `WidgetErrorBoundary` in the responsive grid (`DashboardPage.tsx:535–538`, `572–574`), so the source supports a per-widget fallback rather than a whole-dashboard crash. Malformed `query.filters.conditions` can similarly fail at the spread in `WidgetCard.tsx:50–57`.
- An object-valued `title` can be accepted by the envelope guard. In the dashboard, it reaches a React child inside the per-widget boundary (`WidgetCard.tsx:179`, `DashboardPage.tsx:535–538`). In the builder, the title is rendered directly without a shown error boundary (`BuilderCanvas.tsx:138–142`); this is another plausible crash path if the title is not a renderable React child.
- Finite but grid-invalid coordinates are accepted, including negative or fractional dimensions (`parseLayout.ts:23–27`; explicitly tested at `parseLayout.test.ts:41–49`). The dashboard uses them in CSS grid calculations (`DashboardPage.tsx:514–520`, `556–570`), and the builder passes them to `GridLayout` (`BuilderCanvas.tsx:40–52`, `98–119`). The packet does not include the grid library’s behavior, so I cannot establish a crash or specific destructive effect from those positions.
- **Neither recovery flow overwrites the saved layout by itself.** Dashboard Reset mutates only the user preference (`DashboardPage.tsx:428–433`). Builder Start fresh clears draft state and the selected config ID (`DashboardBuilderPage.tsx:154–166`); a later save therefore follows the create path rather than updating the prior config (`DashboardBuilderPage.tsx:168–184`). The builder also blocks saving while the loaded layout error remains (`DashboardBuilderPage.tsx:57–60`, `306–309`).

**Unknown types and extra fields:** Unknown types render the placeholder fallback (`WidgetRenderer.tsx:102–104`, `317–322`); the parser does not reject custom types or strip extra fields (`parseLayout.ts:21–27`, `parseLayout.test.ts:41–49`). Editing a widget presents only allowlisted type options (`WidgetConfigEditor.tsx:48–49`, `95–103`), so an explicit type change can replace a legacy type. The editor otherwise spreads existing config on save (`WidgetConfigEditor.tsx:37–45`), and `updateWidget` shallow-merges updates into the widget (`DashboardBuilderPage.tsx:121–125`); the supplied code does not establish a general extra-field loss or automatic custom-type rejection.

**Scope and uncertainty:** The packet omits the grid library implementation and downstream widget implementations; I make no claims about their internal handling. No evidence here establishes malformed database records.

Primary judge's stated reason

A provides a supported, practically important advantage on an explicitly requested outcome: it locates an existing-layout overwrite path and proposes preserving nested fields rather than broadening the parser. Its additional persona-clone reset case and query-transform tracing reinforce coverage. This is a clear coverage advantage, not merely a forced stylistic preference; neither answer demonstrates actual database damage or executed failures.

This reason is the judge's assessment. No independent factual-defect finding is asserted by this record.

Battle wave: fd07e73c-9cd1-42ac-ae73-7a3724f34d1c. Pair: brp1_256baa2813e86a897cc27303cd5754bcc95735ec9165f5b8efe7f8fec30acdfe. A separate independent review is required before calling a concern a verified factual defect. Judge disagreement is not recorded here.