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

Unable to resolve var #17

Open
DonyorM opened this issue Sep 14, 2018 · 5 comments
Open

Unable to resolve var #17

DonyorM opened this issue Sep 14, 2018 · 5 comments

Comments

@DonyorM
Copy link

DonyorM commented Sep 14, 2018

I'm currently getting the following error when trying to run boot-figreload:

java.lang.RuntimeException: Unable to resolve var: figwheel-sidecar.build-middleware.injection/figwheel-connect-ns-name in this context
clojure.lang.Compiler$CompilerException: java.lang.RuntimeException: Unable to resolve var: figwheel-sidecar.build-middleware.injection/figwheel-connect-ns-name in this context, compiling:(powerlaces/boot_figreload/figwheel.clj:25:3)
             clojure.lang.ExceptionInfo: java.lang.RuntimeException: Unable to resolve var: figwheel-sidecar.build-middleware.injection/figwheel-connect-ns-name in this context, compiling:(powerlaces/boot_figreload/figwheel.clj:25:3)

Here's the task that runs when this issue is caused:

(deftask figwheel
  "Runs figwheel and enables reloading."
  []
  (dev)
  (require '[powerlaces.boot-figreload :refer [reload]])
  (let [reload (resolve 'powerlaces.boot-figreload/reload)]
    (comp
     (start-server)
     (watch)
     (reload :client-opts {:debug true})
     (cljs-repl)
     (cljs))))
@arichiardi
Copy link
Contributor

Hi! Figwheel is tested against the version specified in the README and fortunately I haven't had time for upgrading it. Can it be a version issue?

@DonyorM
Copy link
Author

DonyorM commented Sep 14, 2018

Hey thanks for answering! I'm depending on figwheel-sidecar 0.5.15-SNAPSHOT which seems to be what figreload wants. It's not actually specified in the README, I can only see it in the commit log, FYI.

I check boot show -d and the output for figwheel-sidecar is a little weird:

[figwheel-sidecar "0.5.15-20180224.195519-22"]
??? [com.stuartsierra/component "0.3.2"]
?   ??? [com.stuartsierra/dependency "0.2.0"]
??? [figwheel "0.5.15-20180224.195458-12" :exclusions [[org.clojure/tools.reader]]]
??? [hawk "0.2.11" :exclusions [[org.clojure/clojure]]]
?   ??? [net.incongru.watchservice/barbary-watchservice "1.0"]
?       ??? [net.java.dev.jna/jna "3.2.2"]

Is that what you expected?

EDIT: I tried removing the figwheel-sidecar direct dependency from my build.boot, I realized it wasn't needed, and had the same error.

@arichiardi
Copy link
Contributor

Sorry, it should be clearer in the README, but the boot-figreload version follows the supported figwheel one, so in this case we support 0.5.14.

@DonyorM
Copy link
Author

DonyorM commented Sep 14, 2018

Same error when I specify 0.5.14.

Fig-reload seems to use 0.5.15 (beabdd0#diff-0a1425bd66240468daf4c256a411ce75R1). Any chance that's the issue?

@arichiardi
Copy link
Contributor

Ah, yes well, I was still kind of working on that, this is why it is still -SNAPSHOT. For sure that is the problem...

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