Skip to content

Codex: Review and refactor#80

Open
Obscuretone wants to merge 1 commit intomaxi1134:masterfrom
Obscuretone:codex-review
Open

Codex: Review and refactor#80
Obscuretone wants to merge 1 commit intomaxi1134:masterfrom
Obscuretone:codex-review

Conversation

@Obscuretone
Copy link

Summary

This change is a repo-wide review and cleanup pass focused on accuracy, maintainability, and config drift across the Home Assistant setup.

It fixes a handful of stale/broken references, improves a few template sensors and automations, cleans up old dead config paths, and updates documentation so the repo better matches the current live setup.

What changed

  • Fixed stale entity references that no longer matched the current setup.

    • Replaced the old sensor.maxi_location_by_petro_v2 reference with sensor.maxi_location_by_petro.
    • Replaced old vacuum.xiaomi_vacuum_cleaner references with vacuum.roborock_qrevo_curv_series where appropriate.
  • Fixed automation/script behavior that was incorrect or misleading.

    • Reworked the live concert automation so it actually waits for input_boolean.live_concert to turn off before restoring the tablet interfaces.
    • Removed invalid empty wait_for_trigger: [] behavior from the broadcast script.
    • Fixed the paused-TV shutdown logic so it turns off all targeted Chromecast devices instead of using an invalid repeat index outside the loop.
  • Improved template sensor correctness and metadata.

    • Updated Outside Temperature with Fallback to return a safer fallback value and use proper temperature metadata.
    • Updated Maxi current Activity V2 to use the current Roborock cleaning state instead of the old Xiaomi vacuum entity.
    • Removed outside humidity from Average House Humidity so the sensor better reflects indoor conditions.
  • Reduced config drift and dead paths.

    • Moved the legacy includes/automations.yaml file out of the active path to includes/automations.yaml.unused so edits are less likely to land in a dead file.
    • Updated Dwains Dashboard and Lovelace references to current entities.
    • Corrected AppDaemon location metadata to match the actual timezone/location pairing.
  • Cleaned up repo documentation.

    • Fixed broken README/doc links.
    • Added a placeholder wip list.md so the README no longer points to a missing file.
    • Added a small node-red/README.md to document that old Node-RED flow exports are no longer tracked.

Intentional TODOs / preserved behavior

Some existing behavior was intentionally preserved even though it is not ideal, because it is still relied on today. These are now marked with TODO comments so they can be called out and cleaned up later:

  • Plex token is still exposed through Home Assistant state for the dashboard card.
  • Reolink PTZ token is still published through Home Assistant state.
  • ESPresense floorplan MQTT password is still stored in browser localStorage.

These behaviors were preserved on purpose for compatibility and should be treated as follow-up security debt.

Validation

  • Parsed updated YAML files successfully
  • Parsed updated Lovelace JSON successfully
  • appdaemon/apps/get_token.py compiles successfully
  • Markdown link audit passed

I could not run a full Home Assistant ha core check in this workspace because the HA CLI/runtime is not available locally.

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.

1 participant