Multihub needs practical testing (but works in theory)
.. most likely it doesn't work. The library makes every attempt to be usable with multiple hubs on the same account simultaneously. However since I only have one hub most of this is untested and there's at least one known point where it won't work:
- When using a hub locally we don't yet have any sane way to map hub id to hub ip on authentication. It's just a matter of hammering it down but it's tedious without being able to test.
Much of the initial multihub issues are gone already earlier with the change to storing hubs per id instead of name. This solved the chicken-egg issues initially mentioned.
v0.2.12 now brings cloud remote operations into multihub compatibility, at least in theory. Since I only have one real hub testing has been theoretical. Now hubs can exist in a mixed state of remoteness though so it's much more practical to have multiple hubs.
Current code saved hub information little bit wrong way. There was sections for each hub but both contained name and ip of local hub which was little bit confusing and default one was always wrong one for me. I tried to improve little bit how authentication works with multiple hubs.
https://github.com/jinnatar/python-cozify/pull/25
Needs still some clean up and need to change code little bit in case there is only one hub which is not local, then it is stored as default one. Any comments?