UnsupportedOperationException nth not supported on this type: Keyword
AndreTheHunter opened this issue · 2 comments
AndreTheHunter commented
Reoccurring from #8
I get the error:
UnsupportedOperationException nth not supported on this type: Keyword clojure.lang.RT.nthFrom (RT.java:965)
When running:
(venia.core/graphql-query
{:venia/queries [[:employee {:id 1 :active true}
[:name {:preferNickname 1}
:address
[:friends
[:name
:email]]]]]})
Using [vincit/venia "0.2.4"]
with [org.clojure/clojure "1.9.0-beta2"]
macluck commented
@AndreTheHunter You need to wrap :name {:preferNickname 1}
in vector:
(venia.core/graphql-query
{:venia/queries [[:employee {:id 1 :active true}
[[:name {:preferNickname 1}]
:address
[:friends
[:name
:email]]]]]})
Probably, I should have documented it better. Also, i should definitely improve error messages, because quite often they don't make any sense.
AndreTheHunter commented
@macluck Thanks, that sorted it out!
Yes, please update the documentation to make it clearer