Skip to content

Validate integration connectivity in the action - #5706

Open
ludeeus wants to merge 1 commit into
mainfrom
claude/trusting-shannon-owxfcd
Open

ludeeus wants to merge 1 commit into
mainfrom
claude/trusting-shannon-owxfcd

Conversation

@ludeeus

@ludeeus ludeeus commented Nov 30, 2026 •

Copy link
Copy Markdown
Member

#5705 added connectivity from integration manifests to the generated data. The action did not check it, so authors got no feedback when the data generator dropped unknown values.

This adds an integration_connectivity action check, like integration_categories. It fails on unknown, duplicate or empty connectivity values. A missing connectivity key logs a warning and doesn't fail the check, because the key is optional.

Docs: home-assistant/contributors.home-assistant.io#270


Generated by Claude Code

Adds an integration_connectivity action check that fails on unknown,
duplicate, or empty connectivity values in the integration manifest, and
logs a warning when the key is missing, the same way as categories.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HrvhMK1JAvDcTBp9N94Yi9
Copilot AI adaptive review requested due to automatic review settings November 30, 2026 18:52
@ludeeus ludeeus added the pr: action Changes to actions label Nov 30, 2026

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.

🟢 Approval recommended

The connectivity-validation change has no active review issues.

No open issues 🎉

What changed in this PR

Adds connectivity validation to the HACS action, complementing the generated-data support from #5705 so authors receive feedback before invalid values are dropped.

Changes:

  • Adds an integration_connectivity check that rejects unknown, duplicate, empty, or incorrectly typed values while warning when the optional key is absent.
  • Reuses the existing connectivity validator through a dedicated manifest schema.
  • Adds validator and action tests, with updated log and API-usage snapshots.
File Description
tests/​validate/​test_integration_connectivity_check.py Tests validation, optional-key warnings, and manifest loading.
tests/​snapshots/​api-usage/​tests/​validate/​test_integration_connectivity_checktest-integration-connectivity-no-manifest.json Records API usage for a missing manifest.
tests/​snapshots/​api-usage/​tests/​validate/​test_integration_connectivity_checktest-integration-connectivity-missing-is-a-warning.json Records API usage for the optional-key warning.
tests/​snapshots/​api-usage/​tests/​validate/​test_integration_connectivity_checktest-integration-connectivity-manifest5-true.json Records API usage for an invalid value type.
tests/​snapshots/​api-usage/​tests/​validate/​test_integration_connectivity_checktest-integration-connectivity-manifest4-true.json Records API usage for empty connectivity.
tests/​snapshots/​api-usage/​tests/​validate/​test_integration_connectivity_checktest-integration-connectivity-manifest3-true.json Records API usage for duplicate values.
tests/​snapshots/​api-usage/​tests/​validate/​test_integration_connectivity_checktest-integration-connectivity-manifest2-true.json Records API usage for an unknown value.
tests/​snapshots/​api-usage/​tests/​validate/​test_integration_connectivity_checktest-integration-connectivity-manifest1-false.json Records API usage for valid connectivity.
tests/​snapshots/​api-usage/​tests/​validate/​test_integration_connectivity_checktest-integration-connectivity-manifest0-false.json Records API usage when connectivity is omitted.
tests/​snapshots/​api-usage/​tests/​validate/​test_integration_connectivity_checktest-integration-connectivity-fetches-manifest-when-not-loaded.json Records API usage for manifest loading.
tests/​snapshots/​api-usage/​tests/​action/​test_hacs_action_integrationtest-hacs-action-integration-bad-connectivity.json Records API usage for the action failure case.
tests/​snapshots/​action/​test_hacs_action_integration/​valid_manifest.log Adds the warning and eleventh check to successful output.
tests/​snapshots/​action/​test_hacs_action_integration/​releases_without_assets.log Updates output for releases without assets.
tests/​snapshots/​action/​test_hacs_action_integration/​no_releases.log Updates output for repositories without releases.
tests/​snapshots/​action/​test_hacs_action_integration/​bad_issue_tracker.log Updates output while preserving the issue-tracker failure.
tests/​snapshots/​action/​test_hacs_action_integration/​bad_documentation.log Updates output while preserving the documentation failure.
tests/​snapshots/​action/​test_hacs_action_integration/​bad_connectivity.log Captures the connectivity validation failure.
tests/​snapshots/​action/​test_hacs_action_integration/​bad_categories.log Updates output while preserving the categories failure.
tests/​action/​test_hacs_action_integration.py Adds invalid-connectivity coverage and updates check counts.
custom_components/​hacs/​validate/​integration_connectivity.py Implements the action check and optional-key warning.
custom_components/​hacs/​utils/​validate.py Exposes a dedicated connectivity manifest schema.

Review effort: Balanced (adaptive)

@ludeeus
ludeeus marked this pull request as ready for review December 3, 2026 21:30

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr: action Changes to actions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants