Allow local brands assets in the brands validator#5128
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This pull request adds support for local brands assets in HACS integrations, allowing repositories to include their own icon.png file in a brands/ directory rather than requiring them to be added to the Home Assistant brands repository. The implementation includes a fallback mechanism that maintains backward compatibility with the existing remote brands repository check.
Changes:
- Added logic to check for local brands assets before falling back to remote brands repository
- Added ASSET_FILENAME constant for the icon.png file
- Added comprehensive test coverage for local brands functionality
- Updated error message to be more descriptive
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| custom_components/hacs/validate/brands.py | Implements local brands asset detection with fallback to remote brands repository, adds ASSET_FILENAME constant |
| tests/validate/test_brands_check.py | Adds three new test cases covering local brands with content_in_root, without content_in_root, and fallback scenarios; imports HacsManifest and ASSET_FILENAME |
| tests/snapshots/api-usage/tests/validate/test_brands_checktest-local-brands-asset-content-in-root.json | API usage snapshot for the content_in_root test case |
| tests/snapshots/api-usage/tests/validate/test_brands_checktest-local-brands-asset-not-in-root.json | API usage snapshot for the not-in-root test case |
| tests/snapshots/api-usage/tests/validate/test_brands_checktest-local-brands-asset-missing-falls-back-to-remote.json | API usage snapshot for the fallback test case |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
edenhaus
approved these changes
Feb 28, 2026
philrenda
added a commit
to philrenda/precipitation-radial-card
that referenced
this pull request
Feb 28, 2026
hacs/integration#5128 merged — the HACS validation action now accepts brand icons shipped inside custom_components/<domain>/brand/. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
SSIA
Closes #5123
Closes #5124