tesla
tesla copied to clipboard
[Finch] Change error handling, fix for response stream
SSE introduced inconsistent error here: https://github.com/elixir-tesla/tesla/blob/tt/finch-stream/lib/tesla/adapter/finch.ex#L143 Finch adapter was always expecting Mint error.
I've looked at other adapters and seems like {:error, :timeout} is used consistently, previous error-handling implementation would respond with {:error, "timeout"} - thus the change not to use Exception.message/1 anymore. This is potentially a breaking change for anyone using Finch adapter.