If you're using an application from Google or Microsoft or any big tech company for that matter: yes.
> And anyway, why would a compiler need internet access ?
The go build tool will fetch dependencies for you. If you don't use dependencies or use a local network proxy instead of the Google one you can safely disable WAN access, but otherwise you'll end up with a broken tool.