Repository navigation
fix (1.0.x backport): parse single-quoted SSO config values on the Hive login page - #170
Merged
Merged
Conversation
Since 2026-10-20 https://sso.hivehome.com/ emits its bootstrap config as window.HiveSSOPoolId = 'eu-west-1_...' (single quotes, spaces around =) instead of window.HiveSSOPoolId="...". The string-replace JSON builder in getLoginInfo() only works with the old format, so it raises JSONDecodeError, returns None, and HiveAuthAsync.async_init crashes with AttributeError on self.data.get. Home Assistant (pinned to 1.0.9) then fails to set up the Hive integration after every restart (home-assistant/core#187516). Parse the window.* assignments with a regex that accepts either quote character. Backport of the dev-branch fix for a 1.0.10 patch release. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Contributor
Author
|
Note on the six pending checks: they are defined only in the dev-branch workflows (tests.yml, guard-master.yml), so they will never report on a PR into master, and source-branch-is-dev would fail a fork branch by design. All 15 lint/build checks pass. This backport is here in case you want a 1.0.10 hotfix from master, since Home Assistant pins pyhive-integration==1.0.9 and is currently broken (home-assistant/core#187516). If you would rather release from dev only, feel free to close this and keep #169. |
This was referenced Oct 20, 2026
KJonline
approved these changes
Oct 20, 2026
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Backport of the
devPR for a 1.0.10 patch release. Home Assistant pinspyhive-integration==1.0.9(from this branch), so every HA install that restarts is currently losing Hive: home-assistant/core#187516.Problem
Since 20 October 2026, https://sso.hivehome.com/ emits its bootstrap config as
window.HiveSSOPoolId = 'eu-west-1_…'(single quotes, spaces around=). The string-replace JSON builder ingetLoginInfo()only works with the oldwindow.X="…",format, so it raisesJSONDecodeError("Expecting value: line 1 column 20"), returnsNone, andHiveAuthAsync.async_initcrashes withAttributeError.Fix
Replace the string munging with a regex over the
window.<key> = <value>assignments that accepts either quote character. Verified against the live page:masterhas no unit tests for this path; the tests are in thedevPR.🤖 Generated with Claude Code