This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-11-01
Channels
- # announcements (7)
- # babashka (41)
- # beginners (117)
- # cider (3)
- # clj-kondo (145)
- # cljdoc (25)
- # cljs-dev (19)
- # clojure (197)
- # clojure-dev (14)
- # clojure-europe (4)
- # clojure-italy (3)
- # clojure-nl (2)
- # clojure-spec (11)
- # clojure-uk (21)
- # clojuredesign-podcast (5)
- # clojurescript (29)
- # code-reviews (4)
- # cursive (87)
- # data-science (11)
- # datomic (29)
- # duct (2)
- # emacs (10)
- # graalvm (1)
- # lumo (13)
- # malli (2)
- # nrepl (5)
- # off-topic (25)
- # onyx (1)
- # pathom (6)
- # reagent (20)
- # reitit (4)
- # rewrite-clj (7)
- # shadow-cljs (114)
- # spacemacs (16)
For fun, I created a toy resolver to understand how batching works with resolvers. This led to some surprising results, with the batching taking quite a bit longer to run than the serial one.
It seems that this is due to it incrementally running the resolver with one new input added each time.
Have I missed something crucial here?
(It’s using Aleph, so http/get
returns a Manifold)
Nevermind, I just discovered the difference between parser
and parallel-parser
🙂
Initially, I thought it redundant, since the web server is parallel anyway. Turns out it has more implications than that.
Hey @wilkerlucio I'm having some problems here. I'm hoping to be able to read a mutation query off the wire from an API and then throw it into pathom.
A call like this works perfectly fine:
(<!! (parser {} '[{(hello {}) [:greeting]}]))
however when I remove the single quote yielding (<!! (parser {} [{(hello {}) [:greeting]}]))
I get an "invalid expression" error.
This matters because when I read my queries off the wire using code like this:
(let [query (read-query-off-the-wire)]
(<!! (parser {} (quote query))))
it does not evaluate the contents of the query variable. So now I'm faced with this weird problem where pathom wants an unevaluated expression, and I need to evaluate my variable within a quote
function which stops me from being able to evaluate it. What can I do?hello @brian.rogers , the reason you need to quote when you write the code like that is that otherwise it tries to run it like a fn, which is not what you need, you need a list with symbol
if you get something that is already that literal list, you dont need to quote, so you can just forward it, makes sense?
Thank you @wilkerlucio!