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

some warnings I don't understand #13

Closed
humanitiesNerd opened this issue Nov 12, 2014 · 5 comments
Closed

some warnings I don't understand #13

humanitiesNerd opened this issue Nov 12, 2014 · 5 comments
Labels

Comments

@humanitiesNerd
Copy link

I have written down the code from this tutorial
https://github.com/swannodette/om/wiki/Intermediate-Tutorial

With lein the clojurescript code compiles.

With boot 5 warnings pop up. Here they are

me@my-machine.net boot-cljs-example$ boot watch speak cljs-repl cljs -usO none reload
<< started reload server on ws://localhost:8090 >>
Starting file watcher (CTRL-C to quit)...

nREPL server listening: 0.0.0.0:37240
Compiling main.js...
WARNING: Use of undeclared Var cljs.core.async/do-alts at line 62 file:/home/me/.m2/repository/org/clojure/core.async/0.1.267.0-0d7780-alpha/core.async-0.1.267.0-0d7780-alpha.jar!/cljs/core/async/impl/ioc_helpers.cljs
WARNING: Bad method signature in protocol implementation, impl/Handler does not declare method called lock-id at line 205 file:/home/me/.m2/repository/org/clojure/core.async/0.1.267.0-0d7780-alpha/core.async-0.1.267.0-0d7780-alpha.jar!/cljs/core/async.cljs
WARNING: Use of undeclared Var cljs.core.async.impl.protocols/lock-id at line 208 file:/home/me/.m2/repository/org/clojure/core.async/0.1.267.0-0d7780-alpha/core.async-0.1.267.0-0d7780-alpha.jar!/cljs/core/async.cljs
WARNING: Bad method signature in protocol implementation, impl/Handler does not declare method called lock-id at line 205 .boot/tmp/m6p/ye6vpt/out/cljs/core/async.cljs
WARNING: Use of undeclared Var cljs.core.async.impl.protocols/lock-id at line 208 .boot/tmp/m6p/ye6vpt/out/cljs/core/async.cljs
Adding <script> tags to html...
Elapsed time: 20,862 sec

Here's my build.boot file

(set-env!
 :src-paths    #{"src/clj" "src/cljs"}
 :rsc-paths    #{"html"}
 :dependencies '[[adzerk/boot-cljs      "0.0-2371-22" :scope "test"]
                 [adzerk/boot-cljs-repl "0.1.5"       :scope "test"]
                 [adzerk/boot-reload    "0.1.3"       :scope "test"]
                 ;[ring/ring "1.2.1"]
                 [org.clojure/clojurescript "0.0-2173"]
                 [org.clojure/core.async "0.1.267.0-0d7780-alpha"]
                 [om "0.5.3"]
                 [om-sync "0.1.1"]
                 ;[compojure "1.1.6"]
                 [fogus/ring-edn "0.2.0"]
                 ;[com.datomic/datomic-free "0.9.4699"]
                 ])

(require
 '[adzerk.boot-cljs      :refer :all]
... blah blah

and here's my lein project.clj file

(defproject om-async "0.1.0-SNAPSHOT"
  :description "FIXME: write description"
  :url "http://example.com/FIXME"
  :license {:name "Eclipse Public License"
            :url "http://www.eclipse.org/legal/epl-v10.html"}

  :jvm-opts ^:replace ["-Xmx1g" "-server"]

  :dependencies [[org.clojure/clojure "1.5.1"]
                 [org.clojure/clojurescript "0.0-2173"]
                 [ring/ring "1.2.1"]
                 [org.clojure/core.async "0.1.267.0-0d7780-alpha"]
                 [om "0.5.3"]
                 [om-sync "0.1.1"]
                 [compojure "1.1.6"]
                 [fogus/ring-edn "0.2.0"]
                 [com.datomic/datomic-free "0.9.4699"]]
... blah blah blah

As you can see core.async and clojurescript are exactly the same in both lein and boot.

What am I missing ?

@micha
Copy link
Contributor

micha commented Nov 12, 2014

@humanitiesNerd Hi, I'll have a look and see what's up. Can you make a repo that demonstrates the problem please? I'll see if I can reproduce the issue here.

@humanitiesNerd
Copy link
Author

@micha Thank you for your offer.

It's here https://github.com/humanitiesNerd/boot-cljs-example/tree/attempetd-fusion

it's the branch "attempetd-fusion" of the repo (please note the misspelling)

@micha
Copy link
Contributor

micha commented Nov 12, 2014

I submitted a pull request with some changes to the project dependencies. I saw two things that were causing problems:

  • You don't need an explicit dependency on CLJS. The boot CLJS compiler task runs the compiler in an isolated classloader, completely separate from your project. You'll see that the boot-cljs version is linked to the version of CLJS it ships with. You had a different version of CLJS as an explicit dependency which was overriding the one the task was trying to use.
  • You had an older version of core.async. I did a little bit of research and found references to this error on the CLJS mailing list, but nothing really conclusive. However, using the latest version of core.async seems to have fixed it.

@micha
Copy link
Contributor

micha commented Nov 12, 2014

Please feel free to reopen this issue if the PR doesn't resolve the problem for you. Thanks!

@micha micha closed this as completed Nov 12, 2014
@micha micha added the question label Nov 12, 2014
@humanitiesNerd
Copy link
Author

@micha Thanks. I copied and pasted pieces of code from the David Nolen's tutorial, that's how that version ended up there.

It worked with lein anyway.

Should I run into more problems because of this version bump, I'll reopen this.

It's ok for now.

Thanks again

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

No branches or pull requests

2 participants