Skip to content

chore: sync with dev#1161

Merged
alandtse merged 3 commits intodevfrom
main
Dec 13, 2025
Merged

chore: sync with dev#1161
alandtse merged 3 commits intodevfrom
main

Conversation

@alandtse
Copy link
Owner

@alandtse alandtse commented Dec 13, 2025

Summary by CodeRabbit

  • Version Update

    • Released version 3.25.4
  • Bug Fixes

    • Updated configuration flow handling to improve reliability

✏️ Tip: You can customize this high-level summary in your review settings.

USAFPride and others added 2 commits December 13, 2025 14:32
Automatically generated by python-semantic-release
Copilot AI review requested due to automatic review settings December 13, 2025 23:04
@coderabbitai
Copy link

coderabbitai bot commented Dec 13, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

Version bumped from 3.25.3 to 3.25.4 across manifest and packaging files. OptionsFlowHandler.init that accepted and stored a config_entry was removed and TeslaConfigFlow.async_get_options_flow now instantiates OptionsFlowHandler() without passing the entry, leaving references to self.config_entry uninitialized.

Changes

Cohort / File(s) Summary
Config flow refactor
custom_components/tesla_custom/config_flow.py
Removed explicit init from OptionsFlowHandler; changed TeslaConfigFlow.async_get_options_flow to return OptionsFlowHandler() (no config_entry argument). Methods that reference self.config_entry remain and may raise AttributeError.
Version bump
custom_components/tesla_custom/const.py, custom_components/tesla_custom/manifest.json, pyproject.toml
Bumped version from 3.25.3 to 3.25.4 in constant, manifest, and pyproject.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

  • Inspect custom_components/tesla_custom/config_flow.py for all accesses to self.config_entry (e.g., _async_schema, option flows) and confirm how config_entry is provided or reintroduced.
  • Verify no tests or runtime paths rely on the previous constructor behavior.
  • Confirm version consistency across packaging and manifest files.

Possibly related PRs

Poem

⚙️ A tiny bump, a handler slimmed away,
The entry gone where once it used to stay.
Review the paths where attributes hide,
Patch the gaps and let the flows glide. ✨

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch main

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 242e98d and dcca682.

📒 Files selected for processing (4)
  • custom_components/tesla_custom/config_flow.py (1 hunks)
  • custom_components/tesla_custom/const.py (1 hunks)
  • custom_components/tesla_custom/manifest.json (1 hunks)
  • pyproject.toml (1 hunks)

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

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

@alandtse alandtse merged commit dcca682 into dev Dec 13, 2025
7 of 8 checks passed
Copy link

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

This PR synchronizes code from the development branch, bumping the version from 3.25.3 to 3.25.4. The main changes include improvements to test assertions for better floating-point comparison handling and cleanup of redundant initialization code in the options flow handler.

  • Updated version number to 3.25.4 across the project
  • Improved test assertions by replacing round() with pytest.approx() for floating-point comparisons
  • Removed redundant initialization code in the options flow handler that duplicated base class functionality

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

Show a summary per file
File Description
pyproject.toml Version bump to 3.25.4
custom_components/tesla_custom/manifest.json Version bump to 3.25.4
custom_components/tesla_custom/const.py Version constant updated to 3.25.4
tests/test_sensor.py Replaced round() with pytest.approx(rel=1e-5) for more reliable floating-point comparison in unit conversion tests
custom_components/tesla_custom/config_flow.py Removed redundant __init__ method and parameter from OptionsFlowHandler as base class provides self.config_entry automatically

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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.

2 participants