Skip to content

Commit 830020d

Browse files
authored
fix(site): don't mark metadata with interval: 0 as stale (#8627)
1 parent 1cb39fc commit 830020d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

site/src/components/Resources/AgentMetadata.tsx

+4-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,10 @@ const MetadataItem: FC<{ item: WorkspaceAgentMetadata }> = ({ item }) => {
3131
if (year <= 1970 || isNaN(year)) {
3232
return "loading"
3333
}
34-
if (item.result.age > staleThreshold) {
34+
// There is a special circumstance for metadata with `interval: 0`. It is
35+
// expected that they run once and never again, so never display them as
36+
// stale.
37+
if (item.result.age > staleThreshold && item.description.interval > 0) {
3538
return "stale"
3639
}
3740
return "valid"

0 commit comments

Comments
 (0)