Go - JSON-RPC - “too many colons”

前端 未结 1 976
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-01-16 04:06

I\'m trying to call a HTTP JSON-RPC server for Bitcoin using Go (not on GAE), but I get error of

dial tcp http://user:pass@127.0.0.1:8332: too many colons in         


        
1条回答
  •  孤城傲影
    2021-01-16 04:42

    Use brackets around the host like this:

    [user:pass@127.0.0.1]:8332
    

    Reference:

    http://golang.org/src/pkg/net/ipsock.go?s=2247:2304#L68

    0 讨论(0)
提交回复
热议问题