Safari ajax request Failed to load resource: The network connection was lost
One of the reasons why it might happen is the way Safari handles some SSL certificates (mainly, LetsEncrypt). The solution is to put the line:
ssl_session_cache shared:SSL:10m;
to your nginx config.
Source: https://community.letsencrypt.org/t/apple-safari-browsers-fail-to-connect/3731/3
Had this trouble too with a form that ajax-posted and when that completed did a window.location.reload(true). Safari 13.0.3 would work the first time after a manual page refresh (seemed consistent) then would get "Failed to load resource: The network connection was lost." roughly 2 out of 3 clicks.
Changed the client to:
use ajax-get instead of post (with a unique query param value each time)
on completion set a timer so that window.location.reload(true) was not done inside the ajax completion handler
User reports that worked, not sure which one of those changes or both.
Hope this helps someone...