hackney
hackney copied to clipboard
redirect to relative url with proxy fails
** (FunctionClauseError) no function clause matching in :hackney_url.transport_scheme/1
(hackney) ../deps/hackney/src/hackney_url.erl:107: :hackney_url.transport_scheme(:hackney_http_connect)
(hackney) ../deps/hackney/src/hackney.erl:888: :hackney.absolute_url/2
(hackney) ../deps/hackney/src/hackney.erl:738: :hackney.maybe_redirect/2
(hackney) ../deps/hackney/src/hackney.erl:374: :hackney.send_request/2
lib/httpoison/base.ex:402: HTTPoison.Base.request/9
This happens only on redirection to relative url with proxy option. Hackney tries to convert the relative url to absolute, but hackney_http_connect
transport type is not handled in hackney_url
module.
Hi Any news about issue ?
I have this exact same issue on my Elixir reverse proxy (using HTTPoison based on hackney). I'd like to help by opening by a PR, but I'm new to Elixir, and know even less about Erlang 😬
@benoitc hey, were you able to work on this. we are having the exact issue as added on https://github.com/edgurgel/httpoison/issues/112#issuecomment-698842552 and is kinda blocking our flows. I would be happy to help out, although not entirely familiar with erlang.
@ananthakumaran were you able to work around this somehow? 🤔
I think we ended up handling redirect response ourselves instead of using follow_redirect
.