jabesq-org / pyatmo

Simple API to access Netatmo weather station data from any python script (for Netatmo information, see www.netatmo.com)
MIT License
26 stars 28 forks source link

Small update to home load handling #512

Closed tmenguy closed 6 days ago

tmenguy commented 6 days ago

Installed pre-commit too

Summary by Sourcery

Enhance the home update logic by adding a flag to detect updates when person data changes, and install pre-commit to improve code quality checks.

Enhancements:

Chores:

sourcery-ai[bot] commented 6 days ago

Reviewer's Guide by Sourcery

This pull request makes a small update to the home load handling in the src/pyatmo/home.py file. The change adds a flag to indicate that the house has been updated when there's a person update.

Sequence Diagram

No sequence diagram generated.

File-Level Changes

Change Details Files
Added a flag to indicate house update on person status change
  • Introduced a new variable 'has_an_update' and set it to True when processing person status updates
  • This change implies that any person status update is considered a house update
src/pyatmo/home.py

Tips and commands #### Interacting with Sourcery - **Trigger a new review:** Comment `@sourcery-ai review` on the pull request. - **Continue discussions:** Reply directly to Sourcery's review comments. - **Generate a GitHub issue from a review comment:** Ask Sourcery to create an issue from a review comment by replying to it. #### Customizing Your Experience Access your [dashboard](https://app.sourcery.ai) to: - Enable or disable review features such as the Sourcery-generated pull request summary, the reviewer's guide, and others. - Change the review language. - Add, remove or edit custom review instructions. - Adjust other review settings. #### Getting Help - [Contact our support team](mailto:support@sourcery.ai) for questions or feedback. - Visit our [documentation](https://docs.sourcery.ai) for detailed guides and information. - Keep in touch with the Sourcery team by following us on [X/Twitter](https://x.com/SourceryAI), [LinkedIn](https://www.linkedin.com/company/sourceryai/) or [GitHub](https://github.com/sourcery-ai).