-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[tado] Support multiple homes & accounts, and bug fixes #18481
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
…ddons into tado-post-fix
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
Ping @OlduwanSteve just for info: I have tested this myself on my own system insofar as is possible without having two accounts. At least I can confirm that a) it does not break anything for users with one account, and b) it can authenticate a (single) account regardless of whether a user name is specified. I suggest you look at the new docs -- note that you need to check the Advanced box to see the new configuration parameters for this feature. |
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
This pull request has been mentioned on openHAB Community. There might be relevant details there: https://community.openhab.org/t/tado-authentication/163276/54 |
@OlduwanSteve there is also a build for OH v4.3.4 above |
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
This pull request has been mentioned on openHAB Community. There might be relevant details there: |
This pull request has been mentioned on openHAB Community. There might be relevant details there: https://community.openhab.org/t/tado-authentication/163276/56 |
Hello, I also support this pull request and though of starting programming it. I have 3 tado devices distributed of VPN to be handled by one OpenHAB instance. I have also this error, when I click on authenticate. I have update several times and currently from 4.3.3 to 4.3.4. If I install a new instance, I have no problem. Regards Andreas
|
Please provide logs as follows:
|
Sorry to ask this question, but where do I do this? In the GUI? |
In the console. |
This pull request has been mentioned on openHAB Community. There might be relevant details there: https://community.openhab.org/t/tado-authentication/163276/58 |
@andrewfg Great stuff, it works like a charm! I dropped the 4.3.4 snapshot jar in my addons folder, stopped the openhab service, cleared the cache, started the service again. My two bridges showed as pending config and each correctly prompted me with the user parameter pre-filled in the url. One nice thing to note is that the tado OAuth confirmation for the second bridge recognised I was already logged in with one account, and gave me the option to logout before proceeding. I'm very grateful for you jumping on this. |
Indeed. And I suspect that if you had not logged out of account A and logged in to account B, then it would have invalidated the prior token for account A. |
This comment was marked as outdated.
This comment was marked as outdated.
Maybe it was the cache not emtpied ... |
@andypmuc you are saying confusing things. On one hand you say it works, but on the other hand you say it reports an error. Which is it? In any case, the exception that you see ( As a result of your log, I see that I do need to make the OH Core error logging more gentle. (Which I will do). However the underlying issue seems to be coming from the Tado server. So can you please turn on EDIT see openhab/openhab-core#4703 |
What I said, was the truth, tested it several times. Now I have the problem, that the scanning of devices of the remote VPN Tado system is not working. Is there another way, to find out the ID? |
Sorry but I don't understand. Can you please explain further?
So if the log that you provided above applies identically to the case when it succeeded and also to the case when it failed, then obviously that log provides us with no information to help discern what failed. Or?? Probably if you could provide the log you would see a message “The authorization request is still pending” this means that you did not complete the login process on the Tado website. Perhaps because you used the wrong login credentials, or perhaps because you did not press the submit button. EDIT: see this https://community.openhab.org/t/tado-authentication/163276/65 |
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
This comment was marked as resolved.
This comment was marked as resolved.
Your refresh token is trashed. So you will need to manually erase it. There is a file |
This pull request has been mentioned on openHAB Community. There might be relevant details there: |
@andypmuc please see this post https://community.openhab.org/t/tado-authentication/163276/71 |
Now it works. I have the two bridges in, because I have them from my old configuration, but I lost two zones and there is no way to get their ID or scan for them (I deleted them because of com problems). When I set up a new Openhab, I do not have the possibility to add anything from the other network, does this request solve this? |
Well, that is more or less generic networking. openHAB can add any devices as long as it is able to connect to it. |
If both Tado hubs present themselves on your network then the OH discovery will find them and put them in the inbox. (If not then you have a LAN routing issue that is unrelated to this thread). Normally when you only have one Tado hub it is only necessary to set the |
I think I wait for the rfcWithUser feature, this will solve it easily. |
This pull request has been mentioned on openHAB Community. There might be relevant details there: |
@lolodomo I think this one is ready to merge. (It has been verified by @OlduwanSteve and @andypmuc) |
This pull request has been mentioned on openHAB Community. There might be relevant details there: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thansk @andrewfg i have some questions that might improve the user experience (or not) :-)
...ab.binding.tado/src/main/java/org/openhab/binding/tado/internal/handler/TadoHomeHandler.java
Show resolved
Hide resolved
...ab.binding.tado/src/main/java/org/openhab/binding/tado/internal/handler/TadoHomeHandler.java
Show resolved
Hide resolved
bundles/org.openhab.binding.tado/src/main/resources/OH-INF/i18n/tado.properties
Show resolved
Hide resolved
Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, LGTM
* [tado] add support for multiple accounts / homes Signed-off-by: Andrew Fiddian-Green <software@whitebear.ch>
This PR does the following:
Signed-off-by: Andrew Fiddian-Green software@whitebear.ch
The Jar files for testing are here: