Skip to content

Put integration files at the HACS zip root - #58

Merged
LordMike merged 1 commit into
mainfrom
fix/hacs-zip-root
Oct 25, 2026
Merged

LordMike merged 1 commit into
mainfrom
fix/hacs-zip-root

Conversation

@LordMike

Copy link
Copy Markdown
Owner

Problem

hacs.json sets zip_release: true, so HACS extracts wattplan.zip directly into custom_components/wattplan/. build_hacs_zip.py stored entries as custom_components/wattplan/..., so a HACS install ended up at custom_components/wattplan/custom_components/wattplan/ and Home Assistant reported Integration 'wattplan' not found. The packaging test asserted the same wrong layout, so CI passed.

Fix

  • Archive entries are now relative to the integration folder (manifest.json, __init__.py at the zip root).
  • tests/test_build_hacs_zip.py asserts the root layout and that nothing starts with custom_components/.

Full suite: 1725 passed (WSL).

🤖 Generated with Claude Code

https://claude.ai/code/session_015GrJia4xEvATC9xWykY7GZ

hacs.json sets zip_release, so HACS extracts wattplan.zip straight into
custom_components/wattplan. The archive stored every file under
custom_components/wattplan/, which nested the integration one level too
deep and left Home Assistant unable to find it. Store entries relative to
the integration folder, and make the test assert that layout.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015GrJia4xEvATC9xWykY7GZ
@LordMike
LordMike merged commit 6cedd3f into main Oct 25, 2026
7 checks passed
@LordMike
LordMike deleted the fix/hacs-zip-root branch October 25, 2026 14:06
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.

1 participant