macOS Sequoia causes QNetworkReply::UnknownNetworkError when using QNetworkAccessManager in local network
-
Hello,
macOS Sequoia introduced a new "Local Network" section under "Privacy & Security". If an executable is not listed in this section, the executable cannot access any other host on the local network.I have a Qt executable, that connects to a local backend server using the QNetworkAccessManager. The backend server is on another host in my local network.
After upgrading to the latest macOS Sequoia, when Qt Creator is used to launch the executable, the executable cannot connect to the backend server on the local network.
When I launch the Qt Creator built executable directly from within the terminal, everything works fine. Only when the executable is launched from within Qt Creator, the exact same executable has issues connecting.
Any tips on how to resolve this? I think this is going to become an issue for all Qt developers.
Thanks,
JG. -
Hello,
macOS Sequoia introduced a new "Local Network" section under "Privacy & Security". If an executable is not listed in this section, the executable cannot access any other host on the local network.I have a Qt executable, that connects to a local backend server using the QNetworkAccessManager. The backend server is on another host in my local network.
After upgrading to the latest macOS Sequoia, when Qt Creator is used to launch the executable, the executable cannot connect to the backend server on the local network.
When I launch the Qt Creator built executable directly from within the terminal, everything works fine. Only when the executable is launched from within Qt Creator, the exact same executable has issues connecting.
Any tips on how to resolve this? I think this is going to become an issue for all Qt developers.
Thanks,
JG.@JohnGa said in macOS Sequoia causes QNetworkReply::UnknownNetworkError when using QNetworkAccessManager in local network:
Any tips on how to resolve this? I think this is going to become an issue for all Qt developers.
I've heard people having general network issues after the upgrade to Sequoia... all kinds of network-based software fails or cannot connect to XYZ anymore... there will be probably a fix from Apple soon.
-
I contacted Apple. Turns out, Qt Creator needs to add itself to the privacy settings section. I do not know exactly how this can be done. Other IDE's like the ones from JetBrains show up in the Network privacy section.
-
@artwaw Yes. With all the other IDE's, like the JetBrains ones, when you start them for the first time on macOS Sequoia, they prompt for "permission to access devices on local network". Answering "Allow" to that prompt adds the IDE to the Settings -> Privacy & Security -> Local network section.
With Qt Creator this does not happen. I am still trying to figure out a way around this. At point, anyone that is trying to debug an executable that does network calls should be stuck COMPLETELY.
-
@artwaw Yes. With all the other IDE's, like the JetBrains ones, when you start them for the first time on macOS Sequoia, they prompt for "permission to access devices on local network". Answering "Allow" to that prompt adds the IDE to the Settings -> Privacy & Security -> Local network section.
With Qt Creator this does not happen. I am still trying to figure out a way around this. At point, anyone that is trying to debug an executable that does network calls should be stuck COMPLETELY.
-
Hi,
In any case, it's something worth a ticket on the bug tracking system.
Qt Creator should be updated to request that permission.
-
For those that are interested:
https://bugreports.qt.io/browse/QTCREATORBUG-31654There is a resolution in the form of running the executable with "Run in terminal" checked and in "Debug" mode. However, these are both productivity killers. Launching a "Debug" is slower. Launching/terminating is also slower. I SINCERELY HOPE Qt will find a solution to this problem.