Fork me on GitHub
#boot
<
2017-04-06
>
juhoteperi07:04:13

@kenny Not possible, default options are handled inside Cljs compiler, there is no API to get them

kumarshantanu09:04:18

Reposting my earlier question: What do boot users use as a substitute for the lein-ring plugin?

martinklepsch11:04:06

@kumarshantanu boot-http, boot-serve come to mind, there are more options…

kumarshantanu12:04:04

Thanks, @alandipert @martinklepsch

mobileink14:04:26

does anybody have an example of how to use --filter with boot-test?

kumarshantanu14:04:15

In deftask dev (in boot-war-example) I am trying to (require '[foo.bar :as bar]) (bar/baz) but it errors out saying No such namespace: bar

kumarshantanu14:04:10

What’s a better way to require a namespace and call a fn in it?

kumarshantanu17:04:48

Fixed it by putting the require outside of the task

pesterhazy17:04:46

You could use resolve instead

pesterhazy17:04:31

When this PR is merged (https://github.com/boot-clj/boot/pull/597), the new call task could help as well

pesterhazy17:04:09

(clandestine advocacy for my PR alert)

kumarshantanu17:04:34

@pesterhazy wow, thanks! I was looking for a boot alternative to lein run too

kumarshantanu17:04:54

which this PR seems to be addressing

pesterhazy17:04:05

correct 🙂

kumarshantanu18:04:35

I’m trying to debug a stack trace in boot dev run

java.lang.Thread.run              Thread.java:  745
java.util.concurrent.ThreadPoolExecutor$Worker.run  ThreadPoolExecutor.java:  617
 java.util.concurrent.ThreadPoolExecutor.runWorker  ThreadPoolExecutor.java: 1142
               java.util.concurrent.FutureTask.run          FutureTask.java:  266
                                               ...
               clojure.core/binding-conveyor-fn/fn                 core.clj: 1938
                                 boot.core/boot/fn                 core.clj: 1029
                               boot.core/run-tasks                 core.clj: 1019
                    boot.task.built-in/fn/fn/fn/fn             built_in.clj:  477
                    boot.task.built-in/fn/fn/fn/fn             built_in.clj:  479
java.lang.NullPointerException:
    clojure.lang.ExceptionInfo:
    file: "/var/folders/cv/myzdv_vd675g4l7y92jx9bm5lflvxq/T/boot.user6365568036974101588.clj"
    line: 19

kumarshantanu18:04:12

Can anybody share a pointer on how to debug this?

kumarshantanu19:04:29

I’m using boot 2.7.1

pesterhazy19:04:49

@kumarshantanu try boot -b to print the generated script to see line numbers

kumarshantanu19:04:51

@pesterhazy Thanks, line number 19 is as follows: (clojure.core/let [boot?__1744__auto__ true] (clojure.core/if-not boot?__1744__auto__ (clojure.core/when-let [main__1745__auto__ (clojure.core/resolve (quote boot.user/-main))] (main__1745__auto__)) (boot.core/boot "boot.task.built-in/help")))

pesterhazy19:04:05

looks like boot.user/-main does not exist?

pesterhazy19:04:13

@kumarshantanu ^^

kumarshantanu19:04:47

@pesterhazy I have no reference to any boot.user/-main in my build.boot file

pesterhazy19:04:22

it's hard to help without seeing the boot file

kumarshantanu19:04:43

@pesterhazy I’ve pasted my build.boot file here: https://pastebin.com/09Hc2i9v

kumarshantanu19:04:35

@pesterhazy Sorry to bother you, I found the issue was handler-init returning nil, which was one of the args to comp.

pesterhazy19:04:05

no problem, it's a bit tricky to build.boot

phreed21:04:54

I have a question about the set-env! function. Are all the keys present on ? In particular I have seen :init-ns mentioned in build.boot files in other projects and am wondering what it does.

phreed21:04:17

The boot run task is not a built-in for boot. shows that the namespace is not optional. If that argument is not present a java.lang.NullPointerException results. When this boot task failed there is little information to guide the search (in this case I stumbled upon the root cause).