Skip to content

Hawk Camera Support#1272

Open
austinc3030 wants to merge 7 commits into
fronzbot:devfrom
dynacylabs:feature/hawk-camera-support
Open

Hawk Camera Support#1272
austinc3030 wants to merge 7 commits into
fronzbot:devfrom
dynacylabs:feature/hawk-camera-support

Conversation

@austinc3030

Copy link
Copy Markdown
Contributor

Description:

Adds support for the Blink Arc camera (hawk product type). Includes homescreen discovery, a BlinkHawk sync module class, and a BlinkCameraHawk camera class with hawk-specific API endpoints. Also fixes a bug in setup_owls() and setup_lotus() where network_id was being used as the camera ID instead of the actual camera ID.

Checklist:

  • Local tests with tox run successfully PR cannot be meged unless tests pass
  • Changes tested locally to ensure platform still works as intended
  • Tests added to verify new code works

- Add BlinkCameraHawk class with arm, record, snap_picture, get_liveview
- Add BlinkHawk sync-less module (mirrors BlinkOwl/BlinkLotus pattern)
- Add setup_hawks() to Blink for homescreen discovery
- Integrate hawk cameras into setup_camera_list()
- Extend request_get_config and request_update_config for hawk/sedona types
- Fix setup_owls() and setup_lotus() to use actual camera IDs instead of network_id
- Add tests
Copilot AI review requested due to automatic review settings July 20, 2026 17:16

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds first-class support for the Blink Arc (hawk) camera type by extending discovery, sync-module handling, camera modeling, and config endpoints, while also correcting camera ID selection for existing sync-less devices.

Changes:

  • Introduces BlinkHawk (sync-less module) and BlinkCameraHawk with hawk-specific endpoints (arm/config/clip/thumbnail/liveview).
  • Extends discovery and camera-list building to include hawks, and updates sync-module camera instantiation to recognize the new type.
  • Fixes setup_owls() / setup_lotus() to use the actual camera id (not network_id) and updates/adds tests accordingly.

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tests/test_sync_module.py Updates homescreen fixtures to include hawks for unique-info lookups.
tests/test_sync_functions.py Adds hawk coverage to mixed-camera sync tests and verifies BlinkCameraHawk instantiation.
tests/test_hawk_as_sync.py Adds a dedicated test ensuring a hawk can behave as a sync-less module and creates a BlinkCameraHawk.
tests/test_blinkpy.py Adjusts expected camera IDs after fixing owl/lotus camera ID selection.
tests/test_api.py Adds tests for request_get_config / request_update_config with product_type="hawk".
blinkpy/sync_module.py Adds hawk type mapping, hawk camera type selection, and introduces BlinkHawk.
blinkpy/camera.py Adds BlinkCameraHawk implementing hawk-specific API endpoints.
blinkpy/blinkpy.py Adds setup_hawks() and integrates hawks into setup_camera_list(), and fixes owl/lotus camera IDs.
blinkpy/api.py Adds hawk URL handling to config get/update APIs and updates docstrings.
Comments suppressed due to low confidence (1)

blinkpy/sync_module.py:229

  • get_unique_info() aborts the whole search on the first missing homescreen key (KeyError). After adding the new hawks type key, homescreen payloads that omit hawks can cause lookups for other device types (e.g., doorbells) to incorrectly return None unless callers/tests inject "hawks": [].
                self.cameras[name] = camera_type(self)
                self._names_table[to_alphanumeric(name)] = name
                await self.cameras[name].update(
                    camera_info, force_cache=True, force=True
                )

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

Comment thread blinkpy/sync_module.py
Comment on lines +213 to +217
# Get camera info first to check product_type
camera_info = await self.get_camera_info(
camera_config["id"], unique_info=unique_info
)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed in commit 0a063cbupdate_cameras() now uses a local resolved_camera_type per iteration instead of mutating the camera_type parameter, preventing class leakage between loop iterations.

@fronzbot

Copy link
Copy Markdown
Owner

Just going to respond here- thanks for the PRs. There's a decent amount of time I need to spend reviewing them and I'm not sure when I'll be able to get around to it. So I'm going to skip these for the next minor release of blinkpy and will target these for a major release post-review. If more than a week or two passes without me reviewing anything, just ping me. I get busy and forget things easily

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.

3 participants