nucleus-core-ts 0.9.930 → 0.9.932

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/.build-ok CHANGED
@@ -1 +1 @@
1
- 0.9.930
1
+ 0.9.932
@@ -28,6 +28,12 @@ export function RunHistoryRow({ run, actions, onReverted }) {
28
28
  const readClock = useEffectEvent(()=>{
29
29
  setNowMs(Date.now());
30
30
  });
31
+ /*
32
+ * De-duplicated: a run that fails on every record of a page records the same
33
+ * sentence many times, and forty identical lines say no more than one.
34
+ */ const failureReasons = [
35
+ ...new Set((run.errors ?? []).map((e)=>String(e).trim()).filter(Boolean))
36
+ ];
31
37
  useEffect(()=>{
32
38
  readClock();
33
39
  }, []);
@@ -101,6 +107,19 @@ export function RunHistoryRow({ run, actions, onReverted }) {
101
107
  className: theme.field.hint,
102
108
  children: `${formatMoment(run.startedAt ?? run.createdAt)} · took ${formatDuration(run.startedAt, run.finishedAt)} · ${run.totalFetched} fetched`
103
109
  }),
110
+ failureReasons.length > 0 ? /*#__PURE__*/ _jsxs("div", {
111
+ className: "flex flex-col gap-1",
112
+ children: [
113
+ /*#__PURE__*/ _jsx("span", {
114
+ className: theme.field.hint,
115
+ children: labels.errors.whyItFailed
116
+ }),
117
+ failureReasons.map((reason)=>/*#__PURE__*/ _jsx("p", {
118
+ className: cn(theme.field.hint, 'text-[var(--nx-danger,#dc2626)]'),
119
+ children: reason
120
+ }, reason))
121
+ ]
122
+ }) : null,
104
123
  undoable ? /*#__PURE__*/ _jsxs("div", {
105
124
  className: "flex flex-wrap items-center gap-2",
106
125
  children: [
@@ -497,6 +497,8 @@ export type IntegrationsLabels = {
497
497
  cancelRejected: string;
498
498
  cancelFailed: string;
499
499
  runFailed: string;
500
+ /** Heading above the reason a run failed, in its history entry. */
501
+ whyItFailed: string;
500
502
  overwriteAnyway: string;
501
503
  stageReading: string;
502
504
  stageValidating: string;
@@ -451,6 +451,7 @@
451
451
  cancelRejected: 'The run did not accept the cancel request.',
452
452
  cancelFailed: 'The cancel request failed.',
453
453
  runFailed: 'The import failed. Its history entry has the detail.',
454
+ whyItFailed: 'Why it failed',
454
455
  overwriteAnyway: 'Overwrite them anyway',
455
456
  stageReading: 'Reading from the source',
456
457
  stageValidating: 'Validating records',