plugins/home-assistant-dev/skills/ha-repairs/SKILL.md
Implement repair issues for Home Assistant integrations. Gold tier IQS requirement. Use when asked about repair issues, issue registry, user notifications, fixable issues, or actionable alerts.
npx skillsauth add l3digital-net/claude-code-plugins ha-repairsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Repair issues provide actionable notifications to users about problems that require attention. Gold tier IQS requirement.
Use repair issues for:
Do NOT use for:
available property)from homeassistant.helpers import issue_registry as ir
# Create an issue
ir.async_create_issue(
hass,
DOMAIN,
"firmware_update_available",
is_fixable=False,
severity=ir.IssueSeverity.WARNING,
translation_key="firmware_update_available",
translation_placeholders={
"current_version": "1.0.0",
"new_version": "2.0.0",
},
)
from homeassistant.helpers.issue_registry import IssueSeverity
IssueSeverity.CRITICAL # Immediate action required
IssueSeverity.ERROR # Something is broken
IssueSeverity.WARNING # Should be addressed soon
User must take action outside Home Assistant:
ir.async_create_issue(
hass,
DOMAIN,
"device_firmware_outdated",
is_fixable=False,
severity=ir.IssueSeverity.WARNING,
translation_key="device_firmware_outdated",
translation_placeholders={
"device": device_name,
"version": current_version,
},
learn_more_url="https://example.com/firmware-update",
)
User can fix directly in Home Assistant:
# In __init__.py or where issue is detected
ir.async_create_issue(
hass,
DOMAIN,
f"reauth_required_{entry.entry_id}",
is_fixable=True,
severity=ir.IssueSeverity.ERROR,
translation_key="reauth_required",
data={"entry_id": entry.entry_id},
)
# repairs.py
from homeassistant import data_entry_flow
from homeassistant.components.repairs import RepairsFlow
class ReauthRequiredRepairFlow(RepairsFlow):
"""Handler for reauth repair flow."""
async def async_step_init(
self, user_input: dict[str, Any] | None = None
) -> data_entry_flow.FlowResult:
"""Handle the first step."""
return await self.async_step_confirm()
async def async_step_confirm(
self, user_input: dict[str, Any] | None = None
) -> data_entry_flow.FlowResult:
"""Handle the confirm step."""
if user_input is not None:
entry_id = self.data["entry_id"]
entry = self.hass.config_entries.async_get_entry(entry_id)
if entry:
self.hass.async_create_task(
self.hass.config_entries.flow.async_init(
DOMAIN,
context={"source": "reauth", "entry_id": entry_id},
)
)
return self.async_create_entry(data={})
return self.async_show_form(step_id="confirm")
async def async_create_fix_flow(
hass: HomeAssistant,
issue_id: str,
data: dict[str, Any] | None,
) -> RepairsFlow:
"""Create flow."""
if issue_id.startswith("reauth_required_"):
return ReauthRequiredRepairFlow()
raise ValueError(f"Unknown issue: {issue_id}")
{
"issues": {
"firmware_update_available": {
"title": "Firmware update available",
"description": "Device {device} has firmware {current_version}. Version {new_version} is available with important fixes."
},
"reauth_required": {
"title": "Re-authentication required",
"fix_flow": {
"step": {
"confirm": {
"title": "Re-authenticate",
"description": "Your credentials have expired. Click submit to re-authenticate."
}
}
}
}
}
}
# Remove when issue is resolved
ir.async_delete_issue(hass, DOMAIN, "firmware_update_available")
# Remove all issues for an entry (e.g., on unload)
ir.async_delete_issue(hass, DOMAIN, f"reauth_required_{entry.entry_id}")
# coordinator.py
class MyCoordinator(DataUpdateCoordinator):
async def _async_update_data(self):
try:
data = await self.client.async_get_data()
# Check for conditions that need user attention
if data.get("firmware_update_available"):
ir.async_create_issue(
self.hass,
DOMAIN,
f"firmware_{self.config_entry.entry_id}",
is_fixable=False,
severity=ir.IssueSeverity.WARNING,
translation_key="firmware_update",
translation_placeholders={
"current": data["firmware_version"],
"available": data["available_version"],
},
)
else:
# Clear issue if no longer applicable
ir.async_delete_issue(
self.hass,
DOMAIN,
f"firmware_{self.config_entry.entry_id}",
)
return data
except AuthenticationError:
ir.async_create_issue(
self.hass,
DOMAIN,
f"auth_{self.config_entry.entry_id}",
is_fixable=True,
severity=ir.IssueSeverity.ERROR,
translation_key="authentication_failed",
)
raise ConfigEntryAuthFailed
ha-config-flowha-coordinatorha-quality-reviewdevelopment
Use when you're stuck or missing current information mid-task - the same command/API/approach failed twice, an error looks like a changed or deprecated API, or you need the current version of something, a fact from after your training cutoff, or to verify something you cannot confirm from the code in context. Starts with a cheap inline lookup and only escalates to a full research sweep if that fails. Do not use for routine pre-emptive checks before ordinary library work - for deliberate research, use /qdev:research.
documentation
Update Outline wiki documentation with implementation-level details from the current session by dispatching the up-docs-propagate-wiki sub-agent. This skill should be used when the user runs /up-docs:wiki.
documentation
Update repository documentation (README.md, docs/, CLAUDE.md) based on session changes by dispatching the up-docs-propagate-repo sub-agent. This skill should be used when the user runs /up-docs:repo.
documentation
Update Notion pages with strategic and organizational context from the current session by dispatching the up-docs-propagate-notion sub-agent. This skill should be used when the user runs /up-docs:notion.