#clojure logs

2009-11-05

00:22adityogood morning folks!
01:12hiredmanclojurebot: ping?
01:12clojurebotPONG!
04:00piccolinoI am trying to use a binding as a dynamically scoped variable, but I'm getting a compile error when I reference that variable in another lexical scope (another function that gets called by the binding's form). Is there something I can do about that?
04:00liwppiccolino: are you talking about the (binding ..) form?
04:00piccolinoYeah
04:01arbschtpiccolino: paste your code somewhere
04:01liwp~paste
04:01clojurebotlisppaste8, url
04:01lisppaste8To use the lisppaste bot, visit http://paste.lisp.org/new/clojure and enter your paste.
04:01liwppiccolino: and what's the error that you're getting?
04:03tomojfunctions don't know about variables that are dynamically bound for them
04:03tomojunless you tell them
04:03piccolinoHow do I tell them?
04:03tomojyou'd have to declare everything that might be bound
04:04tomojthere was a discussion about this on the compojure mailing list I think
04:04tomojsomeone wanted to do like rails where you can just refer to instance variables in the view whether they exist or not
04:04tomojand then dynamically bind them in the controller
04:04tomojbut the view function won't compile if the variable doesn't exist
04:05piccolinoAh, OK.
04:05piccolinoThat actually fixed it, thanks guys.
04:05tomojhmm
04:06piccolinoSo binding doesn't do destructuring?
04:06tomojif you're dynamically binding a var in another namespace, do you have to declare it fully-qualified in the other namespace that uses it?
04:08liwptomoj: I wouldn't think so, if you are (use...)ng the other namespace
04:17tomojwell my experiments just confused me even more :(
04:32AWizzArdI want to typehint that my function returns an array of (primitive) bytes. Is #^bytes the right tag?
04:35tomojI think it's [B
04:36AWizzArdfunny ;)
04:36tomoj"[" means array, "B" means bytes
04:36tomojbut that's the jvm, I haven't done much typehinting
04:38Chousuke#^bytes should work
04:38tomojhow do you typehint an array of objects?
04:39tomoj#^"[Lthe.class.name" ?
04:42cgrandtomoj: #^"[Lthe.class.name;" (adde semi-colon)
04:42cgrandadded
04:43carpdiemhey guys, i've been learning clojure over the past few days (coming from a python background), and i'm having a devil of a time understanding the clojure list comprehension style
04:43carpdiemi was wondering if anyone could help me understand it
04:43carpdiemthe (for ...) format is just not clicking with my brain
04:44cgrand(for [x coll] x) is equivalent to (seq coll)
04:44cgrand(for [x coll] (f x)) is equivalent to (map f coll)
04:45carpdiem@cgrand, let me ask a simple and specific question: how would you make a list of, say, 1/n for 0<=n<100?
04:45cgrand(for [x coll1 y coll2] [x y]) returns the cardinal product of coll1 and coll2 (coll1 being the "outer loop")
04:46cgrand,(for [n (range 10] (/ 1 n))
04:46clojurebotUnmatched delimiter: ]
04:46cgrand,(for [n (range 10)] (/ 1 n))
04:46clojurebotjava.lang.ArithmeticException: Divide by zero
04:46cgrand,(for [n (range 1 10)] (/ 1 n))
04:46clojurebot(1 1/2 1/3 1/4 1/5 1/6 1/7 1/8 1/9)
04:47tomoj(for [x aseq] (foo x)) is like [foo(x) for x in aseq], I think
04:47tomojthough I'm a python noob
04:47yasonApparently hinting argument types only ensures that they're java.lang.Number? Not specifically #^Integer, #^Double, etc?
04:47carpdiem@cgrand - thanks
04:48carpdiem@tomoj - that's actually really helpful, thanks for the translation
04:48tomojI dunno if python's list comprehensions can do cartesian products
04:48cgrandyason: hinting is not casting, an hint doesn't cause the compiler to add checks to ensure a avlue is of the specified type
04:49cgrands/avlue/value/
04:49carpdiem@tomoj - can you show me an example of a cartesian product with a clojure list?
04:50AWizzArdChousuke: yes, seems to work
04:50carpdiemsomething simple, even with just a few terms
04:50tomoj,(for [x (range 3) y (range 3)] [x y])
04:50clojurebot([0 0] [0 1] [0 2] [1 0] [1 1] [1 2] [2 0] [2 1] [2 2])
04:51yasoncgrand: I've understood that Clojure makes static, compile-time checks to ensure you don't, e.g. pass a string as some argument that's been hinted to be a number.
04:51carpdiem@tomoj - i see
04:51tomojit binds x to the first of the first seq, then runs through the elements of the second, moves on to the second of x, etc
04:51tomojthough you can do more
04:51tomoj,(for [x (range 2) y (range 2) z (range 2)] [x y z])
04:51clojurebot([0 0 0] [0 0 1] [0 1 0] [0 1 1] [1 0 0] [1 0 1] [1 1 0] [1 1 1])
04:51carpdiemyeah, i'm starting to "see" it now
04:52carpdiemyour python translation was super helpful
04:52tomojalso..
04:52tomoj,(for [[k v] {"foo" 3, "bar" 4, "baz" 5}] (str k v))
04:52clojurebot("foo3" "bar4" "baz5")
04:52tomojdestructuring :)
04:53yasoncgrand: (defn mult [#^Integer a #^Integer b] (* a b)) happily accepts floats, integers, bignums etc. (Or is #^Integer/TYPE the right form? Same with that, too.)
04:53carpdiem@tomoj - i think it'll take me another day or two before something like that reads comfortably to me
04:53tomojreading it does take a while I think
04:53tomojthe key is this
04:53tomoj,(seq {"foo" 3, "bar" 4, "baz" 5})
04:53clojurebot(["foo" 3] ["bar" 4] ["baz" 5])
04:54cgrandyason: when you hint something it helps the compiler in picking the right method calls when doing interop. When there's no interop hints change nothing to your code.
04:54tomojI think python can do something like that as well
04:54tomojhmm.. maybe not
04:55carpdiem@tomoj - ok, i'm a little confused at what just happened there
04:55carpdiemhow did clojure know to make three pairs, rather than, say, two triples?
04:55carpdiemit doesn't care about the commas, right?
04:56tomojright
04:56tomoj,(seq {"foo" 3 "bar" 4})
04:56clojurebot(["foo" 3] ["bar" 4])
04:56yasoncgrand: oh, I see, it's only useful when calling Java code. Right.
04:56tomoj"{}" means a map, maps map keys to values
04:57carpdiemok
04:57carpdiembut when i run (doc seq), it says "returns a seq on the collection..."
04:57carpdiemwhat is a 'seq' ?
04:57tomojwhen you use a map as a seq, you get a seq of key-value pairs
04:57carpdiemjust stripping out all the key-value pairs?
04:58tomojthere's a video you should probably watch
04:58cgrandyason: and once a specific method overlod is picked it's the JVM which enforces the type at runtime
04:58tomojwell, at http://clojure.blip.tv/
04:58tomojstart at the bottom of the playlist
04:59cgrandyason: mainly usefule calling java code but also when trying to use fast math or array ops
04:59carpdiemall right, i'll check that out
04:59carpdiemi've been going through the ociweb tutorial so far
04:59yasoncgrand: okay. So, any purely native clojure function always just takes plain Objects as arguments? That means that i.e. integer/float arguments are always boxed?
04:59cgrandyason: right now yes
05:00tomojseqs are clojure's big abstraction over all sequential data
05:00cgrandbut starting from JRE 6r14 you can ask the JVM to try optimizing boing/unboxing away
05:00AWizzArdoh really?
05:00AWizzArdHow would that work?
05:00tomojvectors, lists, maps, sets, strings, .. whatever else there is
05:01tomojyou can access them all as seqs
05:01carpdiemok
05:01tomojand there is a library of functions which operate on seqs so that you can use these functions with all of these kinds of objects
05:01tomojin (for [x foo] ...), the foo is a seq
05:01yasoncgrand: thanks, I'll go explore more
05:01carpdiemthanks, i'll go through those videos now, and come back if i have more questions :-)
05:01tomoj(well, it's either a seq or something that can be turned into a seq)
05:02carpdiemgotcha
05:02tomojI think those videos are not too out of date.. right?
05:05tomojcarpdiem: glad to have you join us :)
05:05carpdiemthanks
05:05carpdiemi'm enjoying clojure quite a bit so far
05:06carpdiemjust need to finish wrapping my brain around the new concepts
05:06tomojit's well worth it, I think
05:11tomojI think the only thing I remember being out of date about the seq video is rest/next
05:12tomojbut that's not terribly important, you can just read the docs on those functions as they are now
05:12carpdiemkk
05:29AWizzArdcgrand: do you know how one can ask the JVM to optimize boxing/unboxing away?
05:29somniumis there a way to do (for [x xs] (somefn (for [y ys] (otherfn y)))) with one for statement?
05:30cgrandAWizzArd: -XX:+DoEscapeAnalysis
05:34tomojsomnium: sure
05:34tomojwell
05:35tomoj(repeat (count xs) (somefn (for [y ys] (otherfn y))))
05:35tomojbut I guess that's not really what you meant
05:35AWizzArdgood, thx
05:36somniumwell, something like (for [x xs] (apply hash-map (for [[k v] ys] [k (f v)])))
05:36tomojhmm
05:36tomojthat still doesn't make sense to me
05:36tomojyou're not using x
05:37somnium(well pretend then function at the end is closing over x)
05:37tomojso like (for [x xs] (somefn (for [y ys] (otherfn x y)))) basically?
05:38somniumyeah that looks right
05:38somniumdoing (for [x xs :let [z (for [y ys] ... seems a little silly
05:38somnium;)
05:39cgrandAWizzArd: I think I read this flag should be on by default in a next release
05:39tomojof course you could make one of them a map to have only one 'for'
05:39tomojbut that's a cheap solution
05:39somniumyes, but for is so readable
05:40tomojone time at an interview they asked me to change some code I wrote with multiple print statements to use only one print statement
05:40tomojand I gave up, couldn't do it
05:40tomojthe answer was to have a mutable string and replace all but the last print statements with concatenations onto that mutable string
05:40tomoj:'(
05:41somniumis that a 'clojure has made my mind immutable' anecdote, or something else altogether ?
05:42tomojat that point I didn't know clojure, unfortunately
05:42tomojbut they asked me "can you write this with only one print statement"
05:42tomojsimilarly you asked "can you write this with only one 'for'"
05:42tomojand clearly you can by rewriting it in some other way which is essentially the same, like using map
05:43tomojwhich obviously wouldn't satisfy you, right?
05:43tomojstrange thing to me is that that was the answer they were actually looking for, a trivial rewrite that doesn't actually make any difference, but strictly satisfies the question
05:45somniumwell, in some cases map is equivalent
05:45somniumbut if there are some more lets or filters for is better
05:46tomojI still have never used those extra features of for
05:46somniumto my eyes they can make involved sequence transformation look so simple it seems like cheating
05:47tomojbut I mean we can clearly rewrite (for [x xs] (somefn (for [y ys] (otherfn x y)))) as (for [x xs] (somefn (map #(otherfn x %) ys)))
05:47tomojthat IS cheating :)
05:47tomojI mean, it's not a real answer to your question
05:47tomoj(btw, I don't have any real answers :()
05:47somnium(for [x xs :let [z (:mykey x)] :when (< z 100)] (for ...
05:48tomojessentially it seems like you're doing two nested maps, and I don't see how you could rewrite that as anything except two nested masp
05:48somniumyeah, I briefly wondered if a :for keyword could work, but it would at most save one keystroke from (for ... (for :)
05:49tomojI wonder if (for [... :let [x ..] :when x] x) is faster than (filter identity? (map .....))
05:49somniuminteresting question
05:50somnium~clojurebot
05:50clojurebotclojurebot is like life: you make trade-offs
05:50somnium~clojurebot
05:50clojurebotclojurebot is like life: you make trade-offs
05:50somniumhmm, I guess it picks responses at random
05:51AWizzArdcgrand: yes, that makes sense. I hope Sun will continue to improve this boxing/unboxing stuff, and maybe also add tagged numbers.
05:51somniumwow, the source for for is pretty hairy
05:52tomojseems to be about the same
05:52tomoj(filter identity (map even? (range 1000000))) and (for [x (range 1000000) :let [z (even? x)]] z) both take around 2s
05:54somniumtry macroexpanding for
05:57tomojheh, yeah
05:57tomojclojure's safeguards for macro hygiene don't help
05:57tomojI was thinking of writing a macro to wrap around macroexpand to give a semi-readable expansion
05:58somniumyeah, clojure.core could be dropped at least
05:59tomojwhen debugging your own macros I suppose it might be useful to see namespaces on some symbols
06:00tomojhm, actually
06:00somniumI haven't had the inspiration to try to write one remotely as complicated as for thus far
06:00tomojit seems swank-clojure already does this
06:00somniummacroexpand in place is a good way to destroy the readability of source files, I found
06:01tomoj(for [x xs] x) at the repl and C-c C-m with point at the beginning and you get a buffer with indented code and clojure.core removed
06:01tomojthough all the gensyms still make it pretty unreadable
06:01somniumhmm, C-m seems bound to return on my setup for some reason
06:01somniumwhat's the function name?
06:01tomojand the chunking
06:02tomojhmm
06:03somniumah I got it
06:03tomojC-c RET does it too
06:03somniumthat's more expansion that I was hoping for
06:03tomojslime-macroexpand-1
06:03tomojwell, that's only one macroexpand, supposedly
06:04tomojC-c M-m is slime-macroexpand-all for me
06:04somniumlooking at the source for for it seems about right
06:04tomojah yes
06:04tomojthen the gensyms might actually make some sense I suppose
06:05tomojclojure's gensym stuff really blew my mind when I first saw it
06:06somniumwhat (still) gets me is how comparatively easy it is to write a sane macro based on a function, compared to generating a new class in python or ruby
06:10somniumthe chunk-family doesn't seem to have doc strings
06:11tomojI guess they are relatively new?
06:12somniumonly docs I found were the assembla ticket, so I guess so
06:22adityohow will i use merge-with to merge maps {:a 1 :b 2} {:a 3 :c 4}
06:23hoeckadityo: like this, for example: (merge-with + {:a 1 :b 2} {:a 3 :c 4})
06:24adityoyeah, got it thanks hoeck :)
06:25hoeckadityo: np :)
06:53AWizzArd,(let [x (transient [1])] (into-array Byte/TYPE (map byte (persistent! x))))
06:53clojurebot#<byte[] [B@f3de46>
06:53AWizzArdbut why:
06:53AWizzArd,(let [x (transient [1])] (into-array Byte/TYPE (map byte (persistent! (conj x 2)))))
06:53clojurebotjava.lang.ClassCastException: clojure.lang.PersistentVector$TransientVector cannot be cast to clojure.lang.IPersistentCollection
06:54AWizzArdah okay, nevermind
07:00ambalek,(+ 1 2)
07:00clojurebot3
07:00ambalekclojurebot: <3
07:00clojurebot<3 is </3
07:00ambalekclojurebot: are you saying you don't love me back?
07:00clojurebotHuh?
07:00ambalekyou said </3 which kind of looks like a broken heart
07:10somniumclojurebot: </3
07:10clojurebotExcuse me?
07:18ambalekclojurebot: don't pretend you don't understand
07:18clojurebotNo entiendo
07:28aatifhI have a map like {:a nil :b 2 :c nil :d 4 :e 5} and i want to remove all the key/val whose value is nil. Anyone in just one liner elegant way?
07:30gerry`(filter (fn [[k v]] (not= v nil)) yourmap )
07:32tomoj,(into {} (filter val {:a nil :b 2 :c nil :d 4 :e 5}))
07:32clojurebot{:b 2, :d 4, :e 5}
07:33tomojthough that will remove pairs with false as a value..
07:34tomoj,(into {} (remove (comp nil? val) {:a nil :b 2 :c nil :d 4 :e 5 :f false}))
07:34clojurebot{:b 2, :d 4, :e 5, :f false}
07:35gerry`,(into {} (filter (fn [[k v]] (not= v nil)) {:a nil :b 2 :c nil :d 4 :e 5}))
07:35clojurebot{:b 2, :d 4, :e 5}
07:38tomoj,(into {} (filter (comp (complement nil?) val) {:a nil :b 2 :c nil :d 4 :e 5 :f false}))
07:38clojurebot{:b 2, :d 4, :e 5, :f false}
07:39tomojhehe
07:41djpowelli was just looking at sinatra, the web framework that influences compojure; but it seems hard to read without all the parens :)
07:42djpowella magic token stream
07:43_atodjpowell: huh... you're right
07:44_atothat's kind of scary
07:46_atoCompojure is lacking an awesome logo though :p
07:46ol3hello, i installed clojure-mode and swank-clojure
07:47ol3what should i do now if I want to start normal cl slime?
07:49tomojol3: https://gist.github.com/b06ace1e874298251401
07:49tomojthat works for me
07:49tomojM-x slime-clojure or M-x swank-clojure-project to start up a slime repl
07:49tomojM-x slime starts a cl slime
07:49tomojor C-u M-x slime to pick which slime you want
07:50tomoj_ato: http://preview.compojure.org/
07:50tomojmaybe it's not awesome, I dunno
07:53ol3tomoj: thanks, that what i was looking for
08:08_atotomoj: very nice!
08:08_atoI hadn't seen that
08:08tomojit's hidden away for some reason
08:08clojurebotfor is not a loop
08:09tomojI don't really understand the logo
08:09tomojis it a martini with a blue olive?
08:11_atoyeah looks like a green martini with a blue olive to me
08:11tomojmaybe if we are classy enough to be drinking martinis, we have good composure?
08:13_atoI think it's a reference to Frank Sinatra
08:15tomojaha
08:16tomojso a hidden nod to the sinatra framework as well?
08:16_atoyeah, that's my guess anyway
08:24tomojI have yet to use compojure for anything other than tiny experiments
08:25tomojit's hard!
08:25tomojcompojure (and I guess sinatra as well? never used it) make you actually make decisions
08:25tomojinstead of having them all already made for you by a danish dude
08:39solussdwill 'memoize' work correctly with a function that alters refs?
08:40solussdIt seems like it should not, since the input would be just the ref, not the ref's value
08:41chousersolussd: changing a ref is a kind of side-effect
10:33djorkit's correct to name .clj files with_underscores.clj
10:33djorkright?
10:34chouseryes
10:34djorknamespace/with_underscores.clj becomes (ns namespace.with-underscores)
10:34chouseryes
10:34djorkk
10:34djorkthanks
10:34chouserunfortunately. :-)
10:34lisppaste8cemerick pasted "rhickey: NoSuchFieldError on keyword lookup (regression?)" at http://paste.lisp.org/display/89834
10:35cemerickhrm, that doesn't happen with deftype, tho.
10:35AWizzArdIs there an easier for doing this:
10:35AWizzArd,(apply hash-map (apply concat (pmap #(vector %1 %2) [:a :b :c] [1 2 3])))
10:35clojurebot{:a 1, :c 3, :b 2}
10:35chouserAWizzArd: you want pmap?
10:36AWizzArdyes, no mapcat please
10:36chouser,(into {} (pmap #(vector %1 %2) [:a :b :c] [1 2 3]))
10:36clojurebot{:a 1, :b 2, :c 3}
10:36AWizzArdgood!
10:36chouser,(zipmap [:a :b :c] [1 2 3])
10:36clojurebot{:c 3, :b 2, :a 1}
10:37chouserBut no pzipmap or zippmap, I'm afraid.
10:37chouserso you're still churning out vectors.
10:37AWizzArdwell, my %2 will be (.foo %2)
10:37Anniepooanybody know how to get enclojure to start it's repl with a special java cmd line?
10:38AWizzArdso, the pmap is actually doing something
10:41notallama(zipmap [:a :b :c] (pmap foo [1 2 3])) ?
10:41chouserpmap doesn't appear to use chunked seqs yet.
10:41chousernotallama: yes, good!
10:41chouserrhickey: do you want a chunked pmap?
10:42AWizzArdgood idea notallama
10:43AWizzArdchouser: what is a chunked pmap?
10:47chouserAWizzArd: if the input seq were chunked, each step would do a whole chunk instead of a single item.
10:51chouserthis would reduce the thread-interaction overhead per item and reduce the threshold for the amount of work needed to be done on each item for pmap to be worthwhile.
10:59AWizzArdchouser: and what are the differences between a single item vs. chunk?
11:05AWizzArdgit question: when I want to freshly clone the NEW branch of Clojure, how would I do that?
11:09rhickeychouser: chunked pmap is tricky, I've tried it a couple of times without being completely happy. The fundamental problem is you can't presume a uniformity of (chunked-.non) seq type across the iteration
11:09rhickeycemerick: you get that with a clean build all around?
11:10cemerickrhickey: yes, top to bottom, although I've now discovered that it only happens with two of the ~15 defclasses we have.
11:11rhickeymethod called bounds?
11:12rhickeyand ant clean, not just rebuild?
11:12cemerickwell, it has a field *and* a method called bounds
11:12rhickeycemerick: that was my quesiton
11:12cemerickrhickey: yes, cleaned all the way down the clojure, and back up
11:12rhickeyis that true for other fields that work?
11:12rhickeyfield + method?
11:13cemerickyes, on the same defclass, there's a field + method called derived that works fine
11:13cemerickoh, I'm seeing a pattern, one sec
11:19AWizzArdWhat is the "git clone" command to download Clojures "new" branch instead of master?
11:19lisppaste8cemerick annotated #89834 "untitled" at http://paste.lisp.org/display/89834#1
11:19cemerickrhickey: ^^
11:19The-KennyAWizzArd: After the git clone, do "git checkout new".
11:19drewrAWizzArd: git checkout -b new origin/new
11:20The-KennyOh sorry, origin/new. My bad.
11:20savanniHey, guys, I actually have a question today...
11:22savanniWhen I try loading clojure.contrib.test-is, I get back an error saying that clojure/test__init.class and clojure/test.clj cannot be found. Any idea why this would happen when I have access to other parts of clojure.contrib?
11:26drewrsavanni: test-is was promoted from contrib to core a couple months ago
11:26drewryou may have conflicting versions of both
11:26savanniOh. Well that makes sense.
11:27rhickeycemerick: fixed
11:28rhickeycemerick: note this is still not full non-primitive-hinted-field support
11:28cemerickrhickey: meaning?
11:29rhickeymeaning the hint is ok, but does nothing, and doesn't fail when accessed via :field
11:29cemerickoh, ok
11:29rhickeyas you noted yesterday, it's not creating a String field yet
11:29cemerickso usages in method impl bodies will need hinting
11:29rhickeybut the lookup thunk looked for one
11:30cemerickah, I was only referring to the type on the ctor
11:30savanniDid test-is get move into clojure.core for clojure-1.0.0?
11:31rhickeycemerick: I'll have to survey how extensive a change it is to support non-primitive-local hints, it is my intention to support, but in protocol-land right now
11:40replaca_savanni: nope, it's post-1.0.0
11:41savanniThanks. I'll need to get clojure from git, then.
11:42replaca_savanni: or you can get the 1.0 compatible contrib
11:43savanniThat, too. I'm more inclined to get the latest versions, though.
11:43replaca_(but I just stay at HEAD and everything seems fine)
11:43savanniIf I'm getting development versions, I'll just expect things to break occasionally. :)
11:44chousersavanni: you may be disappointed
11:45savanniYou mean it rarely breaks? That would be awesome.
11:45noididoes anyone have any idea how to install swank-clojure at the moment?
11:46savanni(my statement sounds really mean, and I didn't expect it to...)
11:46noidiI tried following these instructions http://github.com/jochu/swank-clojure, but when I run M-x slime, I get "Symbol's value as variable is void: package-activated-list"
11:47chousersavanni: oh, no, it's not mean to expect a development branch to break occasionally. But in practice it's pretty rare.
11:47chouserand usually cgrand's fault.
11:48chouser:-) see, now *that* was mean.
11:48chousercgrand: just kidding!
11:48noidiI guess I'll try the package management thing, maybe installing clojure-mode from git doesn't work anymore
11:48rhickeyouch!
11:48fogus_zing
11:49cemerickrhickey: That fix is confirmed. I'm hitting a couple of other related issues, as well. Do you want msgs on the list, tickets in assembla, or should I lay them on you here?
11:49rhickeycemerick: start here
11:50stuartsierranoidi: swank-clojure is in flux at the moment, preparing for a release; try the new mailing list http://groups.google.com/group/swank-clojure/browse_frm/thread/20141a1e19c60339
11:50lisppaste8cemerick annotated #89834 "untitled" at http://paste.lisp.org/display/89834#2
11:50cemerickrhickey: ^^
11:51chousercgrand: I think I've broken things about as often, and while attempting changes far less useful or significant than transient maps.
11:52noidistuartsierra, cool, thanks!
11:52stuartsierranoidi: no problem
11:52noidiI guess it's a good thing that &/¤%"#¤ github ate my detailed bug report, then :P
11:54cgrandchouser: well it's usually what I reply when one ask me how stable the dev branch is. "pretty stable unless one of my patches got applied"
11:55chouserheh
11:58stuartsierraAnyone want multi-maps in contrib?
11:59lisppaste8cemerick annotated #89834 "rhickey: issue #3" at http://paste.lisp.org/display/89834#3
11:59cemerickThat's all I have now -- thankfully, I was able to distill good examples. :-)
12:00AWizzArddrewr: thanks
12:06cgrandabout messing with core data structures: stack ops on persistent vectors can be made faster by having the last item or the two last items (depending on the vector parity) stored in fields. Thus the tail array is allocated only once every two conj (or pop) and peek is direct (no array lookup).
12:09rhickeycemerick: first fixed, second a limitation for now (use java-compatible field names)
12:10rhickeycgrand: sounds interesting, what about the cost for ordinary lookup? - definitely adds logic there
12:11rhickeyand complexity to seq et al
12:12lisppaste8stuartsierra pasted "Multimaps" at http://paste.lisp.org/display/89840
12:13cgrandrhickey: haven't benchmarked the idea on the actual persistent vector but on a simplest prototype. The lookup cost wasn't noticeable (the indirection cost through nodes and arrays dominates I guess)
12:17cgrandseq support: getArrayFor(i) must return a synthetic array when i is the last or the penult (when even)
12:18cgrandtransient ops would have added complexity
12:22rhickeycgrand: I don;t think I'd want to take on the complexity right now, but an interesting idea
12:22rhickeyanother idea I had was to have different types for the different depths, then there would be no recursion, straight-through lookup code per depth
12:24savanniWhat is a good wai to debug a NullPointerException, when I know which function it is happening in but not which variable or line is null?
12:26cemerickrhickey: confirmed that fix. Thank you very much. :-)
12:26rhickeycemerick: sure - keep em coming, that one was just an undone todo
12:27rhickeycemerick: I'm really glad you are able to try it out - you'd be amazed at how different things are under the hood :)
12:28rhickeye.g. completely changing the compilation of fns, (:foo x) etc
12:28djorkoops, I just wrote clojure in my objc code
12:28djork(== 0 section)
12:29cemerickrhickey: it's been wonderfully smooth overall. Q: given that non-primitive hints are ignored right now, are host invocations in method bodies reflective? I'm not getting reflection warnings, but I can't imagine how methods are being invoked on Object fields otherwise.
12:31rhickeycemerick: the hints propagate through as hints, just not as storage types, so, stored as Object, resolved as direct calls due to hinting, no reflection, just checkcast
12:31cemerickah, OK
12:31cemerickI'm really starting to like the idea of a defstatic or similar for factories.
12:31rhickeyleave out hint you should get reflection warning
12:32rhickeycemerick: yes, interfaces + defstatic is near ideal external interface IMO
12:32rhickeyas much as this isn't a full interop facility, it really lends to nice, clean designs
12:33rhickeyand protocols will totally rock
12:33rhickeyas soon as I can figure out MI :(
12:35cemerickrhickey: I had to deal with this yesterday, which was fun. Amazing what can be done in "typical Java" APIs. http://lucene.apache.org/java/2_9_0/api/core/org/apache/lucene/index/IndexWriter.html#constructor_summary
12:36rhickeywow
12:36cemerickhalf of them are deprecated, but nevertheless....
12:38technomancylucene even seemed relatively tame for a Java API to me
12:39technomancyafter working with Hadoop... =\
12:39cemerickuh, yeah, hadoop is pretty mammoth in terms of API surface area
12:40cemerickwe've long since stopped using it. Nice concept, but way too much *stuff* to deal with for us.
12:40stuartsierraThat's why I wrote clojure-hadoop :)
12:40patrkrisdoes anyone here have experience with using webjure? I just want to hear some opinions on it as a web programming framework? are there any better alternatives?
12:41cemerickjust the sysadmin junk associated with it was enough to cause us to look away.
12:41cemerickwe're liking simple JMS with couch for data endpoints at the moment
12:41stuartsierrawith ec2 & the cloudera scripts it's not too bad
12:42patrkrisforget my question - i really should learn to use google
12:52jasappI'm having a bit of trouble with clojure.xml/parse
12:53jasappI think this is valid xml
12:53jasapp<foo>\"bar</foo>
12:53jasappbut I get an exception when I try to parse it
12:54jasapp,(clojure.xml/parse "<foo>bar\"</foo>")
12:54clojurebotjava.net.MalformedURLException: no protocol: <foo>bar"</foo>
12:55chouserjasapp: parse wants a sax InputSource, not a string.
12:55clojurebota is b
12:55jasappoh, sorry
12:55jasappI feel silly now, I thought it took strings
12:56The-Kenny,(doc clojure.xml/parse)
12:56clojurebot"([s] [s startparse]); Parses and loads the source s, which can be a File, InputStream or String naming a URI. Returns a tree of the xml/element struct-map, which has the keys :tag, :attrs, and :content. and accessor fns tag, attrs, and content. Other parsers can be supplied by passing startparse, a fn taking a source and a ContentHandler and returning a parser"
13:01jasappahh, much better
13:25javuchihello
13:25JorejiHey guys, how can I keep on calling a function over and over (in a while loop) without freezing the clojure repl?
13:25JorejiIs there some agent/thread magick that can achieve that?
13:26javuchiis there going to be a stand-alone clojure ever (with no dependences for the jvm)?
13:28patrkris Joreji: you can send an action to an agent which itself sends an action to the same agent, whenever it wants to continue "the loop"
13:30AWizzArdThis works fine for me:
13:30AWizzArd,(let [a (agent 15), p (promise)] (send a #(do (deliver p (+ % 5)) :ok)) @p)
13:30clojurebot20
13:30AWizzArdBut, when I make (+ % 5) to (+ % "5") then it hangs
13:31Jorejipatrkris: If I do (while 1 (send my-agent (update))) wouldn't that fill the queue of the agent pretty fast?
13:31AWizzArdCan deliver maybe made so that when an exception occurs that it will throw it, instead of hanging?
13:34patrkrisJoreji: just a sec, i'll give you an example
13:36chouserjavuchi: what would you use it for with no libraries? Clojure depends on a host (JVM, CLR, etc.) for all IO, user interaction, etc.
13:38javuchichouser: because the jvm consumes too much memory
13:38wwood4
13:39cemerickjavuchi: so you want to target C or something?
13:39patrkrisJoreji: http://pastebin.com/m70303ad7
13:39patrkrisJoreji: just a very simple example
13:40patrkrisJoreji: you don't need a while there, because every time the action is called, it will dispatch itself to the agent again and keep it going
13:41patrkrisJoreji: and the agent queue wont fill because every time the action is executed, it is taken off the queue
13:42Jorejipatrkris: Ah, thanks alot!
13:42patrkrisJoreji: and the Thread/sleep is just there to pretend that we're doing some work that takes a little time
13:44abedrashould send-off ever block?
13:46abedrabasically i want to send an agent off every n seconds
13:46abedrahttp://gist.github.com/227280
13:46abedrai started here
13:46abedrabut it blocks
13:46patrkrisabedra: note that the action is not sent before the current action is done executing
13:46drewrabedra: you probably want *agent* on line 2
13:50abedrapatkris: so I should create *agent* ahead of time?
13:50abedraand use that for both?
13:51patrkrisabedra: *agent* refers to the agent currently executing
13:51patrkrisabedra: it's a special variable in clojure
13:52chouserjavuchi: once we have clojure-in-clojure, ports to other host languages/platforms will be quite a bit easier. Perhaps someone will target ObjectiveC/iPhone or chickenscheme
13:53Jorejipatrkris: http://pastebin.com/d5bf739ca
13:53Jorejipatrkris: For some reason I'm getting a stack overflow.
13:53Jorejipatrkris: Anything obvious which I've done wrong?
13:54fradiavalois it good clojure style to have code like this? (reduce + (take 100 (repeat 5)))
13:54chouserfradiavalo: it's probably better just to say (* 100 5)
13:54chouser:-)
13:55chouserfradiavalo: but other than that, there's nothing wrong with your expression. What about it makes you ask?
13:56fradiavalochouser: Thanks, just wondering. I am learning clojure, so quite unsure about the correct idioms.
13:56patrkrisJoreji: i'm not exactly sure
13:57chouserfradiavalo: a seq-producer (like repeat) fed through a chain of filters or processors (like take, filter, remove, map, etc.) is quite common, as is collecting up that seq with a 'reduce'.
13:57Jorejipatrkris: I also get the stack overflow if I remove the (QApplication/processEvent) call.
13:57chouserthere's even a macro to let you write it in what may be a more comfortable order.
13:58chouser,(->> 5 repeat (take 100) (reduce +))
13:58clojurebot500
13:58patrkrisJoreji: do you get the stackoverflow right away?
13:58fradiavalochouser: I like the ordering without the macro better :)
13:59fradiavaloGuess I like to read right to left
13:59Jorejipatrkris: No. After like 3-5 seconds.
13:59chouserfradiavalo: fair enough
14:00fradiavaloI know a little bit of q (http://en.wikipedia.org/wiki/Q_(programming_language_from_Kx_Systems) so the right to left style seems more natural
14:00notallamafradiavalo: with the -> and ->> macros, i often put each form on its own line, so you'd read it top to bottom.
14:01patrkrisJoreji: hmm... maybe it's because QApplication/processEvents doesn't take much time, and the agents effectively does a lot of sends really fast... but I'm not sure.
14:01patrkrissomeone else may be able to answer this
14:01stuartsierraJoreji: does QApplication/processEvents block?
14:01fradiavalonotallama: Thats a good idea to help readability
14:02Jorejistuartsierra: I've removed the QApplication/processEvents. So, no.
14:02stuartsierrathen you might be overflowing the agent's event queue
14:02JorejiAh.
14:03patrkrismy thought
14:03patrkrisexactly
14:03JorejiIndeed. It works if I add a (Thread/sleep 500)
14:03JorejiThanks guys!
14:05stuartsierraJoreji: looking at the definition of QApplication/processEvents, you probably don't want to call it in a busy-loop like that.
14:05abedrapatkris: thanks, that got me further, however I want to make the agent keep firing the function
14:05abedrapatkris: and i get an agent error after the first couple of firings
14:06stuartsierraClojure agents do not directly support calling an action periodically, you need Java timers or something.
14:06Jorejistuartsierra: Why is that?
14:06patrkrisabedra: what is the error?
14:06Jorejistuartsierra: Hm ok.
14:06JorejiExplains why this is not working.
14:07stuartsierraJoreji: the docs say you can call processEvents "periodically", but you're calling it incessantly, like a while(1) loop.
14:07technomancyis there a reason you can only kill all agents at once rather than killing individual ones?
14:07hiredmanhttp://gist.github.com/178350 <- schedule
14:07abedrathanks
14:08abedrapatkris: i just get Agent has errors
14:08Jorejistuartsierra: Makes sense. Guess I'll have to take a look at some java timers.
14:08abedrabut I think the scheduler would help that out
14:09patrkrisabedra: use (agent-errors my-agent) to see the errors
14:09patrkris,(doc agent-errors)
14:09clojurebot"([a]); Returns a sequence of the exceptions thrown during asynchronous actions of the agent."
14:09stuartsierratechnomancy: maybe because the JVM discourages you from killing individual threads?
14:09hiredmanthe binding of agent to thread is very loose
14:09hiredmanan agent's action just runs on whatever thread the threadpool hands it off to
14:11hiredmanif you want to be able to cancel async actions you might look at future
14:12technomancystuartsierra: didn't realize that... (.stop (Thread. foo)) is not kosher?
14:12stuartsierratechnomancy: The JDK docs say don't do it, I think b/c it can leave locks/monitors inconsistent.
14:13chouserand skip 'finally' clauses
14:13abedrapatkris: IllegalArgumentException: Key must be integer is what gets returned there
14:14technomancyinteresting
14:14patrkrisabedra: well I guess you're calling something inside your action that expects an integer argument :)
14:14Chousukethe proper way to "stop" a thread is to have it poll for the .interrupted flag
14:15abedrapatkris: the funny thing is that it runs twice before that happens :)
14:15Chousukealso if you call .interrupt on a thread while it's waiting, an exception will be raised within it.
14:15patrkrisabedra: can you give me a pastbin of your new code?
14:19abedrapatkris: http://pastebin.com/m4785c831
14:19abedrapatkris: that's in the middle of trying a few things out
14:20AWizzArdrhickey: it seems that promises can block forever when an agent tries to deliver them with something that throws an exception. For example, paste this into your repl: (let [a (agent 15), p (promise)] (send a #(do (deliver p (+ % "5")) :ok)) @p)
14:21patrkrisabedra: ok, first of all, the actions that you send to agents must always take the agent's state as the first argument, so you should probably just have (send-off a api-key-agent) in line 8
14:22patrkrisabedra: and in line 4, you are asking for the agent's errors, but that will fail because a is bound to the agent's state at that point, *not* the agent itself
14:22javuchiwhy CL's guys still advocates against clojure?
14:23djorkbecause they are smug Lisp weenies
14:23djorkand they are no fun
14:23stuartsierrajavuchi: because it doesn't have a 50-year-old spec
14:23djorkand nobody likes to hang out with them
14:23patrkrisabedra: and why don't you just call retrieve-api-keys directly?
14:24javuchii found this:
14:24javuchihttp://www.3ofcoins.net/2009/01/30/common-lisp-clojure-and-seriousness/
14:24drewrhow do you get *ns* bound to the namespace of the fn's var?
14:24rhickeyAWizzArd: the exception happens before the transfer of control to deliver. What you are basically saying is, code that throws an exception before it calls deliver doesn't end up calling deliver, which, while correct, is just a program bug, not something promise/deliver can do anything about
14:24javuchiall what he says is that clojure is a toy because it is hosted
14:25javuchino other technical reasons
14:25djork" a serious language to a toy language."
14:25djorkwhat a dick
14:25abedrapatkris: That's what I would like to do...
14:25drewriow, (in-ns 'foo.bar) (defn baz [x y] *ns*)
14:25stuartsierraThe CL guys don't like Clojure because they see it as a concession to the market dominance of Java.
14:25djorkthe toy language is the one where I can download a jar and fire up a Repl and slap a window on the screen with the stuff already in my OS?
14:25abedrapatkris: basically I need to have something keep calling (retrieve-api-keys) in the background while the process is running
14:26patrkrisabedra: and you want to do something with the retrieved value, i guess?
14:26djorkthe toy language is the one where an infinite lazy seq of prime numbers is a one-liner
14:26abedrapatkris: no, (retrieve-api-keys) just updates an atom
14:26djork(my favorite clojure example ever, by the way)
14:26noidi"after a nuclear catastrophe, archæologists of future generations should be able to re-implement the language on any hardware, including the Calculor;"
14:26noidi:D
14:26AWizzArdrhickey: ok I understand
14:26noidiyes, all languages should be designed for the post-apocalyptic use case
14:27javuchihehe
14:27djorkPerl and Tcl are toys too? I guess his definition of a toy language is "one that is used to do vast amounts of real work."
14:27stuartsierraI like this comment: http://www.3ofcoins.net/2009/01/30/common-lisp-clojure-and-seriousness/#comment-31
14:27javuchii don't see the point in going against the JVM right now that it is GPL
14:28djorkHere's the deal: the JVM is specced out, and Clojure is open source. Done. It's just as apocalypse-proof as CL.
14:28javuchidjork: I've never seen a serius project in CL, do you know of one?
14:28djorknope
14:28javuchiin 20 years of existence?
14:28djorkit's just so much work to use CL
14:28djorkthere's no time left to build your project
14:29stuartsierrajavuchi: AllegroGraph (huge triple store) was originally written in CL, then ported to Java :)
14:29javuchiwhat's going to happen to CL today, when multi-threading applications are going to be a must?
14:29djorkI feel like clojure/core is not going anywhere... is that right rhickey? It's small and concise enough.
14:30patrkrisabedra: do you want the agent itself to hold any particular state, or do you just want it to repeatedly call (retreive-api-keys) with certain intervals?
14:30stuartsierradjork: if you think clojure.core is not going anywhere, you haven't been paying attention :)
14:30abedrapatkris: i just want to repeatedly call it
14:30djorkI guess not :)
14:30stuartsierradjork: reify, deftype, transients...
14:31djorkI don't mean in terms of new features
14:31djorkI mean things aren't going away right?
14:31stuartsierradjork: there will probably not be major changes to the existing core functions any time soon
14:32djork"At this point in Lisp’s history a standard was still 25 years in the future."
14:32patrkrisabedra: how about something like this: http://pastebin.com/d1eef4361
14:32djork(the age Clojure is now)
14:33javuchiok, the question now is: is somebody doing any important project based on clojure?
14:34drewr,(in-ns 'foo) (defn bar [] *ns*) (in-ns 'baz) (require 'foo) (foo/bar)
14:34clojurebot#<Namespace foo>
14:34javuchiany significant application?
14:34abedrapatkris: exactly like that, thanks so much!
14:34fogus_"Important" is a loaded term, but FlightCaster uses Clojure
14:34drewr,(ns 'foo) (defn bar [] *ns*) (in-ns 'baz) (require 'foo) (foo/bar)
14:34clojurebotjava.lang.ClassCastException: clojure.lang.PersistentList cannot be cast to clojure.lang.Symbol
14:34patrkrisabedra: if you need to update the state of the agent, the last expression in its action should yields its new state.... i haven't taken that into account
14:34drewr,(ns foo) (defn bar [] *ns*) (in-ns 'baz) (require 'foo) (foo/bar)
14:34clojurebotnil
14:34patrkrisabedra: no problem :)
14:34drewrthat nil seems wrong to me
14:40mikehogyewhere is the best place to ask questions about Lancet?
14:47weissjmikehogye: here probably :) i've worked with it some - it's not quite complete, i've made a few fixes that i don't think anyone ever accepted :)
14:48mikehogyeweissj: in the runonce method, it seems like access to the "result" atom is not properly synced
14:48mikehogyeweissj: http://github.com/stuarthalloway/lancet/blob/master/lancet.clj , lines 68 and following
14:49chouserdrewr: switching namespaces within a single top-level form is perilous. You'll get different results if you run each of those in the repl.
14:49mikehogyeweissj: ThreadA could execute line 83, find that @result != sentinel
14:50mikehogyeweissj: then ThreadB calls reset-fn
14:50mikehogyeweissj: then ThreadA derefs result
14:52mikehogyeweissj: causing line 85 (and ThreadA's call to runonce) to evaluate to sentinel
14:52weissjmikehogye: to be honest i don't have idea idea what runonce is even for. i just require lancet as ant, and start calling things like ant/unzip, ant/move, etc
14:52drewrchouser: for a var that points to a fn, say foo.bar/baz, is there any way within baz to refer to find foo.bar?
14:53mikehogyeweissj: actually, the other question I wanted to ask about Lancet is: is it usable?
14:53drewrI'm not switching namespaces in my real code
14:53weissjmikehogye: all i wanted was clojure bindings into ant, which i get without doing anything special
14:54mikehogyeah
14:54mikehogyeweissj: ah, I'm with you
14:54drewrchouser: s/to find/to/
14:55weissjmikehogye: it's usable for me, but i did have to add a few multimethods like the ones that are already there, for example for exec's arg tag, and echo's level tag
14:55chouserdrewr: not sure exactly what you're trying to do. Would this work? (defn baz [] (.ns #'baz))
14:55mikehogyeweissj: any idea whether anyone else is actively working on it?
14:56chouserdrewr: or: (def baz (let [ns *ns*] (fn baz [] ns)))
14:56weissjmikehogye: i emailed stuart my additions and never heard anything, and i see the current git copy still doesn't have them. so i'd say no
14:56mikehogyeweissj: bleh
14:56mikehogyeweissj: thanks
14:56weissji think he used it as an example from his book and never expected anyone to really use it
14:56mikehogyeweissj: that's a shame
14:56technomancypretty sure lancet is intended just as an instructional project, not to be used for anything serious.
14:56technomancyat least, not as a tool in itself.
14:56weissjtechnomancy: yeah, which is unfortunate because it's really useful
14:57mikehogyeit's such a good idea, though (or, it seems like a good idea to me)
14:57weissjand it's almost complete
14:57weissjthen again, if its used as an example in a book, how hard can it be to finish
14:57weissji haven't finished it because i'm a noob and i haven't had time
14:57technomancyhowever there *is* an in-process project at http://github.com/technomancy/leiningen that may be more like what you're looking for
14:57technomancybut you didn't hear that from me.
14:57weissjbut mikehogye you can have my changes if you want em :)
14:58notallamaif ::foo is a child of ::bar, will multimethods always prefer ::foo? or do i have to tell it to prefer ::foo?
14:58mikehogyeweissj: I assume you're the weissjeffm on github?
14:58drewrchouser: ah, thanks; ns() is what I needed
14:59weissjmikehogye: yep
14:59drewrit'd be nice to do it without the #'baz, but at least it occurs near the scope
14:59mikehogyetechnomancy: is leiningen specifically for building Clojure codebases?
14:59drewrI'm trying to convert "foo" to the value that #'foo points to dynamically
15:00technomancymikehogye: maaaaaaybe. (actually, yes.)
15:00djorksomeone asked about important projects in Clojure
15:00djorkflightcaster.com
15:01djorkbuilt a Clojure layer on top of Hadoop and Cascading
15:01mikehogyetechnomancy: okay -- I will look at leiningen, but what I'm really dying for is Ant without the suckage
15:01mikehogyetechnomancy: which is to say, Lancet
15:01djorkthey do massive distributed computations in Clojure
15:01djorkit is pretty much their backbone
15:02djorkhttp://www.infoq.com/articles/flightcaster-clojure-rails
15:02technomancymikehogye: lancet doesn't even ship with a bin script; it's definitely not meant to be used like ant.
15:04javuchidoes clojure works on mobile devices supporting java?
15:04javuchifor example, on my nokia 6210 mobile?
15:04stuartsierrajavuchi: it's reported to work on Android
15:05hiredmanjavuchi: most "java" phones are j2me which is garbage :(
15:05mikehogyetechnomancy: it seems like a basic wrapper script would be fairly easy (although I've given it a grand total of about 30 seconds of thought)
15:05chouserIt's been a long time since I've heard anyone talk about clojure on j2me -- I don't remember if people got it working or not.
15:05javuchihiredman: so it doesn't work?
15:05hiredmanchouser: it would be really hard
15:05hiredmanI think j2me is mostly java 1.4
15:06hiredmanI forget, but I don't think it even has Collections
15:06chouseroh. ouch.
15:06ordnungswidrighi
15:06hiredmanyeah
15:06djorkoh well... j2me devices feel slow with pure Java in the first place
15:06djorkI'd hate to see Clojure
15:07hiredmanI think that depends on the phone
15:08hiredmanI did a game of life for my blackberry and it ran fine :P
15:08ordnungswidrigjava on my sony ericsson w800i was surpringsingly fast
15:08Chousukehm
15:09ChousukeI wonder how to make ant print out the entire stacktrace
15:09ordnungswidrigant?
15:09hiredmanI think palm pre might be the only phone with real java
15:09ordnungswidrigant -d?
15:09ChousukeI'm trying to run contrib tests with my reader and it fails and it's hiding 80 items from me and not even -v shows them
15:09hiredmanchouser: doesn't it usually do that at the end?
15:09ChousukeI get a string out of bounds exception somewhere.
15:10hiredmanI would also get an abbreviated exception inline with the test run, and then a dump of all the stacktraces at the end of the ant run
15:11djorkI'm happy with Clojure on the desktop right now, since it's all about the Repl anyway.
15:11clojurebota is b
15:12rhickeywoah - http://code.google.com/closure/
15:12djorkwut
15:12djorkyou know what... the word "closure" looks funny now :)
15:12hiredmanrhickey: yeah
15:13chouser,(swap! (atom [] :validator #(or (empty? %) (number? (peek %)))) conj :oops)
15:13clojurebotjava.lang.IllegalStateException: Invalid reference state
15:14mikehogyetechnomancy: do you know of reasons that bin scripts for Lancet (or a descendent thereof) would be difficult to write?
15:15technomancymikehogye: no, and that's essentially what leiningen is, plus dependency management and some built-in clojure-specific tasks. it's not hard at all.
15:15mikehogyetechnomancy: cool. I will definitely take a look.
15:16chouser"it compiles from JavaScript to better JavaScript" hmph.
15:16Chousukehmh
15:17Chousukethe ant page says to use fork="true" but that's already set...
15:17technomancymikehogye: once I get the jar task done I will polish it a bit to make it easier to install and make an announcement, but you're welcome to give it a go now.
15:20rhickeychouser: hmph? that sounds awesome to me, like hotspot for js, makes it easier for us
15:22javuchihow much memory consumes an agent?
15:22chouserI'm actually quite ambivalent about compiling to JavaScript.
15:22hiredmanchouser: really? I thought most of the java tasks in build.xml did not have fork="true"
15:23hiredmaner
15:23hiredmanChousuke:
15:23chouser:-)
15:23rhickeyjavascript is the new bytecode
15:23clojurebotnew Class(x) is (Class. x)
15:23fogus_chouser: I've spent a lot of time in GWT, so I have similar conflicting feelings.
15:24rhickeyunlike gwt, this seems to be the stuff they actually use
15:24chouserrhickey: I'll buy js is bytecode when I see debuggers that tie you back to the original source.
15:25rhickeygood point
15:25hiredmanhmmm
15:25chouserthe wave team apparently uses and loves gwt
15:25rhickeychouser: yeah, the customized new version they had made for them addressing all shortcomings of the stuff everyone else was using
15:26chouserjavuchi: agent uses very little memory -- it's not a whole thread or anything
15:26chouserrhickey: oh. :-(
15:27javuchiis it lightweighter tha erlang processes?
15:27javuchithay consume about 230 bytes
15:27chouseroh, I missed that Closure is from google.
15:28fogus_GWT has it's nice points, when viewed through the right lens
15:28chouserhm, the Closure inspector sounds interesting -- that might be the missing piece for debugging. We'll just need one for clojurescript
15:29chouserfogus_: I can see some of the benefits, but in general I'd rather write javascript than java. :-P
15:31fogus_chouser: I agree with you. There is a huge impedance mismatch using GWT and that's tough to swallow.
15:32javuchichouser: how can i know the size of an agent?
15:32G0SUBa lot of people complain about the debugging facilities of Clojure + SLIME being not so awesome. what is needed to fix the situation?
15:32hiredmanmore printlns
15:32javuchiG0SUB: i find it nice in the last versions
15:33frooghttp://georgejahad.com/clojure/cljdb.html
15:33G0SUBhiredman: better sldb integration will be great :)
15:33hiredmanG0SUB: *shrug*
15:35chouserjavuchi: http://www.javaworld.com/javaworld/javaqa/2003-12/02-qa-1226-sizeof.html :-P
15:35G0SUBrhickey: where can we get the video of your awesome talk about time at the jvm lang summit?
15:37javuchichouser: so basically i need to create a million agents and measure memory consumption?
15:37fogus_Hrmmm. Reading about Google-Closure is making bitter.
15:38chouseragent is _meta + validator + watches + state + q + errors
15:38djorkyou mean (+ _meta validator watches state q errors) :)
15:39chousereach of those one a 32-bit JVM is probably 4 bytes, plus 8 for Object, I'd guess 32 bytes per agent
15:39chouserdjork: er, right. of course.
15:39RomanRoeis anybody able to use build.clojure.org as mvn repo? It stopped working for me :-/
15:40djorkmy count is 88 bytes on my JVM
15:40chouseron a 64-bit JVM it's probably closer to 64 bytes.
15:40javuchiso it is expected to use 64 bytes on a 64bit machine
15:40djorkOS X Snow Leopard
15:40chouserdjork: counted how?
15:40javuchi88 bytes?
15:40javuchithats much less than 230 bytes for process in erlang
15:40djork(- (mime (agent nil)) (mime nil))
15:41djorkerr that doesn't really work right now
15:41djorkit's my new toy memory measuring macro
15:41chouserah
15:42djorkbut (mime nil) takes 24 bytes to evaluate, and (mime (agent nil)) takes 112 bytes to evaluate
15:42chouserwell, that's about as accurate as it's worth trying to get -- something less than 100 bytes per agent.
15:42djorkyes
15:42javuchiso it is reasonable to think that we could use around 60 millions of agents with 4gb of memory?
15:42javuchiperhaps 50 millions?
15:43chouserI don't know what all an erlang process has to track, but agents don't have their own stack or instruction pointer or anything like that.
15:43chouserAn agent is just a simple one-element container with a queue of actions to perform.
15:43tmountainGOSUB: http://www.infoq.com/presentations/Value-Identity-State-Rich-Hickey
15:44chouserjavuchi: as you queue up more actions, the agent will hold onto more memory until it can dequeu them.
15:44djorkthat is some zen stuff there
15:44javuchiso 50 millions is not very reallistic
15:45javuchiperhaps 5 millions would be more reallistic
15:45danlarkinjavuchi: there's no way to answer that, it depends on what the agents are doing
15:45djorkI would think about my architecture as soon as 5 million of *anything* was being considered.
15:46javuchidjork: think, for example, of a massive IM server
15:47javuchithat's when erlang is brillant
15:47javuchii'm think if clojure might be better???
15:47dysingerre: bulid.clojure.org RomanRoe I had to change the url and hadn't got around to posting an updated message to the list
15:47ordnungswidrigjavuchi: but 5 million on a single node / server sounds too much even for erlang
15:48dysingerthe maven url is http://build.clojure.org/snapshots now RomanRoe
15:48hiredmanjavuchi: clojure agents are not actors
15:48djorka massive server probably needs to be distributed, whereas clojure's strong point is concurrency
15:48dysingerRomanRoe: I wont mess with it again
15:48djorkyou could load balance between clojure nodes
15:49javuchianyway clojure is not designed for being distributed, is it?
15:49hiredman2009:Sep:22:09:02:37 rhickey : Writing a message queue? use Erlang. Writing an ordinary application? use a message queue.
15:50RomanRoedysinger: thanks!
15:50dysingerI still like erlang too
15:50RomanRoedysinger: my clojure hacking evening is safe again.... puhhhh..... ;-)
15:51dysingerthere are things you can do with networking and clustering in erlang that are trivial compared to socket programming in java land.
15:51djorkindeed
15:52djorkI'd say that if you want to, just develop your server in Clojure and then try scaling it with a message queue or something like Hadoop.
15:52djorkIt would be a good experiment.
15:52djorkI don't see it going too badly either.
15:53dysingerI am working on a peer-2-peer work group library in clojure that will allow clusters of repls to work together. Message queues don't solve all problems neatly.
15:53djorkmmm distributed repls
15:54hiredmandysinger: sounds kinda like terracotta
15:54dysingerminus 300k lines of code and instrumenting and XML
15:54hiredman:P
15:55dysingerno I don't have any shared memory needs
15:55dysingerI just need lots of machines to work together
15:55hiredmanhttp://vids.myspace.com/index.cfm?fuseaction=vids.individual&amp;videoid=60771080 <-- Origins of APL, the hair styles alone are worth it
16:00ordnungswidrighiredman: great video :-)
16:00ordnungswidrigevent roger moore has a role in it
16:01ordnungswidrigs/nt /n /
16:14chouserthey seriously didn't pause for a moment when they realized the development of their language required new keyboard mappings, fonts, and a "type ball"?
16:17ordnungswidrigchouser: they where from IBM, so it was no issue to build some new hardware.
16:17ordnungswidrigchouser: I think
16:18froogbesides, the world only needed 5-6 computers
16:18froogback then
16:18ordnungswidrigwith a most 640k memory
16:20ordnungswidrigthe host is smoking while the guest is talking. different times then.
16:20dublindanhow can i force symbol capture in macros?
16:20chouserdublindan: ~'foo
16:20clojurebotfoo is is Short, Self Contained, Correct (Compilable), Example http://sscce.org/
16:20dublindanchouser: thanks!
16:25javuchidysinger: do you have something done?
16:25dysingerit's a wip - soon
16:25dysingerI love it :) so simple and so cool :) can't wait to share
16:26javuchiwould it bring the power of erlang distributed to clojure?
16:27chouserjavuchi: http://github.com/amitrathore/swarmiji
16:29javuchilooks nice, chouser
16:29javuchidysinger: is your library something like that?
16:29dysingerno - that's message queues with no job tracking
16:30dysingerand no peer awareness
16:30dysingernot to knock it - amit is smart
16:30dysingerit's just a different tool than I am targeting
16:31javuchiso what are you doing?
16:34javuchidysinger?
16:37dysingerjavuchi: above "peer-2-peer work group library in clojure that will allow clusters of repls to work together."
16:38rhickeydysinger: are you using something like JGroups under the hood?
16:38dysingerIE, not message queues but clustered interacting repls.
16:38dysingerrhickey: yes-ish + branch/leaf node work tracking
16:39rhickeycool
16:39javuchidysinger: i'm trying to figure out what exactly you mean
16:39dysingerjust give me a couple weeks more I'll get it out there O.S.
16:39danlarkindysinger is spilling the secret sauce!
16:39dysinger:)
16:40rhickeydysinger: thanks for splitting off new branch on build.clojure.org - much easier to see what is what
16:41dysingeryeah plus it pollutes the maven repo with mixed branches plus there is a bug in hudson that once you add a branch you can't remove it.
16:41dysingerso it's best to just "copy" the job and modify it for the other branch
16:56javuchiwhat do you think about Shoal?
16:56javuchi(for clustering)
17:01twbrayGosh, it turns out that when you have to say -Xmx900m to get a clojure app to run, and it has tons & tons of threads, it really sucks the life out of your basic MacBook.
17:02hiredmanwhich one is Xmx again?
17:02chouserone of the unsung benefits of single-threaded apps -- no one of them can completely saturate your dual-core machine. :-)
17:03hiredman~google Xmx
17:03clojurebotFirst, out of 66500 results is:
17:03clojurebotXMX Home Page
17:03clojurebothttp://www.cs.brown.edu/software/xmx/
17:03hiredman:|
17:03danlarkinit's max heap
17:04hiredmanclojurebot: Xmx is max heap
17:04clojurebotAlles klar
17:13leafwtwbray: if your mac has two cores, try -Xincgc (incremental garbage collector). I found it to make the JVM perform better when creating lots of throwaway objects like clojure does.
17:14twbrayleafw: Cool, will give it a try. But this thing isn't really designed to run on my laptop :)
17:15leafwas for clogging your poor macbook, all one can do is renice the process. Other things help too to avoid swappign: remove window shading, remove window double buffering, closing power hungry apps like MSWord and Photoshop.
17:15leafwtwbray: then ssh to a server :)
17:15twbrayMSword!?!? Quit talking dirty, this is a respectable IRC channel
17:15leafwtwbray: I run ubuntu here on a macbook pro 5,5
17:16leafwtwbray: M$word is used by just about everybody I know. And I know it to be a problem, bot memory wise and because it can't be really swapped out; it keeps constant activity
17:17twbrayleafw: You need to start hanging out with a better crowd :)
17:17leafwtwbray: the world is larger than you think.
17:21javuchiwould clojure work with terracotta?
17:21chouserjavuchi: yes, more or less. There's been some work in that direction, not sure of its current state.
17:29javuchithis seems to be the most up to date information?? http://paul.stadig.name/2009/03/clojure-terracotta-next-steps.html
17:31jbendigjavuchi: Here is someone who uses Clojure with Terracotta on a live system for a vet hospital. http://groups.google.com/group/clojure/browse_thread/thread/85649a134cf22655?tvc=2
17:34Chousukehmmhmm.
17:39Chousukehoh
17:39ChousukeFinally managed to compile contrib
17:40hiredman:D
17:40Chousukethis is a great step forward :P
17:42hiredmanso even after you could read clojure, contrib still had problems?
17:43Chousukereading is different from reading it correctly so that it can be compiled :P
17:44hiredmanI mean, you can read clojure.core in and it compiles fine, yes?
17:46Chousukeyeah. though I haven't tried to use the compiled result
17:46Chousuke... much :D
17:48savanniI asked this before but may have missed the answer, so I'll ask again. Is there a way to enable a stack trace or something for when I get a Null Pointer Exception in my code?
17:49Chousukeyou can do (.printStackTrace *e)
17:49Chousukeif in repl
17:49Chousuke*e means latest exception
17:51savanniAwesome. A little arcane, but that will help out a lot later.
17:51Chousukehmm, contrib tests pass, except for one that overflows the stack for some reason
18:00hiredmansavanni: checkout clojure.stacktrace
18:03savanniIs that in core?
18:03hiredmanit's in stacktrace.clj, which is right next to core.clj
18:04savanniOkay... like with test-is, I'm going to need to upgrade to the clojure dev before I will be able to use it.
18:04hiredmanare you sure? I'm not sure when it was added
18:05savanniWell, my 1.0.0 library claims that clojure.stacktrace is not found, so I would assume so.
18:39cow-orkeris there a practical difference between #_"comment" and ;comment ? I know they have different "scope", but for short comments...?
18:40hiredman#_ eats the following form
18:41hiredman; drops everything until a newline
18:41hiredman,#_(
18:41clojurebotEOF while reading
18:41hiredman,;(
18:41clojurebotEOF while reading
18:41hiredmannot a good demo, I guess
18:43cow-orkerwell.... I got that part more or less :) I asked because #_"" was used for short comments in (defmacro for ...) in core.clj. Just wondered if there was some reason for commenting that way.
18:43Chousukewell, you can put them in the middle of stuff
18:43Chousuke,[foo #_"bar:" bar]
18:43clojurebotjava.lang.Exception: Unable to resolve symbol: foo in this context
18:43Chousukeoops
18:43Chousuke,'[foo #_"bar:" bar]
18:43clojurebot[foo bar]
18:44cow-orker:)
18:44Chousuke,'[foo ;bar: bar]
18:44clojurebotEOF while reading
18:48cow-orkerwhat got me wondering was in master/src/clj/clojure/core.clj line 3019, but I guess here it's just style
18:50hiredmaninteresting
18:51hiredmanI think a lot of that is chouser's work
18:51hiredman(maybe all?)
18:53cow-orkerthanks, I'll ask him when he's online :)
19:07JorejiHey guys, is there some way to ensure that an agent is running in the main thread?
19:08rhickeyJoreji: will never be
19:09rhickeythey run in thread pools
19:10JorejiOh.
19:10JorejiOk, thanks.
19:19JorejiHow can I translate "new TimerTask() { public void run() { ... } }" into clojure?
19:20Chousukecan you construct TimerTasks from callables?
19:21JorejiIn java? Yes.
19:21ChousukeThen you could just do (TimerTask. somefn)
19:21Chousukeeg. (TimerTask (fn [] (println "hello"))
19:21hiredmanno, you can't
19:21JorejiBut that would require me to write java code.
19:22hiredmanJoreji: Chousuke meant "Does the TimerTask constructor take a Runnable"
19:22hiredmanwhich it doesn't
19:22JorejiAh, no.
19:22JorejiIt does not take a Runnable.
19:22hiredmanwrapping a fn in a proxied TimerTask is pretty trivial
19:23ChousukeI gues you'll need proxy then :)
19:23Chousuke+s
19:23hiredmanI would push you in the direction of ScheduledThreadpoolExecutor
19:23hiredmanwhich takes runnables directly
19:24Jorejihiredman: Hm. Are the java timers all running in a different thread?
19:25onigirihi guys
19:26onigiriI'm really really new with clojure, I was playing along with the REPL now and tried some functions:
19:26onigiriI've got a utf8/strings bug (or at least what I think is a bug)
19:26onigiri(.toUpperCase "harajuku 原宿") yields "HARAJUKU 僆宯"
19:27hiredmanJoreji: Timer uses a single thread
19:28JorejiHm ok.
19:28onigiriI'm still trying to wrap my head around functional programming, so I thought that the only thing I was able to do was to report it ;)
19:28hiredmanonigiri: it might be an issue with java's String
19:28hiredmanin which case there is nothing to be done about it
19:29Chousukeonigiri: I don't think that's a Clojure bug :)
19:29onigirihiredman: oh ok :)
19:29Chousukeamusing, thoug.h
19:29onigiriChousuke: heh
19:30ChousukeI guess toUpperCase is just a dumb function that assumes its input is actually something that can sanely be uppercased :P
19:31onigiriand the fun thing was that I guess was twbray's fault if I'd tried it :P I remember his talk about unicode and ruby and since he's now learning Clojure, my head mixed the 2 thoughts :P
19:31onigiriChousuke: yes, I guess so.
19:32onigiriI may peek under the clojure hood to see if there's a hint though
19:32technomancyonigiri: there's not much of a hood; that's a direct JVM method call. =)
19:32twbrayonigiri: That is kind of surprising
19:32ChousukeJava strings aren't quite as bad as Ruby (1.8) "strings" but they're not perfect either :/
19:32twbrayString.toUpper looks at your LOCALE and does all sorts of voodoo
19:33cemerickcasing is *very* complicated
19:33onigiritechnomancy: oooh! you're right! I was in fact reading the direct java call
19:33onigiriparagraph...
19:33twbraybut it should realize that that's in a case-free language and just no-op
19:34onigiritwbray: yes, indeed: before asking here I tried with ruby and it worked fine (I tried just to check if I was expecting the correct behaviour)
19:34twbrayHOld on, I keep a java sandbox project around for just this sort of thing
19:35cemerickonigiri: http://www.brosinski.com/stephan/2008/02/09/the-evils-of-javalangstringtouppercase/
19:35twbrayonigiri: Remember, in my original Ruby/Unicode talk I basically said "Don't use toUpper/toLower". I still think I was right :)
19:35cemerickif you provide the target locale, it will likely work correctly
19:36onigiritwbray: hehe I know :) I still have that talk burned in my head :)
19:36onigiricemerick: reading now, thanks
19:37twbrayonigiri: When I run it in pure Java in NetBeans, it comes out OK
19:39onigiritwbray: hmm, if you run in your REPL is the "bug" reproduced?
19:40twbrayuser=> (println (str "In: harajuku 原宿 out: " (. "harajuku 原宿" toUpperCase)))
19:40twbrayIn: harajuku 原宿 out: HARAJUKU 原宿
19:40cemerickonigiri: what's your system/java locale?
19:40twbrayRight, try echo $LOCALE at shell
19:41onigirinot set
19:42onigiritwbray: I'm on a MBP 10.5, and if I run locale, I get LANG="it_IT.UTF-8"
19:43onigiribut an echo $LOCALE yields a deafening void
19:43twbrayAs long as it's got UTF-8 in there you should be OK.
19:43cemerickonigiri: eval this in clojure: (java.util.Locale/getDefault)
19:43onigiritwbray: you on SLeopard?
19:44twbrayonigiri: yes
19:44twbrayJava 6, 64 bit
19:44onigiricemerick: hehe here's the culprit
19:44onigiriuser=> (java.util.Locale/getDefault)
19:44onigiri#<Locale en_US>
19:44twbrayonigiri: Same for me, en_US
19:45cemerickyeah, that's mine, I don't have an issue with uppercasing those glyphs
19:45cemerickchars*
19:45twbrayonigiri: What environment are you running in? xterm? IDE?
19:45onigiritwbray: plain old Terminal
19:45twbrayI'm doing this in NetBeans Enclojure REPL
19:46onigiria github cloned clojure just builded
19:46onigirithat was run with a java -jar clojure.jar
19:47twbrayHah! When I do it terminal, I see the bug
19:48twbrayMac Terminal.app I mean
19:48onigiritwbray: good, at least I'm not seeing things ;)
19:48cemerickfunny. Just set your encodings in terminal's prefs, probably
19:51twbrayonigiri: Go get enclojure, it's pretty good
19:51twbrayDisabled everything but UTF-8 in the terminal prefs, didn't seem to make any difference.
19:52onigiritwbray: I read your post, I was more partial to try the vimclojure
19:52onigiriI don't have any java IDE or emacs installed
19:52twbrayThat might work. Still can't figure out what Terminal.app is sending Clojure though.
19:52cemericktwbray: glad you've come around on enclojure :-)
19:53onigiritwbray: for what it matters, I tried setting UTF16, but nothing changed
19:53twbrayoh, of course, inside NetBeans, it's probably an all-UTF16 world.
19:54cemerickI presume those are display encodings. It'd be worthwhile to see what code point clojure reports in the terminal for those chars, maybe the input is getting munged.
19:55twbraycemerick: I think that has to be it.
19:56twbrayonigiri: Anyhow, the right answer is still the same - don't use toUpper/toLower. (snickers)
19:57twbrayAmong other things, they're unbelievable performance pigs.
19:57onigiritwbray: hehe
19:58cemerick(int (first "宿")) reports 194 in my terminal, 23487 in enclojure, definitely an input issue
19:58cemerickand (count "宿") is 3 :-)
19:58onigiriat least this bug made me do a foray in the #irc and now this channel is set for autojoin ;)
19:59ChousukeI get 23487 in emacs
19:59cemerick,(.toUpperCase "宿")
19:59clojurebot"宿"
19:59ChousukeI have it configured to be UTF-8
19:59cemerickit's crazy that irc is so unicode-friendly these days
19:59onigiriso the Terminal.app is the borked one
20:00twbrayI usually drop into an aquamacs shell when I have to do serious non-ASCII at the command-line level
20:00Chousukecemerick: well, at least English-speaking people won't have to deal with encoding wars because UTF-8 is ascii-compatible :P
20:00cemerickChousuke: sorry? :-)
20:01twbrayMaybe iTerm would be better?
20:01Chousukecemerick: some years ago there were debates all over the Finnish IRCSpace whether UTF-8 should be allowed or not, because the de-facto standard was ISO-8859-1 and it's UTF-8-incompatible.
20:02Chousukeonigiri: I think you need to specify the encoding with a jvm property somehow.
20:03twbrayDebates about i18n stuff used to regularly provoke paralyzing stupidity up until sometime earlier this decade when everyone just rolled over and gave in to Unicode.
20:03onigiriChousuke: I fear so
20:04cemerickChousuke: I'm guessing it has nothing to do with java.
20:04ChousukeI get 194 in iTerm as well, with a plain repl.
20:07ChousukeIf I do java -Dfile.encoding=UTF-8 -jar clojure.jar then it works. .)
20:07cemerickhuh
20:08Chousukeit defaults to MacRoman on OS X I think
20:09Chousukeso when I print UTF-8 in Clojure in an UTF-8 terminal it'll show up even then, but only because the bitpattern happens to match what the terminal expects, not because the JVM prints it out as UTF-8 :)
20:09onigiriChousuke: oh you beat me: I just found the -D flag ;) nice
20:11onigiriso I guess the matter was solved, thanks everyone!
20:11ChousukeI wonder why the JVM is MacRoman by default anyway :/
20:11ChousukeOS X is pretty much entirely Unicode otherwise :P
20:22onigiriok, back to clojure study
20:53krumholthi can i proxy an abstract class?
20:54cemerickyes
20:55krumholtso if i proxy something it will be an anonymous class extended from the abstract class?
20:56cemerickright
20:56krumholtok thanks
21:01djorkwhat's the most idiomatic way to do something n times?
21:01djorkI've been doing (take n (repeatedly #(foo)))
21:02djorkbut it seems like the closure is a bit unnecessary
21:02cemerickdotimes if you're looking for side effects
21:03mikehincheyyou can just use foo instead of #(foo) if foo is a regular function
21:04cemerickhah, I didn't even notice that :-P
21:04cemerick,(take 5 (repeatedly rand))
21:04clojurebot(0.2702439022277704 0.06886273089068606 0.908758027809942 0.5910756151509906 0.9058909510000488)
21:04cemerickI wrote that a couple of times last year :-)
21:05djorkI am looking for dotimes, I think
21:05cemerickdjork: note that it isn't lazy and returns nil
21:06djorknot a problem
21:06djorkjust need to literally do something
21:06djorkpurely for side effects
21:06iceyAnyone here spend much time with compojure? I'm having an issue that doesn't make sense to me when trying to include it in slime. I'm sure it's a noob issue.
21:06hiredmanwhat is the issue?
21:07icey(I'm getting NoClassDefFoundError on org/apache/commons/fileupload/FileUpload whne I try to (use 'compojure))
21:07hiredmanah
21:07djork(dotimes [_ 5] (System/gc))
21:07iceycompojure is in my classpath, I am getting the problem on 2 machines, so whatever I've done wrong I've done wrong in a consistent fashion
21:08hiredmanjust a second
21:08cemerickdjork: invoking System/gc is generally a waste of time
21:08hiredmando you have all of compojures dependencies on the classpath?
21:08iceyhmm most likely not
21:08djorkcemerick: not in this case
21:09djorkit's for a very particular purpose
21:09hiredmanwell, there you go
21:09hiredmanif you run ant it will grap a zip of all the deps
21:11iceyhiredman: i'm taking a look in the deps dir, just so I'm clear all the jars need to go in the classpath? (sorry, I have done like 0 java prior to touching clojure)
21:12hiredmanyes
21:12iceyhiredman: i'll give it a swing and see what happens, thanks :D
21:12hiredmanyou can leave out clojure/contrib if you already have those, but you might run into versioning issues
21:29iceyhiredman: thanks for the tip regarding the classpath stuff on compojure; that did the trick for me :D
21:37djorkthe classpath is a harsh mistress
21:47djorkanybody using something like this? http://gist.github.com/227662
21:47djorkis this adequate?
21:47djorkI use it in my clj script
21:53_mstthe 1.6 JVM actually lets you do java -cp '/some/where/*' to pick up all .jars from that directory
21:54_mstbut I've used that same trick in 1.5 :)
21:54djorkoh wow that's nice
21:54djorkI'm using 1.6
21:54djorkoh well it's already working
21:54djorkI can also do . src foo/*.jar to build it
21:54djorkreal globbing is nice
22:56qedI know this is kind of a lame question but-- I'm wondering if there are any easier ways than using compojure
22:56qedhas anyone built an all-in-one installer or package for compojure?
23:08hiredmanqed: running ant in the git checkout of compojure will download all the dependencies
23:30qedhiredman: it's not working for me
23:30hiredmanwhat is not working?
23:31qed /Users/defn/src/compojure/build.xml:35: /Users/defn/src/compojure/deps not found.
23:31qedno deps dir in there
23:31hiredmanmake one?
23:31qedomg im a moron
23:31hiredman
23:31qedapologies
23:32qedPS: I didn't need the UTF-8 to rub it in
23:39technomancyit would really be great if contrib's 1.0-compat branch got its own version number to distinguish it from master so we could add it to build.clojure.org
23:39technomancycould we bump master up to 1.1.0-alpha-SNAPSHOT to match clojure itself?