snapframework / snap

Top-level package for the official Snap Framework libraries, includes the snaplets API as well as infrastructure for sessions, auth, and templates.
http://snapframework.com/
BSD 3-Clause "New" or "Revised" License
455 stars 68 forks source link

Remove dependency on errors, depend on either instead #153

Closed DanBurton closed 9 years ago

DanBurton commented 9 years ago

Rather than modify existing code, I found it preferable to just copy the small slice of errors that was needed. (Like snap, errors is BSD3 licensed.)

This PR is in the same spirit as https://github.com/snapframework/heist/pull/67.

bergmark commented 9 years ago

Ping?

mightybyte commented 9 years ago

I'm planning to look at it this weekend.

hvr commented 9 years ago

btw, judging from http://www.reddit.com/r/haskell/comments/3ded39/why_cant_we_have_an_eithert_in_transformers/ct4mnk1

@ekmett seems to suggest that either be considered deprecated (IIUC):

With 7.10+, we can finally start to see some migration to ExceptT and in theory the either package can start to dissolve over time as more and more code can finally start to use transformers to get ExceptT rather than either for EitherT.

ekmett commented 9 years ago

I wouldn't go so far as to say that.

I'd say that in a few years I'd be up for deprecating EitherT from it.

For now, users don't have a good story for how to get ExceptT. transformers-compat, being the best tool we have for doing it now, is going to have an awkward adolescence when the next version of transformers comes out and breaks Eq1 .. Show1.