Fork me on GitHub
#babashka
<
2019-12-25
>
Santiago12:12:19

trying babashka for the first time 😄

Could not resolve symbol: json/parsed-seq
after I try to run my script:
(def all-airports
  (json/parsed-seq (io/reader "airport-codes_onlyscheduled.json") true))
do I need to load a namespace to get that function? I thought chesire was already loaded as json

borkdude12:12:36

@slack.jcpsantiago I must have forgotten to add it:

(def cheshire-core-namespace
  {'encode json/encode
   'generate-string json/generate-string
   'encode-stream json/encode-stream
   'generate-stream json/generate-stream
   'encode-smile json/encode-smile
   'generate-smile json/generate-smile
   'decode json/decode
   'parse-string json/parse-string
   'decode-smile json/decode-smile})

borkdude12:12:12

PR welcome or I'll do it myself. Maybe good to check other missing functions as well

Santiago12:12:34

Cool, I can write a PR 👍

borkdude12:12:52

I think I went through the README and added every function mentioned there

borkdude12:12:15

but it's mentioned there I see now, so I just forgot 🙂

Santiago18:12:49

Thank you for the awesome work! This will help me deliver a nice Xmas present to my friends 👍😁