Hi, are there differences in the way mDNS discovery works on the Android companion app vs the macOS companion app? I was working to configure avahi and realized my configuration works fine with the macOS companion app but it never worked so far with the Android companion app and I'm curious to understand why. I looked at network packets to figure out the proper avahi configuration.
#mDNS discovery of Home Assistant server with Android companion app not working but working on macOS
1 messages · Page 1 of 1 (latest)
To add to this, I can see the Home Assistant Android app searching for the Home Assistant server through mDNS and I can see it gets a response but it keeps searching anyways unlike the macOS companion app
well its porbably to be expected there will indeed be platform differences there
is the response we get valid or did the app get an error?
we have logging around wehn services are discovered and if there was any issue
I cannot know if the response that Home Assistant gets is valid because it doesn't respond and it does not provide an error either. I'll check the logs to see if Home Assistant reported something.
Also, I noticed the macOS Home Assistant companion app does not work and I see this in the logs: 2024-11-15 07:30:59.826 ERROR (MainThread) [frontend.js.modern.202410023] Uncaught error from WebKit 605.1.15 on Mac OS 10.15.7
Script error.
null
@:0:0
I see this too: 2024-11-15 08:01:40.413 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [139830813498176] Error handling message: Unauthorized (unauthorized) [REDACTED] from [REDACTED] (Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Home Assistant/2024.9.2 (io.robbie.HomeAssistant; build:2024.881; macOS 14.6.1) Mobile/HomeAssistant, like Safari)
But absolutely nothing about the Android Home Assistant companion app in the logs
I have info level enabled. I can enable debug level and see what I get.
It could just be device differences if the server is not being discovered. You can just enter the URL manually. The logs I am referring to are app logs but they won't be visible if you haven't logged in yet.
Where could I see the app logs?
So far, absolutely nothing in Home Assistant logs that would concern the Android Home Assistant companion app
Once your logged in go to settings > companion app > troubleshooting> show and share logs. The logs may not contain the error unless you reproduce the issue
I don't think there are any logs on the server side for app discovery
I would expect if there is any error it would appear below this line https://github.com/home-assistant/android/blob/master/app%2Fsrc%2Fmain%2Fjava%2Fio%2Fhomeassistant%2Fcompanion%2Fandroid%2Fonboarding%2Fdiscovery%2FHomeAssistantSearcher.kt#L81