Align Physical Disk stale-reading Help across FAQ, TrueNAS, and Agent (#5339)

Update docs/FAQ.md, docs/TRUENAS.md, docs/UNIFIED_AGENT.md, and their
mirrored in-app Help copies under frontend-modern/public/docs/ to match
Pulse #5333 (20146aa2de):

- Document canonical source-staleness cues for Physical Disks on Storage
tables, linked storage-pool disk rows, and Physical Disks & SMART cards
  in guest, machine, and host drawers.
- Document amber Stale health verdicts for clear stale disks (excluded
  from Healthy, included in Attention and Warning, sorted ahead of fresh
  healthy disks) and inline amber Stale data cues beneath the disk name
  for worse Replace Now and Needs Attention verdicts.
- Document muted last-known temperature and SSD Life remaining styling
  (preventing live Running Hot verdicts), stale search indexing, the
DiskDrawerOverview inline warning notice, Last known temperature health
  card wording, and deferred temperature/SMART history charts until live
  reporting recovers.
- Bind these Help updates to live frontend source in
  scripts/tests/test_stale_reading_help_docs.py.

Contract-Neutral: Documentation, mirrored in-app Help, and documentation
consistency tests only; no runtime, API, polling, alert, telemetry, or
route contract changes.

---
Fleet candidate `20261128T012936Z-product-intelligence` from the
`product-intelligence` lane. Reviewed tip
`aea6d34cc34bdf9d563a881638514226177f7819` on `main`.

[How Pulse handles
triage](https://github.com/rcourtman/Pulse/blob/main/docs/AI_TRANSPARENCY.md)
This commit is contained in:
pulse-triage[bot]
2026-11-28 02:01:47 +00:00
committed by GitHub
7 changed files with 157 additions and 2 deletions

View File

@@ -428,6 +428,24 @@ does not prove that every reading is fresh. Missing or unavailable is not zero.
drawers across images, volumes, engine storage usage and networks display the
same inline Docker stale-readings notice and freshness-aware status indicator
until live reporting recovers.
- **Physical disks** (on Storage disk tables, linked storage-pool disk rows, and
**Physical Disks & SMART** cards in guest, machine, and host drawers) surface
source staleness when a host agent, Proxmox poller, or TrueNAS source stops
updating or hits a collection error. Clear stale disks switch from **Healthy**
or **Online** to amber **Stale**, leave the **Healthy** filter, join
**Attention** and **Warning**, and sort ahead of fresh healthy disks. Worse
verdicts (**Replace Now** and **Needs Attention**) stay visible with an inline
amber **Stale data** cue beneath the disk name (or beside the health label in
guest, machine, and host drawers). Stale temperatures and SSD **Life
remaining** percentages render in muted dotted-underline last-known styling
and never trigger a live **Running Hot** verdict. Physical disk search matches
`stale`, `stale data`, refresh age, and recorded source error text, and
expanding a stale disk shows an amber inline notice (`Stale data. Retained
last-known disk readings.` with the last refresh age and source error when
present, plus `Health, temperature, and SMART readings reflect the last report
received and may no longer be current.`), labels the health card **Last known
temperature**, and defers temperature and SMART history charts as last-known
values until live reporting recovers.
Use the relevant checks for [stale TrueNAS data](TRUENAS.md#stale-truenas-data),
[stale Kubernetes readings](KUBERNETES.md#stale-kubernetes-readings),

View File

@@ -188,7 +188,16 @@ while TrueNAS still reports the condition.
use the saved per-disk temperature override, then the TrueNAS-wide default,
then the inherited agent/by-type policy. An Off or disabled temperature policy
leaves the reading visible but unjudged; a last known reading is never current
heat. A display mismatch is not proof that your saved rule failed. Compare the same disk, observation time and saved threshold with
heat. When TrueNAS polling goes stale or hits a collection error, clear physical
disks switch from **Healthy** to amber **Stale** (leaving the **Healthy** filter
and joining **Attention** and **Warning**), while **Replace Now** and **Needs
Attention** verdicts stay visible with an inline amber **Stale data** cue
beneath the disk name. Stale temperatures and SSD **Life remaining** values
render as muted last-known readings without triggering **Running Hot**, disk
search matches stale labels and source errors, and expanding the disk shows an
amber notice (`Stale data. Retained last-known disk readings.`) while deferring
temperature and SMART history charts as last-known values until live polling
recovers. A display mismatch is not proof that your saved rule failed. Compare the same disk, observation time and saved threshold with
its existing TrueNAS reading and SMART state; do not raise thresholds, run new
SMART tests, force a probe or restart merely to make the views agree.

View File

@@ -907,6 +907,7 @@ The agent can report S.M.A.R.T. disk temperatures, health status, identity, and
**Notes:**
- Disks in standby mode are reported as such (no temperature) to avoid waking them
- S.M.A.R.T. data is collected alongside other host metrics and can enrich the Physical Disks view with temperature, stable disk identity, power-on hours, SSD life, pending sectors, media errors, and related counters
- When a host agent stops updating or hits a collection error, Physical Disks (and **Physical Disks & SMART** cards inside guest, machine, and host drawers) switch clear disks from **Healthy** or **Online** to amber **Stale** (moving them out of **Healthy** into **Attention** and **Warning**), keep **Replace Now** and **Needs Attention** verdicts visible with an inline amber **Stale data** cue, style stale temperatures and SSD **Life remaining** as muted last-known values so they never trigger **Running Hot**, and display an inline `Stale data. Retained last-known disk readings.` notice while deferring temperature and SMART history charts until fresh agent reports arrive
- If `smartctl` is not available, S.M.A.R.T. monitoring is silently skipped
- **Disk exclusions** (`--disk-exclude` / `PULSE_DISK_EXCLUDE`) also apply to S.M.A.R.T. monitoring.
Use patterns like `sda`, `/dev/sdb`, `nvme*`, or `*cache*` to exclude specific block devices.

View File

@@ -428,6 +428,24 @@ does not prove that every reading is fresh. Missing or unavailable is not zero.
drawers across images, volumes, engine storage usage and networks display the
same inline Docker stale-readings notice and freshness-aware status indicator
until live reporting recovers.
- **Physical disks** (on Storage disk tables, linked storage-pool disk rows, and
**Physical Disks & SMART** cards in guest, machine, and host drawers) surface
source staleness when a host agent, Proxmox poller, or TrueNAS source stops
updating or hits a collection error. Clear stale disks switch from **Healthy**
or **Online** to amber **Stale**, leave the **Healthy** filter, join
**Attention** and **Warning**, and sort ahead of fresh healthy disks. Worse
verdicts (**Replace Now** and **Needs Attention**) stay visible with an inline
amber **Stale data** cue beneath the disk name (or beside the health label in
guest, machine, and host drawers). Stale temperatures and SSD **Life
remaining** percentages render in muted dotted-underline last-known styling
and never trigger a live **Running Hot** verdict. Physical disk search matches
`stale`, `stale data`, refresh age, and recorded source error text, and
expanding a stale disk shows an amber inline notice (`Stale data. Retained
last-known disk readings.` with the last refresh age and source error when
present, plus `Health, temperature, and SMART readings reflect the last report
received and may no longer be current.`), labels the health card **Last known
temperature**, and defers temperature and SMART history charts as last-known
values until live reporting recovers.
Use the relevant checks for [stale TrueNAS data](TRUENAS.md#stale-truenas-data),
[stale Kubernetes readings](KUBERNETES.md#stale-kubernetes-readings),

View File

@@ -188,7 +188,16 @@ while TrueNAS still reports the condition.
use the saved per-disk temperature override, then the TrueNAS-wide default,
then the inherited agent/by-type policy. An Off or disabled temperature policy
leaves the reading visible but unjudged; a last known reading is never current
heat. A display mismatch is not proof that your saved rule failed. Compare the same disk, observation time and saved threshold with
heat. When TrueNAS polling goes stale or hits a collection error, clear physical
disks switch from **Healthy** to amber **Stale** (leaving the **Healthy** filter
and joining **Attention** and **Warning**), while **Replace Now** and **Needs
Attention** verdicts stay visible with an inline amber **Stale data** cue
beneath the disk name. Stale temperatures and SSD **Life remaining** values
render as muted last-known readings without triggering **Running Hot**, disk
search matches stale labels and source errors, and expanding the disk shows an
amber notice (`Stale data. Retained last-known disk readings.`) while deferring
temperature and SMART history charts as last-known values until live polling
recovers. A display mismatch is not proof that your saved rule failed. Compare the same disk, observation time and saved threshold with
its existing TrueNAS reading and SMART state; do not raise thresholds, run new
SMART tests, force a probe or restart merely to make the views agree.

View File

@@ -907,6 +907,7 @@ The agent can report S.M.A.R.T. disk temperatures, health status, identity, and
**Notes:**
- Disks in standby mode are reported as such (no temperature) to avoid waking them
- S.M.A.R.T. data is collected alongside other host metrics and can enrich the Physical Disks view with temperature, stable disk identity, power-on hours, SSD life, pending sectors, media errors, and related counters
- When a host agent stops updating or hits a collection error, Physical Disks (and **Physical Disks & SMART** cards inside guest, machine, and host drawers) switch clear disks from **Healthy** or **Online** to amber **Stale** (moving them out of **Healthy** into **Attention** and **Warning**), keep **Replace Now** and **Needs Attention** verdicts visible with an inline amber **Stale data** cue, style stale temperatures and SSD **Life remaining** as muted last-known values so they never trigger **Running Hot**, and display an inline `Stale data. Retained last-known disk readings.` notice while deferring temperature and SMART history charts until fresh agent reports arrive
- If `smartctl` is not available, S.M.A.R.T. monitoring is silently skipped
- **Disk exclusions** (`--disk-exclude` / `PULSE_DISK_EXCLUDE`) also apply to S.M.A.R.T. monitoring.
Use patterns like `sda`, `/dev/sdb`, `nvme*`, or `*cache*` to exclude specific block devices.

View File

@@ -626,6 +626,105 @@ class StaleReadingAndAgentHelpDocsTest(unittest.TestCase):
self.assertIn("ReportEncodedBodyLimitBytes int64 = 2 * 1024 * 1024", report_limits)
self.assertIn("ReportDecodedBodyLimitBytes int64 = 10 * 1024 * 1024", report_limits)
def test_help_documents_physical_disk_stale_readings_across_storage_and_drawers(self):
faq = doc_text("docs/FAQ.md")
faq_section = norm(
faq.split("### No data showing?\n", 1)[1].split("\n### ", 1)[0]
)
for phrase in (
"**Physical disks**",
"**Physical Disks & SMART** cards in guest, machine, and host drawers",
"switch from **Healthy** or **Online** to amber **Stale**",
"leave the **Healthy** filter, join **Attention** and **Warning**, and sort ahead of fresh healthy disks",
"Worse verdicts (**Replace Now** and **Needs Attention**) stay visible with an inline amber **Stale data** cue beneath the disk name",
"Stale temperatures and SSD **Life remaining** percentages render in muted dotted-underline last-known styling and never trigger a live **Running Hot** verdict",
"Physical disk search matches `stale`, `stale data`, refresh age, and recorded source error text",
"`Stale data. Retained last-known disk readings.`",
"`Health, temperature, and SMART readings reflect the last report received and may no longer be current.`",
"labels the health card **Last known temperature**, and defers temperature and SMART history charts as last-known values until live reporting recovers",
):
with self.subTest(doc="FAQ.md", phrase=phrase):
self.assertIn(phrase, faq_section)
truenas = doc_text("docs/TRUENAS.md")
truenas_disk = norm(
truenas.split("## Disk temperature and health\n", 1)[1].split(
"## Multiple TrueNAS Systems", 1
)[0]
)
for phrase in (
"switch from **Healthy** to amber **Stale** (leaving the **Healthy** filter and joining **Attention** and **Warning**)",
"**Replace Now** and **Needs Attention** verdicts stay visible with an inline amber **Stale data** cue beneath the disk name",
"Stale temperatures and SSD **Life remaining** values render as muted last-known readings without triggering **Running Hot**",
"`Stale data. Retained last-known disk readings.`",
"deferring temperature and SMART history charts as last-known values until live polling recovers",
):
with self.subTest(doc="TRUENAS.md", phrase=phrase):
self.assertIn(phrase, truenas_disk)
unified = doc_text("docs/UNIFIED_AGENT.md")
smart_section = norm(
unified.split("## S.M.A.R.T. Disk Health\n", 1)[1].split(
"\n## Auto-Update", 1
)[0]
)
for phrase in (
"**Physical Disks & SMART** cards inside guest, machine, and host drawers",
"switch clear disks from **Healthy** or **Online** to amber **Stale**",
"keep **Replace Now** and **Needs Attention** verdicts visible with an inline amber **Stale data** cue",
"style stale temperatures and SSD **Life remaining** as muted last-known values so they never trigger **Running Hot**",
"`Stale data. Retained last-known disk readings.`",
"deferring temperature and SMART history charts until fresh agent reports arrive",
):
with self.subTest(doc="UNIFIED_AGENT.md", phrase=phrase):
self.assertIn(phrase, smart_section)
disk_pres = doc_text("frontend-modern/src/features/storageBackups/diskPresentation.ts")
disk_temp = doc_text(
"frontend-modern/src/features/storageBackups/diskTemperaturePresentation.ts"
)
disk_drawer = doc_text(
"frontend-modern/src/features/storageBackups/diskDrawerPresentation.ts"
)
disk_list = doc_text("frontend-modern/src/components/Storage/DiskList.tsx")
disk_overview = doc_text("frontend-modern/src/components/Storage/DiskDrawerOverview.tsx")
guest_disks = doc_text("frontend-modern/src/components/Workloads/GuestPhysicalDisks.tsx")
pool_detail = doc_text(
"frontend-modern/src/features/storageBackups/storagePoolDetailPresentation.ts"
)
for marker in (
"export function extractPhysicalDiskFreshness(resource: Resource)",
"return `Retained last-known disk readings.${age}${error}`.trim();",
"disk.freshness === 'stale' ? 'stale stale data' : ''",
"label: 'Stale'",
"if (verdict.kind === 'attention' || disk.freshness === 'stale') return 'warning';",
"return disk.freshness === 'stale' ? 100 : 0;",
):
self.assertIn(marker, disk_pres)
for marker in (
"if (freshness === 'stale') return false;",
"if (!isPhysicalDiskTemperatureCurrent(disk.collection, disk.freshness)) return false;",
):
self.assertIn(marker, disk_temp)
for marker in (
"if (disk.freshness === 'stale') return {};",
"if (disk.freshness === 'stale') {",
"temperature.current ? 'Temperature' : 'Last known temperature'",
):
self.assertIn(marker, disk_drawer)
self.assertIn("data-disk-stale-cue", disk_list)
self.assertIn('data-life-reading={isStale() ? \'last-known\' : \'current\'}', disk_list)
for marker in (
'data-testid="disk-drawer-stale-notice"',
'<span class="font-medium">Stale data.</span>',
"Health, temperature, and",
"SMART readings reflect the last report received and may no longer be current.",
):
self.assertIn(marker, disk_overview)
self.assertIn("data-disk-stale-cue", guest_disks)
self.assertIn("extractPhysicalDiskFreshness(disk)", pool_detail)
def test_shipped_public_docs_mirrors_match_byte_for_byte(self):
for name in (
"AGENT_SECURITY.md",