I've also hit this bug, here's a couple of observations:
(1) Looks like the version of gnutls affects the behavior of url-retrieve-synchronously.
My conclusion is that the bug manifests with gnutls >= 3.6. I confirmed this on Arch with
emacs 26.1 and on Ubuntu bionic/cosmic with emacs 25.2
(2) Weird workaround, which works for me: add (setq gnutls-log-level 1) to the end of init.el