Skip to content

Add option to enable offline mode to lamarzocco#159094

Merged
joostlek merged 7 commits into
home-assistant:devfrom
zweckj:lamarzocco/option-offline-mode
Dec 15, 2025
Merged

Add option to enable offline mode to lamarzocco#159094
joostlek merged 7 commits into
home-assistant:devfrom
zweckj:lamarzocco/option-offline-mode

Conversation

@zweckj
Copy link
Copy Markdown
Member

@zweckj zweckj commented Dec 15, 2025

Breaking change

Proposed change

This change allows users which do not want to use the cloud to manually enter into the offline mode.

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New integration (thank you!)
  • New feature (which adds functionality to an existing integration)
  • Deprecation (breaking change to happen in the future)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Additional information

Checklist

  • I understand the code I am submitting and can explain how it works.
  • The code change is tested and works locally.
  • Local tests pass. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist
  • I have followed the perfect PR recommendations
  • The code has been formatted using Ruff (ruff format homeassistant tests)
  • Tests have been added to verify that the new code works.
  • Any generated code has been carefully reviewed for correctness and compliance with project standards.

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • The manifest file has all fields filled out correctly.
    Updated and included derived files by running: python3 -m script.hassfest.
  • New or updated dependencies have been added to requirements_all.txt.
    Updated by running python3 -m script.gen_requirements_all.
  • For the updated dependencies - a link to the changelog, or at minimum a diff between library versions is added to the PR description.

To help with the load of incoming pull requests:

Copy link
Copy Markdown
Contributor

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 adds an offline mode option to the La Marzocco integration, allowing users to operate their coffee machines without cloud connectivity by relying solely on Bluetooth communication. This feature is useful for users who prefer local-only control or have connectivity concerns.

Key changes:

  • Added CONF_OFFLINE_MODE configuration option with validation requiring Bluetooth to be enabled
  • Modified coordinators to skip cloud-based updates when offline mode is active
  • Refactored setup logic to conditionally skip cloud API calls in offline mode

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
homeassistant/components/lamarzocco/const.py Added CONF_OFFLINE_MODE constant definition
homeassistant/components/lamarzocco/config_flow.py Added offline mode option to options flow with validation that Bluetooth must be enabled
homeassistant/components/lamarzocco/coordinator.py Modified base coordinator to disable update intervals for cloud coordinators when offline mode is active, added _ignore_offline_mode flag for Bluetooth coordinator
homeassistant/components/lamarzocco/__init__.py Refactored setup to skip cloud API calls when offline mode is enabled, added validation that Bluetooth is available in offline mode
homeassistant/components/lamarzocco/strings.json Added user-facing strings for offline mode option and error messages
tests/components/lamarzocco/test_config_flow.py Added tests for offline mode validation in options flow
tests/components/lamarzocco/test_bluetooth.py Added tests for offline mode setup scenarios with and without Bluetooth device

Comment thread homeassistant/components/lamarzocco/strings.json
Comment thread tests/components/lamarzocco/test_config_flow.py Outdated
Comment thread tests/components/lamarzocco/test_bluetooth.py Outdated
zweckj and others added 3 commits December 15, 2025 12:40
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@joostlek joostlek merged commit a3f3586 into home-assistant:dev Dec 15, 2025
36 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators Dec 16, 2025
@zweckj zweckj deleted the lamarzocco/option-offline-mode branch February 17, 2026 07:32
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants