Replies: 1 comment
-
The fix to the GraphQL parsing problem above was not the line endings, but rather embedded characters (first diff below): A further problem followed which was also in a graphql schema which contained a single line : ../library.graphql I bypassed that with the second diff below: After that it all built and ran on Windows. ================================================= DIFF 1: diff --git a/graphql/exe/schema.graphql b/graphql/exe/schema.graphql -union Writing = Book |Article type Author {
|
Beta Was this translation helpful? Give feedback.
-
Hi there.
Mu-Haskell is an interesting package thank you. It's certainly pushing my technical limits! (Good)
Building an up to date version of the repo on Windows with Stack in the Git Bash terminal, I get the error shown below. I believe from the \n's in the parsed GraphQL spec that this is about line endings. I'm building on a quick train commute (Eastern Australian Time), so I won't be able to follow up on that possibility right now. First thing I'll try will be to modify the line endings in the spec file.
If you have any other advice please let me know.
Additional info is that to build mu-haskell I had to comment out the Kafka related items shown in the diff further below.
Cheers
Mike Thomas
======================================================================
mu-grpc-client > [2 of 5] Compiling Mu.GRpc.Client.Optics [Mu.GRpc.Client.Internal changed]
mu-graphql >
mu-graphql > exe\Main.hs:39:1: error:
mu-graphql > could not parse graphql spec: "ParseErrorBundle {bundleErrors = TrivialError 160 (Just (Tokens ('\9516' :| ""))) (fromList [Tokens ('_' :| "")]) :| [], bun
dlePosState = PosState {pstateInput = "type Book {\n id: Int!\n title: String!\n author: Author!\n info: JSON\n}\n\ntype Article {\n id: Int!\n title: String!\n author: Autho
r!\n}\n\nunion Writing = Book |\9516\225Article\n\ntype Author {\n id: Int!\n name: String!\n writings: [Writing!]!\n}\n\ntype Query {\n author(name: String! = \".\"): A
uthor\n book(title: String! = \".\"): Book\n authors: [Author!]!\n books: [Book!]!\n}\n\ntype Subscription {\n books: Book!\n}\n\nschema {\n query: Query\n subscription:
Subscription\n}\n", pstateOffset = 0, pstateSourcePos = SourcePos {sourceName = "", sourceLine = Pos 1, sourceColumn = Pos 1}, pstateTabWidth = Pos 8, pstateLinePrefix = ""}}"
mu-graphql > |
mu-graphql > 39 | graphql "ServiceDefinition" "exe/schema.graphql"
mu-graphql > | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
mu-graphql >
mu-grpc-client > [3 of 5] Compiling Mu.GRpc.Client.Record [Mu.GRpc.Client.Internal changed]
===================================================================
$ git diff
warning: LF will be replaced by CRLF in cabal.project.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in stack.yaml.
The file will have its original line endings in your working directory
diff --git a/cabal.project b/cabal.project
index 653d413..7fcb8f7 100644
--- a/cabal.project
+++ b/cabal.project
@@ -3,7 +3,6 @@ allow-newer: base, network, ghc-prim, template-haskell, proto3-wire, http2
preferences: base16-bytestring < 1
packages: adapter/avro/
diff --git a/stack.yaml b/stack.yaml
index 93307f9..b11c33e 100644
--- a/stack.yaml
+++ b/stack.yaml
@@ -3,7 +3,7 @@ allow-newer: true
packages:
-- adapter/kafka
+# - adapter/kafka
@@ -32,6 +32,8 @@ extra-deps:
-- hw-kafka-conduit-2.7.0
+# - hw-kafka-conduit-2.7.0
+- lzma-clib-5.2.2@sha256:25eb43d5fd8a8ab58380f475b91fb1fa907381f8a81c8d8ba63ba428d97ae0cc,4900
+#- unix-2.7.2.2@sha256:ddb8fc5d5eede81dfad7846eceb65267fe4cf8b4f324bc74542f694a32335ef2,3496
Beta Was this translation helpful? Give feedback.
All reactions