I am using the revel framework with the go language. Recently, when I run the following code:
import (
...
"net/url"
...
)
revel.INFO.Println(url.QueryEscape("http://hello.com"))
I get
INFO 2014/07/09 14:58:34 user.go:39: http%A(MISSING)%F(MISSING)%F(MISSING)hello.com
When I expect to get something more like
INFO 2014/07/09 14:58:34 user.go:39: http%3A%2F%2Fhello.com
Why has %3A
been replaced by %A(MISSING)
in the output and how can I fix it?
The only go code where I see something that might produce the string "(MISSING)' is in the fmt
package, but from looking at the net/url
source code package, I don't see how that could be happening. Am I perhaps somehow accessing an old (and broken?) version of the go libraries? Is something else possibly wrong with my setup?
Related: Encode / decode URLs
Relevant Go Source code: http://golang.org/src/pkg/net/url/url.go?s=14330:14361#L553