ekmett / contravariant

Haskell 98 contravariant functors
http://hackage.haskell.org/package/contravariant
Other
73 stars 24 forks source link

contravariant-1.5 doesn't build against transformers-0.5.5.0 #60

Closed 23Skidoo closed 5 years ago

23Skidoo commented 5 years ago

This is with GHC 8.6.4. Steps to reproduce:

$ cabal new-build -f-safe -f+semigroups -f+statevar -f+tagged --constraint="StateVar ==1.1.1.1" --constraint="transformers ==0.5.6.2" --constraint="base ==4.12.0.0"
[Succeeds]

$ cabal new-build -f-safe -f+semigroups -f+statevar -f+tagged --constraint="StateVar ==1.1.1.1" --constraint="transformers ==0.5.5.0" --constraint="base ==4.12.0.0"
[Fails]

Compile errors look like this:

[1 of 3] Compiling Data.Functor.Contravariant.Divisible ( src/Data/Functor/Contravariant/Divisible.hs, /home/refold/code/scrive/contravariant-1.5/dist-newstyle/build/x86_64-linux/ghc-8.6.4/contravariant-1.5/build/Data/Functor/Contravariant/Divisible.o ) [Data.StateVar changed]

src/Data/Functor/Contravariant/Divisible.hs:233:10: error:
    • Could not deduce (Contravariant (Backwards f))
        arising from the superclasses of an instance declaration
      from the context: Divisible f
        bound by the instance declaration
        at src/Data/Functor/Contravariant/Divisible.hs:233:10-47
    • In the instance declaration for ‘Divisible (Backwards f)’

I suggest bumping the lower bound on transformers to 0.5.6.0 (the first version that doesn't fail).

RyanGlScott commented 5 years ago

This is a bit of a tricky situation, as the version of transformers-0.5.5.0 that is on Hackage is not the same version that is shipped with GHC 8.6.1 through 8.6.3 (the former doesn't work with contravariant-1.5, whereas the latter does). See haskell-infra/hackage-trustees#209: I'd like to come to a resolution on that issue before making any changes to contravariant itself.

RyanGlScott commented 5 years ago

Now that transformers-0.5.5.2 has been released to Hackage, I believe this is no longer an issue. At the very least, cabal new-build -f-safe -f+semigroups -f+statevar -f+tagged --constraint="StateVar ==1.1.1.1" --constraint="transformers ==0.5.5.*" --constraint="base ==4.12.0.0" works for me.

Can you confirm that this is an acceptable state of affairs, @23Skidoo?

RyanGlScott commented 5 years ago

As far as I can tell, this matter has been fixed with the resolution of https://github.com/haskell-infra/hackage-trustees/issues/209. Do re-open if you are still experiencing issues.

23Skidoo commented 5 years ago

Great, thanks. We've upgraded to the latest transformers and are no longer experiencing the issue.