Strange No instance error with cabal install

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Strange No instance error with cabal install

Rune Harder Bak
Sometimes when one of our developers (using Arch-linux) tries to cabal
install packages he gets
a "no instance for" error.
Code that compiles fine on my computer, and other computers I try it
on. Even some packages on hackage
(trying to install aeson-native for instance gives Data/Aeson/Types.hs:196:22:
    No instance for (NFData Object)
      arising from a use of `rnf'
    Possible fix: add an instance declaration for (NFData Object)
    In the expression: rnf o
    In an equation for `rnf': rnf (Object o) = rnf o
    In the instance declaration for `NFData Value')
I tried removing the .ghc and .cabal folder, even reinstalled ghc-7.04
and cabal-install (most recent), but the problem persisted (might not
have been a clean install though, I'm no Arch expert)
I know this is kind of vauge, and not in she shape of filling a bug
report, heck I can't even reproduce the error on my computer.
But perhaps somebody else has run in to this strange behavior before?

Best,
Rune

_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe
Reply | Threaded
Open this post in threaded view
|

Re: Strange No instance error with cabal install

Roel van Dijk-3
I believe this is because of aeson depending on *any* version of
deepseq. This was very recently fixed in the development version:

  https://github.com/mailrank/aeson/pull/25

2011/9/20 Rune Harder Bak <[hidden email]>:

> Sometimes when one of our developers (using Arch-linux) tries to cabal
> install packages he gets
> a "no instance for" error.
> Code that compiles fine on my computer, and other computers I try it
> on. Even some packages on hackage
> (trying to install aeson-native for instance gives Data/Aeson/Types.hs:196:22:
>    No instance for (NFData Object)
>      arising from a use of `rnf'
>    Possible fix: add an instance declaration for (NFData Object)
>    In the expression: rnf o
>    In an equation for `rnf': rnf (Object o) = rnf o
>    In the instance declaration for `NFData Value')
> I tried removing the .ghc and .cabal folder, even reinstalled ghc-7.04
> and cabal-install (most recent), but the problem persisted (might not
> have been a clean install though, I'm no Arch expert)
> I know this is kind of vauge, and not in she shape of filling a bug
> report, heck I can't even reproduce the error on my computer.
> But perhaps somebody else has run in to this strange behavior before?
>
> Best,
> Rune
>
> _______________________________________________
> Haskell-Cafe mailing list
> [hidden email]
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>

_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe
Reply | Threaded
Open this post in threaded view
|

Re: Strange No instance error with cabal install

Roel van Dijk-3
I see the aeson version with the stricter dependency on deepseq < 1.2
is now also released on hackage:

http://hackage.haskell.org/package/aeson-0.3.2.12

_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe
Reply | Threaded
Open this post in threaded view
|

Re: Strange No instance error with cabal install

Rune Harder Bak
Sorry, forgot to send to the list, But everything works today, and the
commit was pulled from aeson to aeson-native,
so that must have been it. Thanks!


On Wed, Sep 21, 2011 at 8:20 AM, Rune Harder Bak <[hidden email]> wrote:

> So you are saying, that this is basically because he has other version
> of different packages,
> not providing the same instances, that makes sense.
> The other problem was no instance for Default (Request R) (Request
> from Network.Wai)
> It was provided by http-enumerator, but maybe not in his version of the package.
>
> I tried with aeson-native after you post without look, but I see a new
> one has been released now.
> Going to try it today.
> Thanks!
>
>
> On Tue, Sep 20, 2011 at 2:00 PM, Roel van Dijk <[hidden email]> wrote:
>> I see the aeson version with the stricter dependency on deepseq < 1.2
>> is now also released on hackage:
>>
>> http://hackage.haskell.org/package/aeson-0.3.2.12
>>
>

_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe