requirements-dev.txt intentionally leaves homeassistant/cryptography unpinned (always test against latest), so ty's view of their stubs can drift between runs. SensorEntity._attr_state_class now requires SensorStateClass rather than a bare str (same fix already applied to _attr_device_class); NameAttribute.value is generic over str | bytes, so narrow it before handing it to re.search.