haskell-graphql / graphql-api

Write type-safe GraphQL services in Haskell
BSD 3-Clause "New" or "Revised" License
406 stars 35 forks source link

I try to install with cabal install graphql-api, but I have an issue #121

Closed tibastral closed 7 years ago

tibastral commented 7 years ago

Building library for graphql-api-0.1.2.. [ 1 of 18] Compiling GraphQL.Internal.Arbitrary ( src/GraphQL/Internal/Arbitrary.hs, dist/build/GraphQL/Internal/Arbitrary.o ) [ 2 of 18] Compiling GraphQL.Internal.OrderedMap ( src/GraphQL/Internal/OrderedMap.hs, dist/build/GraphQL/Internal/OrderedMap.o ) [ 3 of 18] Compiling GraphQL.Internal.Syntax.Tokens ( src/GraphQL/Internal/Syntax/Tokens.hs, dist/build/GraphQL/Internal/Syntax/Tokens.o ) [ 4 of 18] Compiling GraphQL.Internal.Syntax.AST ( src/GraphQL/Internal/Syntax/AST.hs, dist/build/GraphQL/Internal/Syntax/AST.o )

src/GraphQL/Internal/Syntax/AST.hs:55:1: warning: [-Wdodgy-imports] Module ‘Protolude’ does not export ‘Type’ | 55 | import Protolude hiding (Type) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [ 5 of 18] Compiling GraphQL.Internal.Syntax.Parser ( src/GraphQL/Internal/Syntax/Parser.hs, dist/build/GraphQL/Internal/Syntax/Parser.o )

src/GraphQL/Internal/Syntax/Parser.hs:86:23: error: Ambiguous occurrence ‘option’ It could refer to either ‘Protolude.option’, imported from ‘Protolude’ at src/GraphQL/Internal/Syntax/Parser.hs:8:1-41 (and originally defined in ‘Data.Semigroup’) or ‘Data.Attoparsec.Text.option’, imported from ‘Data.Attoparsec.Text’ at src/GraphQL/Internal/Syntax/Parser.hs:23:5-10 (and originally defined in ‘Data.Attoparsec.Combinator’) | 86 | field = AST.Field <$> option empty (pure <$> alias) | ^^^^^^

src/GraphQL/Internal/Syntax/Parser.hs:333:12: error: Ambiguous occurrence ‘option’ It could refer to either ‘Protolude.option’, imported from ‘Protolude’ at src/GraphQL/Internal/Syntax/Parser.hs:8:1-41 (and originally defined in ‘Data.Semigroup’) or ‘Data.Attoparsec.Text.option’, imported from ‘Data.Attoparsec.Text’ at src/GraphQL/Internal/Syntax/Parser.hs:23:5-10 (and originally defined in ‘Data.Attoparsec.Combinator’) | 333 | optempty = option mempty | ^^^^^^ cabal: Leaving directory '/var/folders/zb/jqp3vqj170nc5vkyw8k2p_tw0000gn/T/cabal-tmp-13818/graphql-api-0.1.2' cabal: Error: some packages failed to install: graphql-api-0.1.2-HmKbgdf15yT6zJHN4EkHkp failed during the building phase. The exception was: ExitFailure 1

jml commented 7 years ago

I think probably we need to put an upper bound on the protolude version (or update the code to use the latest protolude and then put a lower bound on it).

I personally won't have time to address this over the next few weeks, but would be happy to review a PR.

tibastral commented 7 years ago

What version of Protolude is working for you ?

jml commented 7 years ago

Whichever is included in the Stackage nightly-2017-01-25 resolver, c.f. https://github.com/jml/graphql-api/blob/master/stack.yaml#L1

On Mon, 4 Sep 2017 at 13:15 Thibaut Assus notifications@github.com wrote:

What version of Protolude is working for you ?

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/jml/graphql-api/issues/121#issuecomment-326948328, or mute the thread https://github.com/notifications/unsubscribe-auth/AAHq6hPT5JJi_mH24CpsJRKEv4kAoXZCks5se-nigaJpZM4PL1Z_ .

teh commented 7 years ago

    protolude-0.1.10
``` is working for me, so it's probably protolude 0.2 that breaks 
teh commented 7 years ago

@tibastral does the latest master (which includes https://github.com/jml/graphql-api/pull/123) work for you?

jml commented 7 years ago

@tibastral I'm closing this for now, but please re-open if you're still having issues.