Skip to content

Fix missing Live report tooltip for locked hosts - #54509

Merged
nulmete merged 1 commit into
fleetdm:mainfrom
Prajwal2246:fix/54482-locked-host-live-report-tooltip
Oct 1, 2026
Merged

nulmete merged 1 commit into
fleetdm:mainfrom
Prajwal2246:fix/54482-locked-host-live-report-tooltip

Conversation

@Prajwal2246

@Prajwal2246 Prajwal2246 commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

Related issue: Resolves #54482

On an online, locked host, Actions > Live report is disabled without explaining why. Add tooltips for locked, wiped, and updating device states using the existing dropdown tooltip helper. The offline explanation and action availability stay unchanged.

Checklist for submitter

  • Changes file added for user-visible changes in changes/, orbit/changes/ or ee/fleetd-chrome/changes.
    See Changes files for more information.

Testing

  • Added/updated automated tests

  • QA'd all new/changed functionality manually

Automated validation:

  • HostActionsDropdown Jest suite: 121 tests passed. The locked-host tooltip regression failed before the fix.
  • ESLint and Prettier passed for both changed frontend files; git diff --check passed.
  • Tests cover online locked/wiped hosts and the locking, unlocking, wiping, and clearing-passcode states. Existing offline coverage passes.

Manual validation:

  • Confirmed the disabled Live report tooltip in the local browser using a mocked locked host state.
  • No physical device was locked. Temporary preview code was removed and is not included in this PR.
  • Wiped and updating states are covered by automated tests, not manual browser verification.

CI note: The lint-js failure reports five import-formatting errors in frontend/pages/admin/ManageFleetsPage/TeamDetailsWrapper/AgentOptionsPage/AgentOptionsPage.tests.tsx. That file is unchanged by this PR and identical to the base commit aa90e843ed. The JavaScript test job passes.

AI

AI: Codex (unknown)

Frontend

  • Attached a screenshot or screen recording of each user-visible change. For changes to existing UI, show the before and after.

Before — screenshot from the original report in #54482: the disabled Live report action has no tooltip.

Before: disabled Live report without an explanation

After — local recording using a mocked locked host state: hovering over the disabled Live report action shows "You can't run a live report on a locked host." No device was physically locked.

Screen.Recording.2026-10-01.at.12.29.36.PM.mov

The recording covers the locked-host case. Wiped and updating states are covered by automated tests; their manual browser checks remain pending.

Summary by CodeRabbit

  • Bug Fixes
    • Live report is now disabled for online hosts that are locked, wiped, or undergoing a device-status update, with a tooltip explaining why.

@codecov

codecov Bot commented Oct 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 76.56%. Comparing base (aa90e84) to head (6774586).

Additional details and impacted files
@@           Coverage Diff            @@
##             main   #54509    +/-   ##
========================================
  Coverage   76.56%   76.56%            
========================================
  Files        4261     4261            
  Lines      260385   260390     +5     
  Branches    15067    15240   +173     
========================================
+ Hits       199365   199370     +5     
+ Misses      60843    60842     -1     
- Partials      177      178     +1     
Flag Coverage Δ
frontend 69.46% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Prajwal2246
Prajwal2246 marked this pull request as ready for review October 1, 2026 07:09
@Prajwal2246
Prajwal2246 requested a review from a team as a code owner October 1, 2026 07:09
@coderabbitai

coderabbitai Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: fleetdm/fleet/.coderabbit.yaml

Review profile: CHILL

Plan: Advanced

Run ID: 265d1c6f-ead2-4bc0-b375-d8df0ad75ba7

📥 Commits

Reviewing files that changed from the base of the PR and between aa90e84 and 6774586.

📒 Files selected for processing (3)
  • changes/54482-live-report-disabled-tooltip
  • frontend/pages/hosts/details/HostDetailsPage/HostActionsDropdown/HostActionsDropdown.tests.tsx
  • frontend/pages/hosts/details/HostDetailsPage/HostActionsDropdown/helpers.tsx

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.


Walkthrough

Live report tooltip generation now receives the host’s MDM device status. For online hosts, it provides status-specific messages when the host is locked or wiped, and an updating-status message when the device status is updating. The existing offline-host tooltip remains. Tests cover six device statuses and verify the disabled state and tooltip text.

Priority: ⬇️ Low

Severity of issue fixed: Low

Merge Risk: ⚪ Minimal · up to 67745

The change explains why Live report is unavailable for locked, wiped, and updating hosts while preserving existing offline explanations and action availability. No merge-blocking issue is identified.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the primary change: restoring the missing Live report tooltip for locked hosts.
Description check ✅ Passed The description identifies the related issue, explains the behavior change, documents testing and manual validation, includes the required AI section, and provides frontend evidence. It also clearly n…
Linked Issues check ✅ Passed PR #54509 satisfies the coding requirement in [#54482]. getDropdownOptionTooltipContent now receives hostMdmDeviceStatus, and disabled online Live report options receive status-specific text for `…
Out of Scope Changes check ✅ Passed The changes stay within [#54482]. The helper update, tooltip tests, and change note support the disabled Live report behavior. The additional wiped and updating tooltips cover the same disabled states…
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2…
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Comment on lines 702 to +719
if (!isHostOnline && value === "query") {
return <>You can&apos;t run a live report on an offline host.</>;
}
if (value === "query") {
if (hostMdmDeviceStatus === "locked" || hostMdmDeviceStatus === "wiped") {
return (
<>You can&apos;t run a live report on a {hostMdmDeviceStatus} host.</>
);
}
if (hostMdmDeviceStatus && isDeviceStatusUpdating(hostMdmDeviceStatus)) {
return (
<>
You can&apos;t run a live report while the host&apos;s device status
is updating.
</>
);
}
}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: should we have a single if (value === "query") { ... } block so we can group all the tooltip contents in that same block?

@nulmete

nulmete commented Oct 1, 2026

Copy link
Copy Markdown
Member

Thanks @Prajwal2246 !

@nulmete
nulmete merged commit 9118ef3 into fleetdm:main Oct 1, 2026
28 of 30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Host details: disabled Live report action has no tooltip when the host is locked

2 participants