Skip to content

0.8.0 — Platinum quality scale + boschshcpy 0.4.0

Choose a tag to compare

@github-actions github-actions released this 29 Jun 07:16

Platinum quality scale + full type annotations

This release delivers the Platinum quality scale milestone and significantly improves code robustness across the integration.


boschshcpy 0.4.0

  • py.typed marker — full PEP 561 type annotations; mypy can now type-check against the library
  • SHCSessionAsync — async-first session class (foundation for future async migration)
  • All service + model classes exported from top-level __init__
  • certificate.py: not_valid_after_utc (replaces deprecated not_valid_after)
  • ruff + mypy CI gate in the library
  • GitHub Release auto-creation after PyPI publish

Platinum quality scale

All cumulative quality scale rules (Bronze → Silver → Gold → Platinum) are done or exempt.

  • Full mypy strict typing across the integration
  • mypy gate now enforced in CI (was informational)
  • 2915 tests passing, ≥95 % coverage gate

Bug fixes (since 0.7.25)

Stability / crash fixes

  • UserDefinedState crash on deleted states (#351) — Bosch API omits 'deleted'/'state' keys when False; .get() fallback prevents KeyError
  • SwitchDeviceEventListener duplicate homeassistant_stop listener — caused "Unable to remove unknown job listener" ValueError on every HA restart (4× per boot); removed since async_unload_entry already calls shutdown()
  • SmokeDetectorSensor.is_on: try/except (KeyError, ValueError) guard on alarmstate
  • ClimateDevice setup: KeyError guard on session.room(room_id)
  • config_flow: None guard in async_step_reconfigure / async_step_credentials (prevented AttributeError on pairing failure)
  • rawscan service: return None → raise ServiceValidationError (required for SupportsResponse.ONLY)
  • 20 services_impl defensive guards for partial long-poll updates (KeyError/ValueError)

Sensor correctness

  • Battery sensors: no longer show unknown / low erroneously — BatteryLevelService.warningLevel safe fallback → NOT_AVAILABLE
  • BatterySensor: self.nameself._device.name in logger calls (was None during polling callbacks)
  • entity_id deprecation fix (#296) — trigger_id now uses stable unique_id
  • Climate AUTO mode guard — prevents jumping back to auto on set_temperature
  • Number entity None guard
  • Binary sensor unsubscribe + ValueError guard
  • Event dedup + ValueError guard
  • Switch available property fix

Device compatibility

  • README: SHC I, SHC II, and SHC Classic all ✅ supported (corrected wrong claim)

CI hardening

  • quality.yml: pip install retry-with-backoff (self-heals when a just-released lib pin hasn't reached the CDN edge)
  • scripts/local-ci.sh — mirrors Quality + Tests workflows locally for pre-push checks

Full Changelog: v0.7.25...v0.8.0