Appengine go cant' using http.Get?

I writing appengine go can’t using http.Get, but I success http.Get by go. In appengine go get body from a url?
response, err := http.Get(url)
if err != nil {
log.Infof(c, “error url”)
} else {
defer response.Body.Close()
contents, err := ioutil.ReadAll(response.Body)
if err != nil {
log.Infof(c, "Error read body ")
//fmt.Println(err)
}
}

I’m not really sure what you are asking? If you are having trouble maybe try examining the error returned.

or maybe a repro case. i’ve used this quite a bit and it looks ok to me…but really could be anything

oh, and btw, this is a forum for an online service to play the game ‘go’, not a forum about
the programming language ‘go’

2 Likes