Skip to content

Remove deprecated via_device constant as suggested by Dosu - #330

Open
tobias-93 wants to merge 1 commit into
CoMPaTech:mainfrom
tobias-93:fix-deprecation-via-device
Open

tobias-93 wants to merge 1 commit into
CoMPaTech:mainfrom
tobias-93:fix-deprecation-via-device

Conversation

@tobias-93

@tobias-93 tobias-93 commented Sep 8, 2026

Copy link
Copy Markdown

Closes #329

Summary by CodeRabbit

  • Bug Fixes
    • Updated Stromer device information handling to improve compatibility with current Home Assistant behavior.

@coderabbitai

coderabbitai Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: cfe0ca9c-d892-4b5c-88c0-dd7390678949

📥 Commits

Reviewing files that changed from the base of the PR and between d656e80 and 3ebaf4d.

📒 Files selected for processing (1)
  • custom_components/stromer/entity.py

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.


Walkthrough

The Stromer integration removes its use of the deprecated ATTR_VIA_DEVICE constant and stops setting the corresponding device information attribute.

Changes

Stromer device information

Layer / File(s) Summary
Remove deprecated device attribute
custom_components/stromer/entity.py
The entity removes the ATTR_VIA_DEVICE import and no longer adds ATTR_VIA_DEVICE: None to device information.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~5 minutes

Severity of issue fixed: Low

Merge Risk: ⚪ Minimal · up to 3ebaf

The integration removes a deprecated unused device-info attribute without changing device behavior. No current merge-blocking risk remains.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The pull request removes ATTR_VIA_DEVICE, but it does not update the deprecated via_device parameter to via_device_id in binary_sensor.py, button.py, sensor.py, and switch.py as required by issue #329 Update all device registry calls that use via_device to use via_device_id, then verify that the deprecation warnings are resolved in all affected entities.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the removal of the deprecated via_device constant and matches the change in the pull request.
Out of Scope Changes check ✅ Passed The change is limited to removing the deprecated ATTR_VIA_DEVICE usage in the Stromer entity implementation. No unrelated changes are present.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 1 files.
Full details: Linked Issues check

Explanation

The pull request removes ATTR_VIA_DEVICE, but it does not update the deprecated via_device parameter to via_device_id in binary_sensor.py, button.py, sensor.py, and switch.py as required by issue #329.

  • Fix all pre-merge checks with AI

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

A rabbit hops through logs so clear
No deprecated fields remain here
The Stromer devices stand bright
With cleaner records day and night
Ears up, the update is right

Comment @coderabbitai help to get the list of available commands.

@sonarqubecloud

sonarqubecloud Bot commented Sep 8, 2026

Copy link
Copy Markdown

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.

[BUG]: Deprecation notices related to via_device

1 participant