lib_rpc_http: enable the client to follow redirects
This MR depends on opam-repository!357 (merged), which must be merged first.
Context
After the introduction of middleware into resto in nomadic-labs/resto!35 (merged), tezos-proxy-server now emits 301 Moved Permanently responses for certain requests (thanks to the redirects MR at !5180 (merged)). Currently tezos-client cannot handle these responses itself (tracked at #3268 (closed)), due to the historic lack of support within resto for this.
resto 1.0 includes nomadic-labs/resto!45 (merged), which introduces the ability for the resto client to follow redirects with a configurable upper limit on the number of redirections allowed.
When I first created this MR, it was against a WIP branch of resto, but the 1.0 release adds various other backwards-incompatible changes. @Killian-Delarue has been working on another resto 1.0-dependent MR (!6343 (merged)) which incidentally contains fixes for all of these, so I've rebased this MR on his branch. This also means I no longer have to do various bits of housekeeping in my own commits, such as removing the Redirect_not_supported error handling. Once !6343 (merged) is merged, the size of the non-test changes in this MR will be a single line. (No actual work had to be done within Tezos to support this feature per se!)
Additionally, we reset a bunch of regressions, which the previous redirects MR (!5180 (merged)) had changed — instead of uninformative redirect failure errors, now these tests contain actually meaningful errors again.
Fixes #3268 (closed).