Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No reader function for tag #19

Closed
jungwookim opened this issue Sep 18, 2022 · 12 comments
Closed

No reader function for tag #19

jungwookim opened this issue Sep 18, 2022 · 12 comments

Comments

@jungwookim
Copy link

jungwookim commented Sep 18, 2022

Hi ! I'm trying to add alias :quickdoc in my deps.edn which contains a tagged literal, #env for clojure cli cuz I'm using this https://github.com/liquidz/build.edn/blob/a4a8f70d2df7591fd0eb7c455d7310f60600b8ac/doc/deploy.adoc#environmental-variables

However, it occurs an error No reader function for tag env. It'd be helpful to accept any literal tag in deps.edn or wanna expect an workaround.

If you give me an idea to work out, I want to contribute it as well.

Thank you for the quickdoc too!

@borkdude
Copy link
Owner

I think I know what the problem is. bb.edn is parsed by bb as EDN without support for tags.

A workaround is to move that to deps.edn and then use this in bb.edn:

{:deps {local/deps {:local/root "."}}}

@borkdude
Copy link
Owner

Made a bb issue here: babashka/babashka#1364

@borkdude
Copy link
Owner

O wait, you're not using bb for this maybe? Can you provide a full repro with your complete project, deps.edn + code + command line invocation?

@borkdude
Copy link
Owner

This project doesn't parse deps.edn so it might just be a tooling issue unrelated to quickdoc.

@jungwookim
Copy link
Author

jungwookim commented Sep 18, 2022

This is a repo I tried to make a quickdoc.

{:paths   ["src" "resources" "classes"]
 :deps    {camel-snake-kebab/camel-snake-kebab {:mvn/version "0.4.3"}
           com.github.seancorfield/honeysql    {:mvn/version "2.2.891"}
           com.rpl/specter                     {:mvn/version "1.1.4"}
           com.taoensso/nippy                  {:mvn/version "3.1.1"}
           com.taoensso/timbre                 {:mvn/version "5.2.1"}
           com.walmartlabs/lacinia             {:mvn/version "1.1"}
           failjure/failjure                   {:mvn/version "2.2.0"}
           io.sentry/sentry-clj                {:mvn/version "5.7.180"}
           medley/medley                       {:mvn/version "1.4.0"}
           org.clojure/clojure                 {:mvn/version "1.11.1"}
           org.clojure/data.json               {:mvn/version "2.4.0"}
           org.clojure/tools.logging           {:mvn/version "1.2.4"}
           org.clojure/core.match              {:mvn/version "1.0.0"}
           superlifter/superlifter             {:git/url "https://github.com/green-labs/superlifter.git"
                                                :sha     "e0df5b36b496c485c75f38052a71b18f02772cc0"}
           metosin/malli                       {:mvn/version "0.8.4"}
           com.github.seancorfield/next.jdbc   {:mvn/version "1.2.780"}
           aero/aero                           {:mvn/version "1.1.6"}}

 :aliases {:test     {:extra-paths ["test"]
                      :extra-deps  {io.github.cognitect-labs/test-runner {:git/tag "v0.5.0"
                                                                          :git/sha "b3fd0d2"}}
                      :exec-fn     cognitect.test-runner.api/test
                      :exec-args   {:excludes [:integration]}}

           :build    {:deps              {com.github.liquidz/build.edn {:git/tag "0.3.90"
                                                                        :git/sha "e3a3e31"}}
                      :ns-default        build-edn.main
                      :deploy-repository {:username #env YOUR_USERNAME
                                          :password #env YOUR_PASSWORD}}
           :quickdoc {:deps      {org.babashka/cli            {:mvn/version "0.2.11"}
                                  io.github.borkdude/quickdoc {:deps/root "jvm"
                                                               :git/sha   "c5320cbe311b651a60b47f4d00d7e8ab63291b6e"}}
                      :main-opts ["-m" "babashka.cli.exec" "quickdoc.api" "quickdoc"]
                      :exec-args {:github/repo "https://github.com/green-labs/gosura"
                                  :git/branch  "master"}}}}

An Above deps.edn is a full itself that I tried and a below is what I got,

❯ clj -M:quickdoc

Execution error at babashka.cli.exec/-main (exec.clj:39).
No reader function for tag env

Full report at:
/var/folders/s6/l1p_l9z50_g45bc3tfp3lrdr0000gn/T/clojure-6539955112641972439.edn

@jungwookim
Copy link
Author

This project doesn't parse deps.edn so it might just be a tooling issue unrelated to quickdoc.

It's true. I've read a whole code to find an issue and couldn't find a code parsing deps.edn.

@borkdude
Copy link
Owner

Ah, this is a bug in babashka CLI. I will fix.

@jungwookim
Copy link
Author

@borkdude Thank you! please let me know if PR is open :)

@borkdude
Copy link
Owner

Can you try with the just upgraded CLI:

           :quickdoc {:deps      {org.babashka/cli            {:mvn/version "0.4.36"}
                                  io.github.borkdude/quickdoc {:deps/root "jvm"
                                                               :git/sha   "c5320cbe311b651a60b47f4d00d7e8ab63291b6e"}}
                      :main-opts ["-m" "babashka.cli.exec" "quickdoc.api" "quickdoc"]
                      :exec-args {:github/repo "https://github.com/green-labs/gosura"
                                  :git/branch  "master"}}

@jungwookim
Copy link
Author

@borkdude it works! Could I know changes for it?

@borkdude
Copy link
Owner

Just pushed the change here: https://github.com/babashka/cli

@jungwookim
Copy link
Author

@borkdude Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants