I've seen it almost exclusively at eBay, and when I do, simply hitting command-R to reload has invariably worked on the first try. (I'm running Safari Version 12.1.2 (14607.3.9).)
I have occasionally encountered the same error message in Safari 13.1 and as you said a refresh clears it immediately. Several years ago (OS X 10.3 or 10.4?) there was a Safari problem due to timing out too fast thus creating errors. That was long since fixed but I have to wonder if this is not a version of the old problem, but reported differently due to literally years of changes to Safari's internals and error handling.
(
NOTE: I very occasionally get a similar message as a result of a URL being blocked by my router's security features, but IIRC those are specifically identified as being blocked by the router.)