diff --git a/web/frontend/src/DashPublic.root.svelte b/web/frontend/src/DashPublic.root.svelte
index 676e496..36e6703 100644
--- a/web/frontend/src/DashPublic.root.svelte
+++ b/web/frontend/src/DashPublic.root.svelte
@@ -509,44 +509,52 @@
-
-
+ {#if refinedStateData.length > 0}
+
+
+ {#key refinedStateData}
+
sd.count,
+ )}
+ entities={refinedStateData.map(
+ (sd) => sd.state,
+ )}
+ fixColors={refinedStateData.map(
+ (sd) => colors['nodeStates'][sd.state],
+ )}
+ />
+ {/key}
+
+
+
{#key refinedStateData}
-
sd.count,
- )}
- entities={refinedStateData.map(
- (sd) => sd.state,
- )}
- fixColors={refinedStateData.map(
- (sd) => colors['nodeStates'][sd.state],
- )}
- />
- {/key}
-
-
-
- {#key refinedStateData}
-
-
- |
- State |
- Count |
-
- {#each refinedStateData as sd, i}
-
- |
- {sd.state.charAt(0).toUpperCase() + sd.state.slice(1)} |
- {sd.count} |
+
+
+ |
+ State |
+ Count |
- {/each}
-
- {/key}
-
+ {#each refinedStateData as sd, i}
+
+ |
+ {sd.state.charAt(0).toUpperCase() + sd.state.slice(1)} |
+ {sd.count} |
+
+ {/each}
+
+ {/key}
+
+ {:else}
+
+ Cannot render state status: No state data returned for Pie Chart
+
+ {/if}
diff --git a/web/frontend/src/generic/plots/Roofline.svelte b/web/frontend/src/generic/plots/Roofline.svelte
index 53aefee..7b7df31 100644
--- a/web/frontend/src/generic/plots/Roofline.svelte
+++ b/web/frontend/src/generic/plots/Roofline.svelte
@@ -997,5 +997,5 @@
{#if roofData != null}
{:else}
- Cannot render roofline: No data!
+ Cannot render roofline: No data!
{/if}
diff --git a/web/frontend/src/generic/plots/Stacked.svelte b/web/frontend/src/generic/plots/Stacked.svelte
index c9ec1d7..d4babb1 100644
--- a/web/frontend/src/generic/plots/Stacked.svelte
+++ b/web/frontend/src/generic/plots/Stacked.svelte
@@ -101,10 +101,10 @@
};
// Data Prep For uPlot
- const sortedData = data.sort((a, b) => a.state.localeCompare(b.state));
+ const sortedData = data?.sort((a, b) => a.state.localeCompare(b.state)) || [];
const collectLabel = sortedData.map(d => d.state);
// Align Data to Timesteps, Introduces 'undefied' as placeholder, reiterate and set those to 0
- const collectData = uPlot.join(sortedData.map(d => [d.times, d.counts])).map(d => d.map(i => i ? i : 0));
+ const collectData = (sortedData.length > 0) ? uPlot.join(sortedData.map(d => [d.times, d.counts])).map(d => d.map(i => i ? i : 0)) : [];
// STACKED CHART FUNCTIONS //
function stack(data, omit) {
@@ -344,7 +344,7 @@
-{#if data && collectData[0].length > 0}
+{#if data && collectData.length > 0}
diff --git a/web/frontend/src/status/DashInternal.svelte b/web/frontend/src/status/DashInternal.svelte
index c6abf06..47a841a 100644
--- a/web/frontend/src/status/DashInternal.svelte
+++ b/web/frontend/src/status/DashInternal.svelte
@@ -487,45 +487,51 @@
-
-
-
-
- Top Projects: Jobs
-
-
tp['totalJobs'],
- )}
- entities={$topJobsQuery.data.jobsStatistics.map((tp) => scrambleNames ? scramble(tp.id) : tp.id)}
- />
-
-
-
-
-
- |
- Project |
- Jobs |
-
- {#each $topJobsQuery.data.jobsStatistics as tp, i}
-
- |
-
- {scrambleNames ? scramble(tp.id) : tp.id}
-
- |
- {tp['totalJobs']} |
+ {#if topJobsQuery?.data?.jobsStatistics?.length > 0}
+
+
+
+
+ Top Projects: Jobs
+
+
tp['totalJobs'],
+ )}
+ entities={$topJobsQuery.data.jobsStatistics.map((tp) => scrambleNames ? scramble(tp.id) : tp.id)}
+ />
+
+
+
+
+
+ |
+ Project |
+ Jobs |
- {/each}
-
-
-
+ {#each $topJobsQuery.data.jobsStatistics as tp, i}
+
+ |
+
+ {scrambleNames ? scramble(tp.id) : tp.id}
+
+ |
+ {tp['totalJobs']} |
+
+ {/each}
+
+
+
+ {:else}
+ Cannot render job status: No state data returned for Pie Chart
+ {/if}