You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One of my project stopped building, because of a breaking change, the result of defaultMakeClientRequest (which is just Network.HTTP.Client.Request) no longer showable. Because now it returns IO Request compared to previously returning just Request. I looked at the sources and see only:
return Client.defaultRequest ...
So there are actually no side-effects. What’s the point of having this return and wrapping the result into IO breaking the backward-compatibility? Are there any plans to have some side-effects in the future for this function? Maybe drop a comment about it if that’s true?
If this was some kind of a mistake and you don’t want to break API again, maybe at least change the type to Monad m => ... -> m Request so one can just use some Identity without a need to involve IO for no reason while previous code written for when it was IO would still work and be compatible?
The text was updated successfully, but these errors were encountered:
@arianvp thanks for the link, though trying to read it through it still does not answer my question, changelog says “Run ClientEnv's makeClientRequest in IO.” okay, but why would you ever do that? So that you don’t need to write pure/return somewhere else? A pretty questionable idea to make it hardly depend on IO for that alone reason.
One of my project stopped building, because of a breaking change, the result of
defaultMakeClientRequest
(which is justNetwork.HTTP.Client.Request
) no longershow
able. Because now it returnsIO Request
compared to previously returning justRequest
. I looked at the sources and see only:return Client.defaultRequest ...
So there are actually no side-effects. What’s the point of having this
return
and wrapping the result intoIO
breaking the backward-compatibility? Are there any plans to have some side-effects in the future for this function? Maybe drop a comment about it if that’s true?If this was some kind of a mistake and you don’t want to break API again, maybe at least change the type to
Monad m => ... -> m Request
so one can just use someIdentity
without a need to involveIO
for no reason while previous code written for when it wasIO
would still work and be compatible?The text was updated successfully, but these errors were encountered: