Skip to content

Add Casper Glow integration#164536

Open
mikeodr wants to merge 1 commit intohome-assistant:devfrom
mikeodr:casper-glow-integration
Open

Add Casper Glow integration#164536
mikeodr wants to merge 1 commit intohome-assistant:devfrom
mikeodr:casper-glow-integration

Conversation

@mikeodr
Copy link
Contributor

@mikeodr mikeodr commented Mar 1, 2026

Proposed change

Add a new integration for Casper Glow Bluetooth controllable lights.

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New integration (thank you!)
  • New feature (which adds functionality to an existing integration)
  • Deprecation (breaking change to happen in the future)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Additional information

Checklist

  • I understand the code I am submitting and can explain how it works.
  • The code change is tested and works locally.
  • Local tests pass. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist
  • I have followed the perfect PR recommendations
  • The code has been formatted using Ruff (ruff format homeassistant tests)
  • Tests have been added to verify that the new code works.
  • Any generated code has been carefully reviewed for correctness and compliance with project standards.

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • The manifest file has all fields filled out correctly.
    Updated and included derived files by running: python3 -m script.hassfest.
  • New or updated dependencies have been added to requirements_all.txt.
    Updated by running python3 -m script.gen_requirements_all.
  • For the updated dependencies a diff between library versions and ideally a link to the changelog/release notes is added to the PR description.

To help with the load of incoming pull requests:

Quality Checklist

Bronze

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds a new Home Assistant integration (casper_glow) to control Casper Glow Bluetooth lights, including a config flow, coordinator-based state handling, services, and full test coverage.

Changes:

  • Introduces the casper_glow integration (manifest, config flow, coordinator, entity + light platform, services, strings/icons, quality scale).
  • Adds comprehensive tests for config flow, setup/unload, coordinator polling/logging, light behavior, and snapshots.
  • Updates generated registries and dependency/type-checking configuration (requirements, mypy, strict-typing, generated bluetooth/config flow lists, CODEOWNERS).

Reviewed changes

Copilot reviewed 25 out of 28 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
homeassistant/components/casper_glow/__init__.py Integration setup/unload, BLE device lookup, coordinator startup, service registration, device removal hook
homeassistant/components/casper_glow/config_flow.py Bluetooth + user config flow for selecting and handshaking with a discovered device
homeassistant/components/casper_glow/const.py Domain constants, brightness mapping, polling interval, service names
homeassistant/components/casper_glow/coordinator.py Active Bluetooth coordinator for polling state + tracking BLE device updates
homeassistant/components/casper_glow/entity.py Shared entity base with device info and command error handling/logging
homeassistant/components/casper_glow/light.py Light entity implementation (on/off, brightness mapping, pause/resume)
homeassistant/components/casper_glow/manifest.json Declares the integration, BLE matching, dependency, requirements, quality scale
homeassistant/components/casper_glow/models.py Runtime-data model (CasperGlowData) and typed config entry alias
homeassistant/components/casper_glow/quality_scale.yaml Quality scale rule tracking for the integration
homeassistant/components/casper_glow/services.yaml Service target definitions for pause/resume
homeassistant/components/casper_glow/strings.json User-facing strings for config flow, exceptions, and services
homeassistant/components/casper_glow/icons.json Service icons for pause/resume
homeassistant/components/casper_glow/translations/en.json Adds English translations file for the integration
tests/components/casper_glow/__init__.py Test helpers + BLE discovery fixtures and integration setup helper
tests/components/casper_glow/conftest.py Casper Glow test fixtures (config entry + integration setup)
tests/components/casper_glow/test_config_flow.py Config flow test coverage (bluetooth/user flows, errors, aborts)
tests/components/casper_glow/test_coordinator.py Coordinator polling + availability logging behavior tests
tests/components/casper_glow/test_init.py Setup/unload/remove-device tests + BLE callback forwarding tests
tests/components/casper_glow/test_light.py Light entity behavior tests (state updates, brightness mapping, services, logging)
tests/components/casper_glow/snapshots/test_light.ambr Snapshot for light entity registry/state
homeassistant/generated/bluetooth.py Registers Casper Glow BLE service UUID matcher (generated)
homeassistant/generated/config_flows.py Adds casper_glow to generated config flow list
homeassistant/generated/integrations.json Adds integration metadata (generated)
requirements_all.txt Adds pycasperglow==1.0.1 to runtime requirements
requirements_test_all.txt Adds pycasperglow==1.0.1 to test requirements
mypy.ini Enables strict mypy rules for homeassistant.components.casper_glow.*
.strict-typing Adds homeassistant.components.casper_glow.* to strict typing allowlist
CODEOWNERS Adds codeownership for Casper Glow integration and its tests
Signed-off-by: Mike O'Driscoll <mike@unusedbytes.ca>
@mikeodr mikeodr force-pushed the casper-glow-integration branch from 8a7bbc1 to 0987d01 Compare March 1, 2026 21:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment