Improve GX device config flow - #483
Merged
Merged
Conversation
tomer-w
reviewed
Aug 13, 2026
tomer-w
reviewed
Aug 13, 2026
philipptrenz
marked this pull request as draft
August 13, 2026 13:30
philipptrenz
force-pushed
the
main
branch
2 times, most recently
from
August 13, 2026 16:05
331b6d4 to
1b211a0
Compare
philipptrenz
marked this pull request as ready for review
August 13, 2026 16:06
tomer-w
reviewed
Aug 13, 2026
- Add SSDP detection of X_MqttTokenPairing from GX device discovery - Add automatic token pairing flow: when a GX device advertises token pairing support, retrieve MQTT credentials via HTTPS POST to /auth/generate-token/ instead of prompting for manual password entry - Show pairing instructions in the UI, prompting the user to enable pairing mode on the GX device before submitting - Try SSL (port 8883) first during SSDP discovery, fall back to plain MQTT (port 1883) if unavailable - Simplify SSDP auth form: hardcode username to remoteconsole, rename password field to "GX Password", default SSL to on - Add second SSDP matcher for X_MqttTokenPairing=1 so discovery triggers even when X_MqttOnLan is disabled; issuing a token automatically enables "Paired devices only" access on the GX - Add PairingError exception and pairing_failed error string - Add CONF_MQTT_TOKEN_PAIRING constant, stored in config entry data when token pairing is used - Add translations for all new UI elements in en, de, fr, ca, sk - Add tests for token pairing success, HTTP error, connection error, MQTT validation failure, and fallback to manual auth
tomer-w
reviewed
Aug 14, 2026
Owner
|
If you want to allow better granularity of the error handling, it should be vmby defining different exceptions in the library or by better text for the current exceptions. It should "leak" the http exceptions outside if the library call. Also, you should probably improve the README.md here as well. I'm approving this PR but feel free to continue improving this. |
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.
X_MqttTokenPairingfrom GX device discovery/auth/generate-token/instead of prompting for manual password entryremoteconsole, rename password field to "GX Password", default SSL to onX_MqttTokenPairing=1so discovery triggers even whenX_MqttOnLanis disabled; issuing a token automatically enables "Paired devices only" access on the GXCONF_MQTT_TOKEN_PAIRINGconstant, stored in config entry data when token pairing is useden,de,fr,ca,skNote: The translations for
fr,ca, andskwere generated automatically and should be reviewed.