-
Notifications
You must be signed in to change notification settings - Fork 51
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
Stopped working for ios 17 #64
Comments
I connected to the onError signal and it gives me -3
|
Do you have NSLocalNetworkUsageDescription NSBonjourServices set in your info.plist? |
error -3 is browser failed (from qzeroconf.h) |
Is service publishing and browsing broken or only browsing? If your app does not have service publishing, please run the example on your iOS17 device as well as a computer. They should see each other. |
Hi, I just wanted to make sure you got my message...
|
Hello thanks for replying :) Yes I have included this in my info.plist
Last year (2023) The app was working perfectly fine on android and ios 16. This year (2024) phones were updated to ios17 and latest android and now zeroconf stopped working. It was successfully working on QT 6.4 & 6.5. I have updated to 6.6 but no help. I have tried with several We are publishing a zerconf service using python which is working. I think the browserFailed (-3) error confirms something is wrong with my ios/android project. I have been trying to troubleshoot this for a while. Its not possible the SDK or QT has changed something. A lot of app developers reported zeroconf problems after ios 17 |
I ran the example and it works fine on ios17 with Qt 6.6.2 I am using QML I might try going back to c++ |
Please apply this patch and run your qml app. There are 4 places that can generate browserFailed. |
i ran the patch and i think browser is running ok now. Not getting any browser errors. But im not getting the onServiceAdded / onServiceRemoved signals either |
You should have a new debug message "browser failed .....xyz". Does c++ qDebug() output make it out in a python app? |
startBrowser is working. The -3 error was because I was calling it when it was already active. This turns out to be a red herring. I have confirmed that bonjour.cpp does find my zeroconf service. I added more qDebug(): Service found: test-service Type: _test._tcp. Domain: local.
The problem now is that I am not getting any signals back in QML except for onError
Doesn't matter if i try with QML type connections. Im not getting any of these signals
QML is just not receiving these signals.... |
I found the problem: resolverCallback never gets called. In bonjour.cpp line 88 is responsible for calling it: err = DNSServiceResolve(&resolver->DNSresolverRef, kDNSServiceFlagsTimeout, zcs->interfaceIndex(), zcs->name().toUtf8(), zcs->type().toUtf8(), zcs->domain().toUtf8(), static_cast(resolverCallback), resolver); This gets called but function resolverCallback never gets called from the SDK. Which means we never get as far as addressReply and the signal never gets emitted. My zeroConf service is published via python so i will modify the example code and see if it can connect to python instead of itself. |
After DNSServiceResolve() is called, a QSocketNotifier is used to "wakeup" an run the resolverCallback. Maybe the QSocketNotifier is not working with python? Please try this patch. It forces the resolverCallback to run after 1.5 seconds. |
I FOUND THE SOLUTION!!! Well these guys found the solution: esp8266/Arduino#9046 (comment) I did the same thing with my python-zeroconf code by simply adding a TXT record to the published service and now the ios callback is working again. I am using python-zeroconf to publish my service so I just had to assign a record to the properties parameter: https://python-zeroconf.readthedocs.io/en/latest/api.html |
I have had this working fine until ios 17 update. I can't get it to find any mdns services from different iphones all running ios 17. Anyone have this working on ios17?
The text was updated successfully, but these errors were encountered: