mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-11-02 12:56:22 +00:00
Downloads set req.URL.Opaque to keep "+" percent-encoded in the path. URL.String() prints "scheme:opaque" and drops the host, so every error from the http client showed a URL such as "https:/repos/debian/...", lacking a host name. The request itself was correct, but the message sent me to look for a malformed URL. Set req.URL.RawPath instead. The escaping still reaches the wire through EscapedPath(), and String() keeps the scheme and the host. The proxy special case is no longer necessary. Requests through a proxy now get the same "+" escaping as direct requests.