#clojure logs

2012-01-30

00:00aphyrYeah, insertion or arbitrary order.
00:00aphyrDo you suppose I could re-jigger a list or vector to implement that interface?
00:01aphyrhttps://github.com/cgrand/parsley/blob/master/src/net/cgrand/parsley/lrplus.clj#L67
00:01aphyrthat, specifically, is what I'm trying to force to evaluate a set in a certain order.
00:03jeremyheilerCould use sorted-set-by with a custom comparator that preserves insertion order by always returining 1.
00:03amalloyjeremyheiler: that would be a disaster and not work
00:04amalloy(a) it's gross that parsley requires you to give it sets, but (b) just write a (set-in-this-order 'a 'b 'c) function, that creates a custom comparator when you give it the items
00:04aphyrWhere the comparator... attaches ordered metadata to the objects?
00:04aphyrOr can I presume that (fn [] 1) will be stable?
00:05amalloyhuh? just create a new comparator that keeps a copy of the original order
00:06aphyrHmm. Feels inefficient... really all this thing needs is a type that's APersistentSet and Seqable, if I understand correctly.
00:06amalloy(defn my-set [& args] (let [order (zipmap args (range))] (apply sorted-set-by (fn [a b] (- (order a) (order b))) args))) or something
00:06jeremyheilersets are seqable
00:06aphyrCan I extend List to be APersistentSet?
00:07aphyrOr I guess I could just patch Parsley to accept some core type like lists for alternation.
00:13jeremyheileramalloy: what exactly is wrong with this? ##(sorted-set-by (fn [x y] 1) :b :a :d :c :f)
00:13lazybot⇒ #{:b :a :d :c :f}
00:14amalloy&(let [elts [:b :a :d :c :f], s (apply sorted-set-by (fn [x y] 1) elts))] (map s elts))
00:14lazybotjava.lang.RuntimeException: Unmatched delimiter: )
00:14amalloy&(let [elts [:b :a :d :c :f], s (apply sorted-set-by (fn [x y] 1) elts)] (map s elts))
00:14lazybot⇒ (nil nil nil nil nil)
00:15amalloyjeremyheiler: if your comparator lies, you can seq over the list, but you can't look things up by key
00:16jeremyheileramalloy: ah yes, forgot sets were just maps underneath.
00:16Raynesamalloy: What is spark plug? What is car?
00:16jeremyheilernever really thought of pulling things out of a set by a key
00:16amalloyit doesn't matter if they're maps underneath
00:16amalloyyou can't call contains? either
00:16amalloy(or rather, it won't work)
00:17nrichardsDoes anyone know the the timeout for 4clojure solutions? I have a problem that finishes in < 30ms on my machine but gets "An Error occured: timeout" on the site
00:18Raynesamalloy: Why don't you write up something about this for an FAQ or something on 4clojure?
00:18Raynesamalloy: It has to be kind of frustrating.
00:19aphyrOh, amalloy, you *wrote* an ordered-set!
00:20amalloyi did. and you're welcome to use it, but if you only have static fixed-size sets, the defn i put in earlier will surely be more lightweight and less complicated
00:23aphyrThey're being destroyed immediately after parser generation... doesn't really matter to me.
00:23aphyrI'll just use the library, make my packaging easier.
00:25jeremyheileramalloy: sorry, didn't mean to sound rude. was just looking for further explanation.
00:25amalloynor i. just further clarifying/explaining
00:26Raynesjeremyheiler: He is lying. Look at his poker face.
00:27amalloyhe can't read my poker face
00:27jeremyheilerI can buffer it though
00:32muhoop p p p p p poker face
00:32aphyr(satisfies? clojure.lang.APersistentSet #{})
00:32Raynesmuhoo: You forgot a 'po' there.
00:32aphyrjava.lang.NullPointerException
00:32aphyr:/
00:33amalloy&(doc instance?)
00:33lazybot⇒ ------------------------- clojure.core/instance? ([c x]) Evaluates x and tests if it is an instance of the class c. Returns true or false nil
00:33aphyr(instance? clojure.lang.APersistentSet (ordered-set 1 6 ))
00:33aphyrfalse
00:33aphyrhmmm
00:34aphyrSo I guess I do need to implement a custom comparator then
00:34amalloyIPersistentSet
00:34aphyror write my own damn parser generator
00:34amalloyif it checks for APersistentSet that's frankly retarded, whereas checking for IPersistentSet is just distasteful to me
00:35aphyrhttps://github.com/cgrand/parsley/blob/master/src/net/cgrand/parsley/lrplus.clj#L67
00:35aphyrI don't exactly understand how protocols interact here
00:36aphyrBut it looks like that ... class? Is being extended with a function for the TokenMatcher protocol?
00:36amalloyah. so it's not doing any silly checking
00:38aphyrAh, A suggests that it's an abstract class?
00:38amalloyjust extend that protocol to whatever type you want, with a behavior that's similar to do what you want. say, to ISeq
00:38aphyrIs it possible to extend only a single object with a protocol?
00:38amalloyno
00:39aphyrSo I need to define a new type
00:41aphyrGoddamnit, I'll just write the damn thing as a PEG
00:42muhoowow, the docstring for deftype is like 3 pages lonng
00:54amalloyjeremyheiler: wish granted, conditional upon your being on the west coast
00:55jeremyheilerwill be in march -- but not today :-/
00:55muhooit's sunday here. it's probably been monday for like a day already in australia
00:55muhoothis joy of clojure book is really good.
00:55jeremyheileralthough it's summer there, dam
00:56jeremyheilermuhoo: i concur
00:56muhoobeats the hell out of trying to learn from just reading the language reference and random stuff from the internets.
01:02taliosmuhoo: 7pm Monday evening in Auckland, New Zealand here.
01:03amalloywas monday any good, or should i just stay in bed?
01:03taliosamalloy: public holiday ( Auckland aniversary day ) so I spent it in the sun with bro and his 1yr old daughter ( and his wife ). so good.
01:03taliosand then coded my pet project to all green tests. so double good.
01:05taliosnow contemplated dinner, or the gym - then dinner.
01:05talioss/ed/ing/
01:11muhootrying to decide if i should blow $500 on attending clojure/west
01:11muhoobummer it's in san jose. if it were in san francsico i could just bart it there.
01:12taliosif you think going would be "blowing" away $500 then yes. sounds like you think it's not worth it. I'd love to go.
01:12muhooi don't know if it'd be worth it. $500 is a lot of money to me.
01:12jeremyheilerI'm flying out form New York. I wouldn't mind switching costs with you, muhoo
01:12jeremyheilerlol
01:13taliosMmm, I suppose - thats $500US, jeremyheiler - hey, if I went I'd be paying upward of $4000NZ in flights alone!
01:13taliosi think.
01:13jeremyheilertalios: yikes!
01:13muhoojeremyheiler: 1am there?
01:14jeremyheilerI imagine it's a lot -- it's already a pretty penny to fly to cali from ny.
01:14taliosMmm, no direct flights from Auckland to San Jose, what would be the closest international?
01:14muhoohmm, then maybe i should take advantage of the opportunity to not have to fly then :-)
01:14amalloysfo probly
01:14muhootalios: SFO
01:15muhoosan jose is a relatively small airport
01:16talios$2,209.34 NZ return to San Francisco, then I'd just have to get from there to San Jose. Plus accom. FOR TWO DAYS. :)
01:16muhoodamn.
01:16taliosIf I went I'd make a week or so of it. But still, thats A LOT of coin.
01:16muhooyep, i have a friend in australia, haven't been to visit him yet, in 10 years, just can't afford it.
01:16muhoocross-pacific flights are crazy expensive.
01:17jeremyheilermuhoo: yep, it's 1am
01:18muhoowell i think i'm going to do it then, and see how it goes.
01:24muhooack, the early registration deadline was yesterday
01:24muhoodamn, coulda saved myself US$75. oh well.
01:25jeremyheilermuhoo: i can get you $25 due to this special thing they're doing.
01:25jeremyheiler$25 off*
01:28muhoothat'd be cool, thanks
01:28jeremyheilerpm me your email, i'll forward you the email they sent
01:28muhoocool, thanks!
01:33jeremyheiler^ wanted that to say pokemon
02:51yawNOhello :D
02:51yawNOjust started learning clj
02:56jeremyheileryawNO: nice!
02:57yawNOi never thought i would have said that
02:58yawNOcoming from ruby and js
02:58yawNObut i like it
02:58yawNO:D
02:58jeremyheilerAre you playing with ClojureScript, too?
02:59yawNOi started learning clj because of it
02:59yawNOi am mainly a nodejs developer
03:01jeremyheilernice! there's a lot going on with cljs at the moment.
03:03yawNOjeremyheiler: is there a irc chan for cljs?
03:03jeremyheilerthis is it
03:03yawNOah
03:03yawNOlol
03:05jeremyheileranywho, i need to get some shut-eye. hope to see your around yawNO!
03:14clj_newbcan I capture the state of a graphics 2d in a BufferedImage? I currently want to have an optimization where I render graphics2D to a BufferedImage, then unless stuff changes, just repaint the bufferedImage instead of rerenderinb everything; the only question is: does this intermediate step reduce quality of rendering?
03:22Licenserclj_newb I don't think it will reduce the quality, AFAIK it is a common practice
03:26Blktgood morning everyone
03:31Licenserhi Blkt
03:32Blkt:D
03:32clj_newbLicenser: cool; any known drawbacks with this?
03:33Licensermore memory usage usually :)
03:33clj_newbI have something like 16GB of RAM
03:34Licensersome image containers even allow a double buffered mode wich allow you to draw in the background and just swap the buffers when done
03:34clj_newbis switching atomic?
03:34Licensernot sure, it has been a long time since I played with that kind of stuff
03:34clj_newbat the moment; Im creating new images and sending it to agents
03:35Licenseralso it was back in Delphi with Borlands canvase objects
03:36Licenseralso that does not sound too bad what you do
03:36Licenserwhat kind of place you use to draw them?
03:36clj_newbi'm writing a wygiwyg editor
03:36clj_newbrendering pages is expensive
03:36Licenserah I see, and yes I understand that :)
03:36clj_newbwhich only needs to render when the document changes; not when I'm scorlling around, etc ...
03:37Licensera wysiwyg or really wygiwyg?
03:37clj_newbthese images I create on the fly on created, live shortly, and then die fast
03:37clj_newbso I think the java gc handles them well
03:37clj_newblol
03:37clj_newbwygiwyg editor encaptures all editors I think
03:37clj_newbincluding LaTeX and MS Word
03:37Licenser^^
03:38LicenserWord is more a What I want is What You Get editor
03:38clj_newbs/I want/Clippy thinks is best/
03:39Licenserthat is what I ment with I :P
04:09clj_newbdo element sent to agents ever get released?
04:09clj_newbif so, when?
04:15AWizzArdclj_newb: what “elements” do you mean?
04:18jondothi guys. i'm reading Storm clojure code on and off, i found this https://refheap.com/paste/492
04:19jondotsince storm-cluster-state isn't used, can we replace the whole thing with just (when-let (:conf nimbus) .. ?
04:21scottjjondot: I don't think so, because (:conf nimbus) is not the same as ((:conf numbus) NIMBUS-REASSIGN)
04:22scottjyou could probably do (when ((:conf nimbus) NIMBUS-REASSIGN)) (mk-assign..) though
04:22jondotlet me rewrite that
04:22scottjremoving the let entirely
04:23IceD^https://gist.github.com/1703536
04:24IceD^and when I'm trying to do get-messages on empty queue, exception is thrown, but I can't catch it
04:24IceD^https://gist.github.com/1703540
04:24IceD^any ideas?
04:25jondothow about this https://refheap.com/paste/493
04:29scottjjondot: no, you can't call (conf NIMBUS-REASSIGN) bc conf isn't bound ot anything
04:29scottj(when ((:conf nimbus) NIMBUS-REASSIGN) is what you want
04:30scottjmake sure you always have a :conf though on your nimbus otherwise you'll get a nullpointerexception
04:33IceD^weird
04:35jondotscottj, right. well i don't work on Storm, but just reading for educational purposes. any idea why that code was left that way? https://github.com/nathanmarz/storm/blob/master/src/clj/backtype/storm/daemon/nimbus.clj#L504
04:37scottjjondot: he probably used storm-cluster-state in an old version of the function and clojure doesn't have a "you're not using this variable" IDE helper so it's easy to miss
04:37jondoti see, ok
04:53amroI'm having trouble setting up clojurescript repl with chromium- I can see in the inspector that it's connecting, but the repl just hangs when I type in a form
04:53jondotim wondering about the benefits of clojurescript..
04:54amronot writing code in javascript
05:11IceD^ok guys, my lib is ready
05:11IceD^how do I distribute it ;]
05:12Fossigithub? :)
05:12foodoowhat about clojars?
05:13Fossiyeah, that too
05:13jondotamro, how about coffeescript?
05:14raekIceD^: https://github.com/ato/clojars-web/wiki/tutorial
05:14IceD^yes, project will be on github in a min
05:14IceD^writing README
05:15raekyou also have to register on Clojars http://clojars.org/register
05:15scottjREADME driven distribution.
05:15IceD^raek, that's what I need, thanks
05:16raekuse semantic versioning
05:16raekand if your library is ready for use, realease it by making a non-SNAPSHOT version available
05:16raekfor example 1.0.0
05:16IceD^raek, is is ;]
05:16raekgreat!
05:16IceD^tested it - everything works perfectly
05:17IceD^it's client for ironmq (http://iron.io)
05:17raek(you see a lot of 0.0.1-SNAPSHOT, even in production, these days)
05:17IceD^yeah, I know
05:17IceD^makes me angry
05:17IceD^btw - small code review 'd be nice
05:18IceD^https://gist.github.com/1703725
05:18IceD^I'm seasoned lisp dev, but used clojure only for fast internal things
05:18IceD^so it's possible my code isn't idiomatic
05:19foodooIceD^: Please write proper documentation metadata
05:19IceD^foodoo, ofc
05:19IceD^FIXME will not let me forget this
05:20IceD^better yet, I'll make our doc guy do it ;)
05:20foodooIceD^: I'm still not sure what this module does
05:20scottjIceD^: :use is not recommended unless you use :only
05:20IceD^it's api for ironmq ;]
05:20raekIceD^: namespace names have hyphens in them when the files have underscores in them
05:21scottjIceD^: also I think you can do & {:as options} and then not have to do (apply hash-map options)
05:21raekso (ns iron-mq-clojure.client ...) in the file src/iron_mq_clojure/client.clj
05:21IceD^hyphen - fixed
05:21IceD^what to use instead of :use
05:22IceD^I'm using only two funcs from there
05:22scottjIceD^: (:use chesire.core :only [list of functions you use])
05:22yawnthai
05:22raek(:use [chesire.core :only [list of functions you use]])
05:22yawntno prior experience w/ lisp
05:22raekthe []s are needed for options
05:22yawntwhich book should i begin w/?
05:23yawntjoy of clojure? clojure in action?
05:23scottjraek: thanks
05:23foodoo"programming clojure" is a good introductory book. But won't go deep into the language in my opinion
05:23scottjyawnt: I think JoC is ocnsidered more advanced.
05:24yawntso foodoo .. what would your advice be?
05:24yawntscottj: okay so not that one
05:24CmdrDatsyawnt: I agree with foodoo - Programming Clojure is a good book to start
05:24foodooprobably "programming clojure" + "The joy of clojure" is a good combo?
05:24yawntthx :D
05:24CmdrDatsjoy of clojure is amazing, but the pace is fast
05:25yawntcause i heard a lot of people speaking about clojure in action too
05:25raekI would write (map (fn [m] (if (string? m) (create-message m) m)) messages)
05:25raeklike this: (->> message (filter string?) (map create-message))
05:25CmdrDatsi can't speak for clojure in action - haven't read it yet
05:25CmdrDats(i certainly intend to though! :P )
05:25scottjprogramming clojure has a new version coming out (not sure date) since the existing is slightly outdated
05:26yawntexisting is 2009
05:26yawntafaik 1.2 brought major changes
05:26yawntor was it 1.3?
05:26raek...or perhaps as (for [m messages :when (string? m)] (create-message m))
05:26foodoosidenote: "programming clojure" was written with Clojure 1.2 in mind. The current version is Clojure 1.3
05:26yawntfoodoo: really?
05:26yawntgood to know
05:27foodooBut I think it's still very current.
05:27foodooBut there will be a new version somewhere in March I think
05:28foodoo(Amazon says 6th of April )
05:28scottjfoodoo: I don't think so. I thought they released 1.0 FOR programming clojure. don't think it mentions deftype/protocol/record
05:28raekIIRC, programming clojure was written at the time of Clojure 1.1
05:28IceD^more advanced question
05:29raekI still think it's a good book, though
05:29IceD^I have multi-deps (for 1.2.1) in my project.clj
05:29IceD^how to test against them without pushing lib
05:29raekespecially if you come from java or another oo language
05:30foodooscottj: true, these topics aren't in the book
05:30scottjIceD^: in request fn, you could use destructuring to not repeat (:key client). you don't need do inside let. you could use doto to not repeat conn.
05:34IceD^removed do, used doto
05:34IceD^destructuring - how
05:38scottjIceD^: https://refheap.com/paste/494
05:38scottjIceD^: opps, you don't need two lets. move the contents of first into second.
05:39scottjIceD^: it's a debateable change since it no longer shows exactly where the data comes from at the point of use.
05:42IceD^scottj, ahh, considered that
05:42IceD^doesn't improve code from my poc
05:42IceD^pov*
05:42scottjyeah I probably agree
05:49amrojondot: I don't like it
05:50amroanyway I figured it out, I was missing <meta charset="UTF-8">
05:50scottjamro: that should be a FAQ
05:51amroindeed- or perhaps the js part should spit out an error
06:20IceD^https://github.com/iron-io/iron_mq_clojure - here we go
06:21IceD^thanks for your help guys
06:42jbiesneckerIf anyone's interested, I'm putting together a number theory/other math library, available at: https://github.com/biesnecker/clj-numbers
06:42jbiesneckerMostly Project Euler inspired now (and rough, because it's serving as my "let's learn Clojure" project), but I'm happy with the functionality it's starting to provide.
06:46clgvjbiesnecker: seeing 'digits and 'binary-digits why dont you just add a base for the digit representation? ;)
06:48jbiesneckerclgv: that's a good point (the answer is that digits came way before binary-digits, and I didn't think about it :)), I'll make that happen in the next release.
06:50clgvjbiesnecker:: I would also rewrite 'integers-larger-than and its friend with usage of 'iterate
06:51jbiesneckerclgv: Is there a particular reason for that? It would certainly be cleaner, but is there a performance difference between the two (or other reason/s)?
06:52clgvjbiesnecker: yes it's cleaner since it's just weird to use a double constant of infinity there. that might cause unforseen trouble whereas the other one is easy to check that its working ;)
06:53jbiesneckerclgv: good reasons all :)
06:59jbiesneckerclgv: (though actually the Double infinity constant is how range itself is implemented -- originally I wanted to do a negative range with a start and no end, didn't think of iterate, and looked up the source to range to figure out how they do it)
07:00clgvjbiesnecker: oh, thats bad programming then...
07:01clgvjbiesnecker: reading the source, that is due to the function organization. they have to have some end-value.
07:01clgvjbiesnecker: but the two function of yours do not need such an end value^^
07:02jbiesneckerclgv: right… iterate is clearly the better choice here
07:23echo-areaDoes anyone read /The Joy of Clojure/? The example using ThreadPoolExecutor via dothreads! won't work as 11.2.1 tells, as without shutdown'ing the executor the process will be hanged out there, right?
07:29clgvecho-area: well if you stay in a repl it should work like told. if you build a jar that might not exit without shutdown
07:33echo-areaclgv: Okay thanks
07:34echo-areaclgv: I'd like to write those examples in a file named some.clj then execute that file, as I think that's easier to be experimented with :)
07:34clgvecho-area: in the box you are told that it was written for demonstration purposes only
07:35clgvecho-area: what do you use as development environment?
07:35echo-areaclgv: I see that. But I still want to change it a bit and see how things go
07:35echo-areaclgv: Emacs + SLIME
07:35clgvecho-area: ah well then you should use REPL and file for experimenting ;)
07:36clgvecho-are: copy the function definitions in the file, reload and try them on the REPL
07:36echo-areaclgv: Yes, I tried C-x C-e yesterday, but it seemed to hang too. I was confused. Maybe I did it wrong, nevermind
07:37clgvecho-area: cant help you with the emacs setup since I am member of the non-emacs minority ;)
07:38echo-areaclgv: Okay. BTW, the diff between (board-map #(dosync (deref %)) board) and (board-map deref board) is that the former wait until all threads done but the latter just read an intermediate value, right?
07:39clgvecho-area: I dont remember the details of the board-map example and cant re-read them right now
07:40clgvecho-area: dosync is a transaction that you need to access the refs
07:41echo-areaclgv: The board-map form is evaluated right after the threads get started. I don't understand the dosync form around deref
07:42echo-areaTo me, it seems there's no difference with or without the dosync form
07:45clgvecho-area: well the second will only work if it is somehow enclosed in a dosync directly or indirectly
07:47echo-areaclgv: But I tried one without dosync, and it worked
07:48echo-areaclgv: And the doc of `deref' says "Within a transaction, returns the in-transaction-value of ref, else returns the most-recently-committed value of ref."
07:50clgvah ok. mixed it up then.
07:50echo-areaWhat does that mean? Is there any difference between the two, for Ref's?
07:51echo-areaThanks
08:01CmdrDatshey guys, I'm busy building a small library for defining schema's in mysql, with auto-updating columns, indices and foreign keys.
08:01CmdrDatsdoes that sound vaguely useful, or am I duplicating someone else's work?
08:23clgvCmdrDrats: you could search github and clojars for the related keywords and see what you find
08:35CmdrDatsclgv: thanks - i can't find anything though.. this is how I define the entities currently : https://gist.github.com/1704412
08:36CmdrDatsi'm staying away from trying to abstract SQL itself, too many libraries already doing that
08:37CmdrDatsbut defentity macro itself defines a defrecord and a couple of helper crud functions
08:38clgvCmdrDats: did you have a look if ClojureQL has something for what you do?
08:40CmdrDatsclgv: i've looked, but everything is against an existing database - what I want is something to describe a database and then it must make sure the database is up to date and correct
08:40clgvCmdrDats: "database life cycle management" to express it in "manager speak"? :P
08:41CmdrDatshehe, i guess so :P
08:44clgvCmdrDats: what about that one? http://budu.github.com/lobos/
08:44CmdrDatslooks promising
08:45CmdrDatsexcept, ugh, it needs to express entities in their final state - not just a wrapper to SQL :P
08:45CmdrDatsbut i might actually incorporate lobos to gain a bit of abstraction from specifically mysql
08:46CmdrDatsI've done quite a bit of work on this thing here at work, but I'm interested in pulling that out into a standalone library so I can open source it
08:59RickInGAI keep reading articles about using GPUs. Anyone know if Clojure can take advantage of heterogenius systemS?
09:07clgvRickInGA: si there a java for GPUs?
09:08RickInGAI don't know
09:08clgvafair I doubt that, since GPU computing is quite special
09:08llasramhttp://code.google.com/p/javacl/
09:08clgvonly dialect for a compiler?
09:08clgvah wrapper to opencl right.
09:09RickInGAMicrosoft is pushing AMP as a way to write C++ for gpu's, and they are saying that right now most code using gpus is in C
09:09clgvI saw some CUDA stuff last year.
09:09RickInGAso the fact that a methodology for C++ is just being developed, or has just been developed, makes me think probably nothing else does it yet.
09:09clgvIt was C++ as far as I remember
09:10lucianthere was an example of compiling a small subset of clojure to shaders
09:10luciantheoretically it should be possible to write an OpenCL DSL
09:11clgvCLJ-GPU? ;)
09:11RickInGAis OpenCL just drawing stuff?
09:11clgvno that OpenGL ;)
09:11lucianRickInGA: OpenCL is just computing stuff
09:12RickInGAah, wow
09:13RickInGAhehe, now that I see that it is possible, I am confronted with admitting I haven't the slightest idea what I will do with it :)
09:14clgvRickInGA: then let me tell you that you might be surprise how few that actually is ;)
09:16RickInGAIt is a fun question... just what sort of software could possibly use a 100 core system?
09:16RickInGAwe are going to have the hardware soon, but what are people going to do with it.
09:17RickInGAright now I am trying to learn HOW to do it. I will figure out the WHY somewhere along the way :)
09:23clgvRickInGA: the problem with GPU programming is that you dont have just 100 normal cores. they are very specialized and thus limited compared with normal CPUs
09:24lucianthere certainly are things we could do if we could easily run a nice language on our GPUs
09:24lucianmostly numerical, though
09:24RickInGAYeah, I know the C++ libraries put a lot of restrictions on what can be done
09:24clgvI guessed that ;)
09:25RickInGAI was jus thinking that one of Clojure's big selling points is the way it handles concurrency
09:25lucianRickInGA: so would a Clojure library, i would be a small incompatible subset of clojure
09:25lucianRickInGA: this would be possible because of homoiconicity, not STM
09:26RickInGAok, how about this sort of setup. a clojure app that runs on the cpu, and when it can benifit from it, it dispatches work to a librarry running on the gpu
09:27RickInGAit is kind of foggy in my mind, but I think i am starting to get it :)
09:27lucianhave you ever used vectorization libs, for things like SSE?
09:28RickInGAno, I haven't. Think that would be a good place for me to learn more?
09:28lucianyou'd say something like (with-gpu (add 2 [1, 2, 3])) and you'd get [3, 4, 5]
09:28lucianpretty much all operators would be on matrices
09:29RickInGAIt is such a cool time to be a developer
09:33clgvhm yeah I guess 1700 would have sucked to be software developer ;)
09:33RickInGAhaha
09:38foodooRickInGA: [on what to do with 100 cores:] solving differential equations
09:42RickInGAthe 7 languages in 7 weeks book has a Sudoku solver in Prolog. In 4 lines of code you specify that 1: Only digits 1-9 are acceptable values, 2: values across have to be unique, 3: values down have to be unique and 4 each of the 9 3 by 3 squares have to have unique values.
09:42RickInGAIt is up to the prolog 'compiler' to find the answer.
09:42lucianRickInGA: sure, but that's a special, limited case
09:42RickInGAI believe it does a depth first search on all possible solutions until a match is found
09:42lucianoften it turns out that explaining the problem in that much detail is similar effort to solving it by other methods
09:43lucianbut yeah, prolog is cool
09:43RickInGAthat is something that could work on a heterogeneious (how do you spell that!) system
09:43lucians/ei//
09:44RickInGAlike you say, very limited application, but cool none the less
09:45RickInGAI want to check out core.logic. I think the sudoku app would be a fun one to play with.
09:53gtrakhave there been any newer overtone videos lately?
09:54RickInGAI saw that someone ported Overtone to F# and called it Undertone :)
09:54gtrakha
09:54samaaronRickInGA: haha, really?
09:54samaarondo you have a link?
09:54RickInGAyeah, one sec
09:54samaarongtrak: no, there haven't been any newer overtone demo vids - just the interview i did with FLOSS
09:55gtrakah ok
09:55gtrakhopefully confreaks gets their act together with the conj one :-)
09:55samaarongtrak: unfortunately, I'm still dealing with my step-father's suicide
09:55samaarongtrak: it's rough times for me atm
09:55samaarongtrak: yeah, totally - it's been ages since the conj
09:55samaarongtrak: it would be nice to have the presentation out there
09:55RickInGAhttp://strangelights.com/blog/archive/2012/01/27/undertone-ndash-programmable-music-in-f.aspx
09:55gtraksamaaron: ah, I'm sorry to hear that, but I really enjoyed your talk :-)
09:57samaaronRickInGA: awesome - thanks!
09:57RickInGAsamaaron: sorry to hear about your loss
09:57fdaoudsamaaron: sorry to hear that, my sympathies to you.
09:57samaaronRickInGA: yeah, i am too. It's just the suddenness of it which is the hardest to deal with.
09:58samaaronit's totally affected my productivity
09:58samaaronlife is very fragile - and we should enjoy it to the very best of our abilities!
09:59samaaronfdaoud: thanks :-)
09:59samaaronstill, people's continuing enthusiasm with Overtone is really helping me along
10:00samaaronyou should read http://twitter.com/overtone for some of the wonderfully positive things people have been saying
10:01RickInGAI haven't checked it out yet. I heard your interview on mostly lazy a couple of weeks ago, I do want to try it out
10:02samaaronRickInGA: have you seen the FLOSS interview?
10:02samaaronhttp://twit.tv/show/floss-weekly/197?page=1
10:02RickInGAThe f# article made it sound like using overtone was a help to learning clojure
10:02samaaronRickInGA: yeah, i think Overtone is a great way of learning Clojure - learning through doing
10:03RickInGAso to use overtone I will write clojure expressions?
10:03samaaronRickInGA: of course :-) *everything* is in Clojure
10:03clojurebotRoger.
10:03RickInGAAwesome, this is one developer who needs his own theme music!!
10:06samaaronhaha
10:08samaaronRickInGA: so the top-level overview is that you design synths using Clojure macros. These then compile down to special binary form which the sound synthesis engine SuperCollider understands. SuperCollider then reifies these designs meaning that they can be triggered and controlled. This triggering and controlling is done via normal Clojure fns.
10:09RickInGAI am just starting to watch the video now, I will be downloading soon
10:09RickInGAprobably have a barrage of questions for you tomorrow :)
10:10samaaronRickInGA: you're welcome. You're free to pester me on freenode. I also hang out in #overtone. Also, the Overtone mailing list is a great place for longer questions
10:11RickInGASince I have started playing with Clojure, I keep finding more and more fun ways to not get any work done.
10:12clgvRickInGA: lol, I hoe you'll also find the complement ;)
10:12samaaronRickInGA: just redefine your notion of 'work'
10:14RickInGAspeaking of complement... I was on 4clojure yesterday... trying to omit every nth occurrence. I did filter(complement (= 0 (rem ndx n))) (ok, the vars are tough to follow).. but anyway, compliment didn't work and not did.
10:14RickInGAhow are complement and not different?
10:15RickInGAsamaaron: yes, I am not playing or wasting time I am "learning"... its an investment, right?
10:15samaaronRickInGA: always :-)
10:15samaaronnever close your mind
10:16samaaronplay is very important too though
10:17RickInGAspeaking of "play" does anyone know anything about less conf? I saw the Relevence guys said they were goign to be there, so I wondered what it was.
10:17RickInGAAnd if you go to the less conf site, they wont tell you
10:18RickInGAtheir videos are pretty good though :)
10:19RickInGAI am thinking about going, just because it is in Atlanta, which means I don't have to pay for lodging, but I really have no idea what it is
10:19RickInGAhttp://lessconf.lesseverything.com/
10:21RickInGAah, there is an emacs plugin too
10:22noidiRickInGA, complement returns a function that's the opposite of the given predicate
10:22noidi,((complement =) 2 2)
10:22clojurebotfalse
10:23RickInGAnoidi: I was trying to filter a sequence. I wrote the code that would only take every third item (= 0 (rem ndx 3)).
10:24RickInGAI thought wrapping that in complement would exclude every third item, but instead I got the whole sequence. wrapping it in not gave me what I expected
10:25noidinot operates on boolean values, returning their negation, while complement works on functions returning boolean values, returning new functions which call the original function and negate the return value
10:26clgvhow about not= ;)
10:26RickInGAhah, didn't look for not= that would work too
10:27fdaoudcemerick: I know it's not on you but-- has your book really been delayed again, this time until end of April? Now it's not funny anymore. :(
10:27fdaoudwww.amazon.com/Clojure-Programming-Chas-Emerick/dp/1449394701#productDetails
10:27cemerickholy shit!
10:28cemerickahem. Sorry.
10:28cemerickfdaoud: No, I hadn't seen that.
10:28fdaoudcemerick: no don't apologize, I'm glad you're as "wtf?" as I am..
10:31TimMcRickInGA: Wow, reading the blog on lesseverything makes me want to punch a kitten.
10:32RickInGAhah, I didn't look at the blog
10:32TimMcDon't, it's terrible.
10:32RickInGAI liked the video about who is speaking
10:32RickInGAI haven't decided if it is a really cool conference, or a way to get people to fork out a bunch of money to hang out and eat pizza for 2 days
10:33clgvthere is a blog?
10:34TimMcYeah, apparently written by two angry, illiterate rhinoceri.
10:34RickInGAnoidi: I don't know why I am having so much difference grasping why complement didn't work for me, but not did. Is this the right way to think about it, complement works on a function and not works on an expression?
10:35clgvTimMc: hmm guess I found it as well
10:35TimMcclgv: I read the grammar post and skimmed the REST post.
10:36TimMcRickInGA: Right.
10:36RickInGAthx
10:37TimMcRickInGA: You might say that 'complement is the HOF version of 'not
10:37noidiRickInGA, if you want the opposite of a boolean *value*, use not. if you want the opposite of a predicate *function*, use complement.
10:37RickInGAHOF = higher order function?
10:37TimMcyeah
10:37TimMcnoidi: That's a great way of putting it.
10:38wiseenis there a clojure reader/writer library that will serilaize to clojure data, for clojure and clojurescript ?
10:38TimMcwiseen: pr-str
10:38TimMcThat's a function, not a library.
10:39RickInGAnoidi: thanks, I will try to remember it that way.
10:39TimMcwiseen: and read-string to get it back (look up *read-eval* before using it)
10:39RickInGA(though, repl makes memory less critical, hey that didnt work try the other one)
10:40wiseenTimMc, is it consistent across clojure and clojurescript ?
10:41wiseeneg. if I send "#user.Foo{:x 1}" to clojurescript - does it have the same reader syntax ?
10:42RickInGA"overtone wants to make electronic music a performable art" -- WOW
10:43samaaronRickInGA: yep, that's the goal
10:43samaaronRickInGA: so everything needs to be achievable live and in real time
10:44raekwiseen: for all "normal" data (vectors, sequences, maps, strings, numbers, keywords, etc) it is definitely consistent
10:44samaaronRickInGA: where did you find taht quote?
10:44raekI'm not sure about records
10:44wiseenraek, and defrecord ?
10:44RickInGAyou are blowing my mind. I can think of non-programming friends, barely programming friends, and only know visual foxpro friends, that I am going to have to show this to
10:44samaaronRickInGA: haha, excellent. Mind-blowing is a hobby of mine
10:44raekrecords are a bit special in that they are data + type
10:45RickInGAsamarron: Probably not an exact quote, but you said it in the twit.tv link you provided. About 12 minutes in.
10:45RickInGAgo to 11:45, and you may have to watch for 30 second
10:45samaaronRickInGA: ah cool. It's definitely the kind of thing I would say :-)
10:46RickInGAare you going to clojure west?
10:46RickInGAnm
10:46RickInGAI remembered, you are one of the presenters
10:47RickInGAhah, the host of the interview is pretty good "I like the idea of using emacs to do all that. I like to think that Jimi Hendrix would have been a wizard on emacs"
10:47TimMcYou can't spell "juxt" without "Jimi Hendrix", and also some other letters.
10:49RickInGAsamaaron: I hope I am not skipping ahead, you have this thing called a monome that has lots of buttons on it. Does each of the buttons fire an event.... kind of like joystics with macro buttons for gaming?
10:50metajack1RickInGA: The monome speaks OSC protocol, so you essentially get a udp packet for every button press and release, etc.
10:51samaaronRickInGA: that's exactly the way my monome lib presents to Clojure - you write handlers which are called on trigger (on/off) events
10:51metajack1you can also send light up messages to rows, buttons, columns, or various squares of grid
10:51samaaronmetajack1: actually, the monome only speaks serial
10:51samaaronmetajack1: however, you can run a separate process which will talk serial and present OSC
10:51metajack1samaaron: but everything runs off of the OSC udp side. nothing talks directly to the serial part except monomecontrol right?
10:51samaaronmetajack1: or you can use my monome lib which talks directly to the serial protocol
10:51metajack1(i have a monome)
10:51metajack1ah.
10:52RickInGAbut a button could be a note, or a chord or a melody... and if buttons are notes, then you can press a few at once for a chord
10:52metajack1i ahve previously only used it from Reaktor and Max
10:52samaaronmetajack1: cool. so the separate process thing was called MonomeSerial if I recall correctly
10:52metajack1samaaron: yeah, that's right.
10:52samaaronmetajack1: so with my monome lib, you don't need MonomeSerial
10:52metajack1i also have the launchpad which is similar but speaks midi. not as responsive as the monome if you have a lot going on
10:53samaaronmetajack1: Phil Potter is working on making my monome stuff work with the launchpad
10:53metajack1is there a technical reason to skip the monomeserial thing?
10:53metajack1or does that only exist because Max doesn't speak serial?
10:53RickInGAcan you have a button that represents a tempo, so if I press button one, it is a melody at 80 bpm, but have another button that multiplies any tempo by 1.5, so both keys give the same melody played at 120bpm?
10:53samaaronmetajack1: no technical reason other than i wanted to remove deps
10:54samaaronRickInGA: yep, all doable :-)
10:54RickInGAIf I had a job and musical ability, I think I would quit my job and play with overtone all day!
10:54samaaronRickInGA: that's exactly what i did for a year :-)
10:55TimMcRickInGA: You're half-way there already!
10:55RickInGAhaha, true!
10:55samaaronRickInGA: and i didn't have any musical ability
10:55samaaronso i think you're all the way there ;-)
11:01samaarondoes anyone know how i might discover the escape sequence for specific key combinations?
11:01TimMcsamaaron: Context?
11:01samaaronTimMc: so in emacs, when I hit C-M-l emacs doesn't register it
11:02samaaronyet when I do C-M-SHIFT-l, emacs registers it as C-M-l
11:02TimMchaha, what
11:02samaaronwhich makes me wonder if my terminal is doing the right thing...
11:02samaaronso, my terminal (iTerm2) allows me to register escape sequences for key combos
11:03TimMcsamaaron: Try using ESC for meta, see what happens: Esc, C-l
11:04samaaronTimMc: that works fine
11:05gtrakprogramming and music feel like the same mental process to me, reasoning about structure, trying to maximize aesthetics, doing one well helps the other
11:07gtrakI think overtone makes the connection more obvious :-)
11:08samaarongtrak: that's exactly how i feel too :-)
11:10gtrakit's interesting stuff
11:11samaarongtrak: thanks :-)
11:12RickInGAI need to head out. Thanks all for the good answers. ANd thanks samaaron for the new toy :)
11:12TimMcsamaaron: So Emacs is not at fault.
11:14samaaronTimMc: yeah, i didn't think it was Emacs' fault
11:27TimMcamalloy_: While grepping my logs for something else, I noticed you said "i just wish people would stop going map->seq->map, which gets you the worst of both worlds performance-wise" -- were you talking about the general case of mapping over the keys and values of maps, or was this likely taken out of context?
11:42axle_512_(+ 2 2)
11:42clojurebot4
11:43clgv(* 2 2)
11:43clojurebot4
11:44axle_512_(pow 2 2)
11:44dgrnbrg,(pow 2 2)
11:44clgvyeah that one is missing^^
11:44clojurebot#<CompilerException java.lang.RuntimeException: Unable to resolve symbol: pow in this context, compiling:(NO_SOURCE_PATH:0)>
11:44axle_512_dang
11:48TimMc(+ 1 5) ; axle_512_
11:48clojurebot*suffusion of yellow*
11:48clgvhmm the next operation fits as well 2!!2=2^2 :D
11:48TimMcYou have to use the eval trigger, \,
11:49clgv,(pow 2 2)
11:49clojurebot#<CompilerException java.lang.RuntimeException: Unable to resolve symbol: pow in this context, compiling:(NO_SOURCE_PATH:0)>
11:49clgv;)
11:49axle_512_Why does the arithmetic operator not require the veal trigger, but pow does?
11:49TimMcamalloy_: It's a factoid Clojurebot has stored, that happens to be correct.
11:49axle_512_veal trigger, that is.
11:49TimMcugh, sorry ^ axle_512_
11:50axle_512_ah, ok
11:50axle_512_,(+ 1 5)
11:50clojurebot6
11:50TimMcclojurebot: (+ 2 3) is 42
11:50clojurebot'Sea, mhuise.
11:50TimMc~(+ 2 3)
11:50clojurebot(+ 2 3) is 42
11:50axle_512_got it, thanks Tim
11:52TimMcclojurebot: forget (+ 2 3) |is| 42
11:52clojurebotI forgot that (+ 2 3) is 42
11:52TimMcActually, that might not be part of the factoids module. It's a pretty weird bot.
11:52axle_512_haha
11:54TimMclazybot is faster, but doesn't allow certain constructs, such as 'binding and 'resolve (for security reasons)
11:54bleakgadfly,(/ 1 998001)
11:54clojurebot1/998001
11:54bleakgadfly,(/ 1 998001.0)
11:54clojurebot1.002003004005006E-6
11:55axle_512_TimMc: how do you interface with lazybot?
11:56TimMcaxle_512_: &(+ 2 2) at the beginning of a line, ##(+ 2 2) in the middle (although that only triggers for parenthesized forms)
11:56lazybot⇒ 4
11:56cemerick,(with-precision 500 (/ 1 998001.0M))
11:56clojurebot0.00000100200300400500600700800901001101201301401501601701801902002102202302402502602702802903003103203303403503603703803904004104204304404504604704804905005105205305405505605705805906006106206306406506606706806907007107207307407507607707807908008108208308408508608708808909009109209309409509609709809910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113...
11:56cemerickbleakgadfly: ^^
11:56axle_512_&(pow 2 2)
11:56lazybotjava.lang.RuntimeException: Unable to resolve symbol: pow in this context
11:57axle_512_TimMc: ok, thanks
11:57TimMcaxle_512_: And there are some $commands too:
11:57TimMc$findfn 2 3 8
11:57lazybot[]
11:57TimMc^ no pow, you'll have to use Math/pow
11:58clgv&(Math/pow 2 2)
11:58lazybot⇒ 4.0
11:58axle_512_TimMc: Can you defn to create your own functions?
11:59TimMcNot in a sandbox.
11:59TimMcYou can use 'let and 'letfn, though.
11:59axle_512_can you use lamdas?
11:59TimMcabsolutely
12:00TimMcThe problem with 'defn is the 'def bit.
12:01axle_512_&(filter (fn [x] (> x 0)) [-1 0 1 2 3])
12:01lazybot⇒ (1 2 3)
12:01axle_512_cool
12:03TimMc&(map #(* 5 %) (range -1 4))
12:03lazybot⇒ (-5 0 5 10 15)
12:12bleakgadflyIf I want to create a library to work both on Clojure for JRE and Clojure for CLR, AND use native bindings in the same library: Is it possible to figure out, in Clojure, if the library is being run on JRE or CLR and choose to execute the part of the code which is written for the platform the library is being run for? Or would I have to create an own library for CLR and one for JRE? I'm thinking
12:12bleakgadflysort of like the #ifdef you can find in some C headers that are platform-dependent.
12:13bleakgadflys/the library is being run for/the library is being run on/
12:19TimMcbleakgadfly: With on-the-fly compilation, you can have macros check the current runtime and set up the environment as appropriate.
12:28jeremyheiler1bleakgadfly: I haven't thought about this too much, but I imagine having three projects: one of them pure clojure code, and then depend it from a java version, and a clr version, and add the platform specific stuff. you can hoose your poison for how you want to abstract it, though. In either case, it would be interesting to see how you make out with whatever solution that ends up working for you.
12:33Bronsais there a funciton that returns [(take-while pred coll) (drop-while pred coll)]?
12:35VinzentBronsa, split-with?
12:35Bronsathanks.
12:49jsabeaudryYou can use defn- for functions that should not be exported. Is there something similar for constants and macros?
12:51Vinzentjsabeaudry, use :private metadata
12:52jsabeaudryVinzent, alrighty, was curious to see if there was something less verbose that already existed, thanks!
12:53Vinzentjsabeaudry, defmacro- and def- was somewhere in contrib, but it looks like they won't be included in core (maybe even defn- will get deprecated someday)
12:55JohnnyLwhat's the sense of having [] over ()?
12:56VinzentJohnnyL, [] is an empty vector, () is an empty list
12:57TimMcand you usually want vectors
12:57jeremyheiler1JohnnyL: Can you provide more context, unless Vinzent answered your question.
13:04edwAnyone here deploying to Heroku? Is there a way to speed up deploys? 'lein deps' is making incremental development deeply painful.
13:07TimMcedw: I think I saw some kind of cure for that...
13:12technomancyedw: I'm working on a way to get dynos to support swank/nrepl connections so you can do development more interactively
13:12technomancydoesn't help when you need to add/remove deps of course
13:12technomancythough your ~/.m2 should be cached in between deploys
13:21jcrossley3technomancy: is it not possible to run (swank.swank/start-server) on an app deployed to heroku?
13:22cemericktechnomancy: BTW, waiting on Meikel for a patch containing his bencode impl at the moment. nrepl-over-http was a snap, though some thought will need to go into the correspondence (or not) of HTTP sessions to nrepl sessions.
13:23bartjI would like to parse HTML DOM to compare HTML nodes
13:23technomancyjcrossley3: it is possible, but right now the routing mesh only routes HTTP requests, not raw sockets. we are working on a raw TCP router, but it's not ready yet.
13:23bartjon the looks of it, Enlive does not like like the right library
13:23bartjcan someone please suggest an option ?
13:24technomancyjcrossley3: even with the TCP router, each process can only listen on a single port, so your swank server process couldn't also respond to HTTP requests.
13:24jcrossley3technomancy: i was *JUST* about to ask that. :)
13:24TimMcbartj: Enlive scrapes HTML into a pretty regular data structure, what's wrong with it?
13:24technomancyjcrossley3: my plan is to get it to make an outbound SSH connection to a proxy server that can reverse-tunnel
13:25Vinzentbartj, standard clojure xml tools + some java html parser lib
13:25technomancycemerick: yeah, really looking forward to trying that out.
13:25JohnnyLjeremyheiler: what makes [a b] in use rather than (a b) <--clojure newb
13:25bartjscraping assumes you *know* the structure of the HTML page before hand
13:26bartjbut, what if you want to parse it, get the first child, sibling, descendants, etc.
13:26bartjwhich led me to conclude that it might not be what I need
13:26jcrossley3technomancy: so with the proxy server, that preserves the HTTP port for the process, right? so i could do both?
13:27jeremyheiler1a vector is constant time look up and you append things at the end. a list is linear lookup, and appends things at the beginning.
13:27jeremyheiler1JohnnyL: ^
13:27technomancyjcrossley3: yup
13:27jcrossley3cool
13:28cemericktechnomancy: right now, I just have a ring-suitable handler fn that does what seems like a sane transformation from HTTP req -> nrepl req -> HTTP response. Some thought will need to go into figuring out the best HTTP representation and maybe "standard" routes so non-Clojure tools can have a shot at using the endpoint sanely.
13:29JohnnyLjeremyheiler: ok
13:29technomancycemerick: is this public anywhere?
13:29JohnnyLjeremyheiler: are vectors hashes?
13:30jeremyheiler1JohnnyL: Also, vectors are generally preferred because by default lists will be invoked as a function call unless quoted.
13:30berealHi. what is fn*, please ?
13:30jeremyheiler1JohnnyL: vectors are more like indexed arrays (at face value)
13:30berealas in the output of (macroexpand '(fn [] 1))
13:31cemericktechnomancy: not yet; blocking on a patch to get https://bitbucket.org/kotarak/wire into nREPL w/ some fixes (can't have outside deps in contrib). Shouldn't be long, last I heard.
13:31jeremyheiler1bereal: it's an internal function used by clojure as it's bootstrapping itself, i believe.
13:32technomancycemerick: cool; let me know once it's ready
13:32berealjeremyheiler1: aha, so it's not useful for a regular coder
13:34bartjTimMc, do you concur ?
13:37TimMcsorry, working atm
13:40TimMcbartj: OK, caught up. No, Enlive parses the whole page and hands it to you as a DOM tree.
13:40TimMcYou can run selectors on it.
13:41jeremyheiler1bereal: Actually, looking at the code, I think fn* is the function that internally represents fn, which is a special form.
13:44bartjI am unable to do any searches on Google for enlive related stuff. eg: [clojure enlive dom tree]
13:45bartjthe only stuff Google returns is clojurescript related. Bah!
13:45bartjand even "-clojurescript" doesn't lead anywhere
13:47TimMcYou may want to use verbatim search, which is their new option to replace +
13:47JohnnyLthanks jeremyheiler.
13:48bartjTimMc, do you have any references/code samples ?
13:48TimMcbartj: Sort of -- it doesn't use Enlive for what you want to do, probably. https://github.com/timmc/seqs-and-colls/blob/master/src/seqs/core.clj
14:09gfredericksI'm trying to learn enlive...what select would I use for "all p tags that come after h2 tags"?
14:10gfrederickss/select/selector
14:14amalloyTimMc: i'm mostly echoing hiredman's objection, that if you are treating a map as just a sequence of k/v pairs, you're spending cpu time and cluttering up your source code by converting it to a sequence, then back to a map, over and over as each step of your application says it "needs" a map but actually treats it as a seq
14:15amalloybetter to do as much transformation as you can on the k/v pairs, and slam it back into a map only when code you don't own finally needs a map
14:15dnolengfredericks: not sure if you can get just the p tags, but you can definitely get a range h2 p
14:17TimMcgfredericks: In CSS, that would be something like h2 + p or h2 ~ p
14:18gfrederickshmm
14:18gfredericksI was trying things like [:p :> :h2]
14:18gfredericksbased on browsing the source code
14:19gfredericksthe function called "left" sounds related based on its docstring
14:22TimMcgfredericks: > is the child selector
14:43technomancytrying to track down a leiningen bug; does anyone know of a :type "pom" dependency I could use to test?
14:49fliebelHey awesome community, long time no see
14:50mrb_bkleiningen question: i'm trying to use the edge checkout of overtone in my project. i symlink to the project directory from /checkouts, and leave overtone in the project.clj
14:50mrb_bkbut it's forcing me to use a version number -- what do i use?
14:51mrb_bkor do i not have to put overtone in the project.clj?
14:51samaaronmrb_bk: putting overtone in project.clj shouldn't make a difference
14:51technomancywhatever the newest published version of overtone is
14:51samaaronyoru checkout dir should take precidence
14:52technomancyno, you need it in project.clj; otherwise you won't get deps
14:52technomancycheckout dependencies aren't transitive
14:52mrb_bktechnomancy: whatever the most recent version # on clojars is?
14:52technomancyshould be
14:52samaarontechnomancy: i still haven't switched from cake, so i'm still unsure of the process of doing this with lein
14:53mrb_bkokay i'll try that again, before it seemed like it wasn't actually taking precedence
14:53technomancymrb_bk: whoever checks out your project should be able to make it work with the version in project.clj; checkout deps are only there for your convenience
14:53samaaronbut in cake you can specify the dep in project.clj but that is overridden if you put a project dir in the classpath
14:53technomancymrb_bk: if you need to check which is taking precedence, you can inspect "lein classpath"
14:53mrb_bktechnomancy: that's interesting, but doesn't it make sense to be able to specify edge code?
14:53mrb_bkfor example if certain examples won't work in the published version
14:54technomancymrb_bk: then you'd want a snapshot
14:55samaarontechnomancy: so when i'm hacking overtone I use a scratchpad project which never gets shared with others
14:55mrb_bktechnomancy: sure, that makes sense
14:55technomancyif the project isn't publishing snapshots frequently enough you can always locally do "lein install" from your checkout dir, but that is a breakdown of the normal process; it's not the usual case
14:56samaaronthe aim being to be able to hack on a dep of the scratchpad project (overtone) without having to worry about teaching the scratchpad project about the exact specifics of the version of overtone i'm working with
14:57technomancysamaaron: so you want the dependencies of the checkout dep to apply transitively?
14:57mrb_bktechnomancy: thanks a lot! it seems like the classpath has the dir of my checked out version, but the published jar is also there
14:57samaarontechnomancy: i'm unsure of what you specifically mean by "transitively" in this context
14:58technomancysamaaron: if "scratchpad" has overtone in its project.clj, overtone's dependencies come in via overtone's pom. you have overtone as a checkout dependency in addition to a regular dependency, and that should give you both overtone's dependencies as well as its source straight on the classpath.
14:59technomancybut having it as a checkout deps *without* putting it in project.clj won't work because overtone's deps won't be visible to scratchpad
14:59samaarontechnomancy: does that give me the source as a git checkout?
14:59technomancyright
14:59samaaronok cool
15:00samaaronso a checkout dependency is a git uri?
15:00technomancyno, it's a checkout
15:00amalloyit's just a directory
15:00amalloyyou point it at your existing git checkout (usually with a symlink)
15:00technomancycd scratchpad; mkdir checkouts; cd checkouts; git clone git@github.com/overtone/overtone.git
15:00technomancy(or symlink)
15:00samaaronok, and i choose how to populate that directory
15:00mrb_bktechnomancy: should the other jar not be in that classpath? or should it
15:01technomancymrb_bk: fewer pronouns please? =)
15:01mrb_bktechnomancy: haha sorry
15:01mrb_bktechnomancy: the overtone 0.6.0 jar is showing in the classpath, along with the directory i symlinked to in checkouts
15:01mrb_bktechnomancy: lein classpath that is
15:01samaaronmrb_bk: which appears first?
15:02mrb_bksamaaron: checkouts
15:02technomancymrb_bk: yeah, as long as the checkout is first, it should "win"
15:03samaaronsounds like a RACE!
15:03ckirkendallacagle: ping
15:03mrb_bktechnomancy: yay
15:03samaarongo checkout!
15:05mrb_bksamaaron: okay now i'm getting an error FileNotFoundException Could not locate seesaw/core__init.class or seesaw/core.clj on classpath: clojure.lang.RT.load (RT.java:430)
15:07samaaronmrb_bk: sounds like a dep issue - I'm assuming the deps in the checkout of overtone edge don't match overtone 0.6
15:07mrb_bkyeah :/
15:07mrb_bktechnomancy: any thoughts? or is this a lib issue?
15:08samaarontechnomancy: what's the lein-idiomatic solution for dealing with a checkout dep with different deps to the released jar?
15:09technomancysamaaron: I'd recommend pushing a new snapshot whenever your deps change
15:09technomancysnapshots are cheap
15:09jondot2hi guys. trying to make an HTTP get, should i go with whats in contrib or there is the way to stay in core for this?
15:09samaaronmrb_bk: i usually circumnavigate that problem by just hacking in the different deps to my scratch project's project.clj
15:09samaarontechnomancy: sounds sensible
15:09mrb_bkah, it works after 'lein install'
15:09brehautjondo2: ideally you want clj-http, otherwise you can just stick with java.net.URL (which is crappy)
15:09mrb_bkoh wait no it doesn't
15:09mrb_bkhaha
15:10edwtechnomancy: You mentioned 'my' ~/.m2; does my Heroku account have one of those?
15:10mrb_bksamaaron: can haz snapshot?
15:11samaaronmrb_bk: working on it right this moment - had to shake the cat of my chest
15:11samaarons/of/off/
15:11technomancyedw: yeah, it's cached in between builds, but I'm a bit fuzzy on when the cache gets cleared.
15:11mrb_bkhahah thanks
15:11mrb_bkthe cat of your chest?
15:11samaaronyep, my cat
15:11mrb_bki hope the dog of your head isn't scaring her too much
15:11samaaronluckily the dog is away for a week
15:11technomancyedw: I have seen a few cases where the cache isn't being respected; if you have a repeatable case of this I could take a look.
15:12johncourtlandhas anyone had (proxy) throw ClassCastException: clojure.asm.Type cannot be cast to clojure.lang.IFn in clj 1.3?
15:12jondot2so lein is using maven to handle the heavy lifting?
15:12edwHmm. I'm inquiring over on #heroku.
15:12johncourtlandi have no idea how it gets in that state
15:13technomancyedw: don't bother; that channel is a wasteland. =(
15:14technomancyhalf the traffic is that stupid broken bot announcing itself over and over and the other half is rails questions
15:14edwHey, I'm actually getting a human who works there checking with their Java dudes. A first time for everything!
15:15muhooi wouldn't be surprised if 90% of heroku apps are rails
15:15edwGiven that up until 3-6 mo ago, 100% were RoR...
15:16technomancyedw: I need to grab lunch in a few, but give me a ping later if you haven't resolved the caching issue.
15:16jsabeaudryIs keep-indexed the most idiomatic way to keep every second value of a sequence? (keep-indexed #(if (odd? %1) true nil)) [1 2 3 4])
15:17edwtechnomancy: Thank you. Will do.
15:18brehautjsabeaudry: take-nth
15:18brehaut,(take-nth 2 (range 10))
15:18clojurebot(0 2 4 6 8)
15:18brehaut,(take-nth 2 (rest (range 10)))
15:18clojurebot(1 3 5 7 9)
15:19jsabeaudrybrehaut, Ah nice, thanks! That long keed-indexed line was suspicious :)
15:20johncourtlandis anything wrong with this (as a test)?: (proxy [java.lang.Object] [] (toString [] "proxy's toString"))
15:20amalloyjohncourtland: no, though i'd prefer reify
15:21johncourtlandi thought you could only implement interfaces/protocols via reify
15:21brehautjohncourtland: object is the exception
15:22johncourtlandok, good to know
15:22johncourtlandi'm actually having issues compiling clojure.logging from within a grails runtime
15:22johncourtlandit has a proxy to ByteArrayOutputStream in there
15:23johncourtlandand using clojure 1.3, i get that exception i asked about (ClassCastException: clojure.asm.Type cannot be cast to clojure.lang.IFn)
15:23samaarontechnomancy: what's the situation with lein 2.0? Is it on the immediate horizon?
15:23johncourtlandin 1.2 it works fine
15:23johncourtlandi have tried tracing code for days and i'm not seeing any reason that it should be trying to apply clojure.asm.Type
15:24johncourtlandso i tried that simple proxy and i get the same issue
15:26johncourtlandthe only thing i can think of is that the grails runtime is causing proxy to behave poorly, because it obviously works fine outside of grails itself
15:27cwardellHelp needed. I am trying to load a .clj file from within a java jar. I am getting an error: Could not locate Clojure resource on classpath. My call is just a RT.loadResourceScript(cljPath) - The cljPath is a string holding the path to a hello-world.clj relative to the jar file. Any ideas?
15:29hiredmanis the resource on the classpath?
15:30danlarkinohhhhhhh burnnnnnnnnnnnn
15:30hiredman~burn
15:30clojurebotPardon?
15:31cwardellyes
15:31muhoo&(def burn "ouuuch!")
15:31lazybotjava.lang.SecurityException: You tripped the alarm! def is bad!
15:31hiredman~burn
15:31clojurebotwhat
15:32cwardellthe resource is place on the class path with the other jar.
15:32muhooso does that error mean it can't locate Clojure (i.e. clojure.jar is not on cp), or that it can't locate the foo.clj file?
15:33muhooalso, wait a minute. clojure is compiled. why would it need a foo.clj file to run a clojure program from java?
15:33muhoowouldn't you just compile the clojure source, make a jar of the classes, and then use them like any other java classes (also including any deps in the cp too)?
15:34cwardellI believe it finds the clojure jar ok. That was assembled into my jar. It's the *.clj that I am trying to pull in at runtime
15:34jondot2whats an idiomatic way to update a single key of a hash within a hash ?
15:34muhoocwardell: and i have to wonder: why?
15:35jeremyheiler1jondot2: update-in
15:35cwardellI have a java app that I would like to extend with clojure.
15:35jondot2jeremyheiler, thanks - how would that relate to assoc?
15:35cwardellHaving end-users writing code in clojure and have my java app execute the functionality.
15:36muhoooh, ok
15:36jeremyheiler1&(update-in {:a {:b 1}} [:a :b] #(inc %))
15:36lazybot⇒ {:a {:b 2}}
15:36jeremyheiler1There's also assoc-in
15:36jondot2jeremyheiler i see. i would need assoc-in imho
15:38jeremyheiler1jondot2: This assumes that you know the path to the value, though.
15:38jondot2yes, i know it
15:38jeremyheiler1cool, just being explicit :-)
15:38muhoocwardell: i dunno. i'd guess treat it like it was a repl, use the regular (require ) stuff?
15:38jondot2yup, thanks!
15:40amalloyyou probably don't want assoc-in to do dissocs; update-in is more general and useful for this
15:41jondot2there are so many ways to shape the braces, i wonder if any LISP convention is valid for clojure ?
15:41amalloy&(let [m {:a 1 {:b 2 :c 3}]] (update-in m [:a] dissoc :c))
15:41lazybotjava.lang.RuntimeException: Unmatched delimiter: ]
15:41amalloy&(let [m {:a 1 {:b 2 :c 3}}] (update-in m [:a] dissoc :c))
15:41lazybotjava.lang.RuntimeException: Map literal must contain an even number of forms
15:41amalloy&(let [m {:a {:b 2 :c 3}}] (update-in m [:a] dissoc :c))
15:41lazybot⇒ {:a {:b 2}}
15:41jkdufairi'm having a problem with clojure-jack-in. "couldn't find project.clj". I'm in a dired buffer with a project.clj. Also lein swank seems to start up just fine
15:41cwardellok thanks muhoo
15:41edwjkdufair: Did you M-x cd to the dir?
15:42amalloyjondot2: you mean where to put the parens? that's more or less a solved problem
15:42jkdufairlemme try that
15:42edwOr M-x shell and cd there.
15:42jondot2i'm trying to mimick what other people do, so far i'm learning from nathanmarz' storm. he likes to leave the closing brace in case of let vertical to the indent.
15:42jondot2amalloy, yes
15:43jondot2my code looks like a wacky closing paren case.
15:43amalloymostly the answer is "let emacs do all the indenting; don't put trailing parens on their own line"
15:43jondot2in my case - i'm using vim
15:43edw"Now you have two problems."
15:43jondot2haha
15:43jeremyheiler1jondot2: Are you using vimclojure?
15:43jkdufairedw: alas, neither seems to have helped
15:43jondot2yes its starting to come to me that when i did scheme i never worried about this (was using emacs at the time). yes, vimclojure
15:44jkdufairany other ideas?
15:44amalloymy understanding is there are paredit-like features for vim that make this not-too-onerous
15:44TimMcamalloy: The one thing tha makes me want trailing parens on their own line is the cleanliness of the resulting diffs. :-P
15:44amalloyugh i know
15:44jeremyheiler1with you on that one TimMc... and just general code refactoring
15:44amalloyhow does refactoring enter the discussion at all?
15:45jondot2TimMc, i thought it is typically done for do like forms, where it is probably that people can add statements (side effects) vertically.
15:45RaynesThere is nothing in the world that would ever make me want to put closing parens on their own line.
15:45jeremyheiler1amalloy: eh, yank and put by lines (same reason as for diff)
15:45amalloysolution: never do that? use paredit to kill/yank balanced forms
15:46amalloyor one of vim's balanced-pair equivalents
15:46jondot2look here: https://github.com/nathanmarz/storm/blob/master/src/clj/backtype/storm/cluster.clj
15:47jondot2nathan typically leaves a trailing paren so that it will be convenient to add lines (without finding an splicing the correct paren)
15:47amalloythat style is not at all common. nathan can do what he wants, i guess, but most newbies doing that get taken to task
15:47jkdufairi also see that my emacs has no slime whatsoever. does that matter?
15:47jkdufairi just installed clojure-mode from marmalade and swank-clojure plugin for lein
15:47jkdufairi'm on cygwin
15:48jkdufairother pc with cygwin is ok as is my mac. looking thru buffers for more detail but nothing yet
15:48edwTimMc: wouldn't it be nice if we had a symbolic, not lexical, 'diff'?
15:48amalloyjkdufair: clojure-mode bundles its own version of slime these days
15:48amalloyso i don't think you need it, assuming you use clojure-jack-in
15:49ordnungswidrigedw: there is https://github.com/brentonashworth/clj-diff
15:49jkdufairok that's what i thought. any idea where else to look?
15:50amalloyhuh? look for what?
15:50jondot2is there any historical reason as to why parens should never be left on their own line?
15:51RaynesMy reason is simple: it is hideous.
15:52amalloyit's a line of vertical space wasted for no reason, and encourages bad habits like trying to visually match opening and closing parens
15:52jondot2to my fresh (read: newbie) eyes it looks practical and less error prone
15:52jkdufairok, strangely when i run emacs -nw, i get the following: no such file or directory, /cygdrive/e/dev/clojurecraft/c:/users/jase/.emacs.d/swank/slime-dbd975fa.el
15:52jkdufairwtf?
15:52jkdufairthis is as a result of clojure-jack-in
15:53mrb_bktechnomancy: that worked a treat, thank you!
15:53TimMcedw: Absolutely, I'd love structural diff.
15:53brehautjondot2: your text editor should support paren management for you. you shouldnt be counting them yourself.
15:54jondot2i see.
15:54brehautjondot2: once you learn the basics of structural editing (aka paredit) you dont want to go back to editing lisp as text
15:54jondot2i'll give it a try. is paredit a vim specific thing?
15:55emezeskejondot2: paredit is an emacs thing, but somebody created a vim plugin that does pretty much the same thing
15:57brehauttheres also support for it in CCW, the eclipse clojure support stuff
15:57jondot2ah. i see.
16:04jondot2how bad is it if i'm naming things with snake_case (and not hypen-case)?
16:04jondot2specifically, let variables
16:04brehautits pretty bad
16:04amalloyjondot2: someone will murder you in your sleep
16:04jondot2ah damn.
16:04brehautbest case: you're code will be treated like a leper
16:05jondot2well, is that true for hash keys as well?
16:05pjstadigjondot2: it's so ugly...why?
16:05amalloyyes, unless you're getting those hashes from some other language
16:05TimMcalso, extra shift key
16:05jondot2yea.. i'm replacing..
16:05pjstadigTimMc: yes, it's very annoying to type
16:05amalloy(eg, when you convert a java object to a hash and back, it's okay to use camelCase keys)
16:06TimMcso is Java
16:06TimMcBAZINGA
16:06pjstadigi think you mean clabango
16:06brehautthanks sheldon
16:06pjstadig~suddenly
16:06clojurebotBOT FIGHT!!!!!111
16:06pjstadig~suddenly
16:06clojurebotBOT FIGHT!!!!!111
16:06ordnungswidrigjkdufair: I got a similiar glitch with emacs and clojure-jack-in on windows. I do not use cygwin but emacs and leiningen jack-in disagree on my home directory.
16:06amalloyone thing that lisp has going for it is that there's actually a global style that people mostly agree on
16:07ordnungswidrigthus having c:/documents and settings/USER/.emacs as well as c:/documents and settings/USER/Local Settings/.emacs
16:07amalloycompared to the C-like languages, where every language has five prevalent styles, each with minor variations, that people fight over within the same team
16:07hiredmanI wrote this sweet function at work the other day called mirror, that given an object return an object that implemented ILookup and would get the values of all fields (even private ones) from the original object
16:07amalloyoh god, reflection pun?
16:08brehauthiredman: how dies that differ from bean?
16:08hiredmanso then you could (let [{x :somePrivateField} (mirror something)] ...)
16:08brehautjondot2: http://mumble.net/~campbell/scheme/style.txt
16:08hiredmanbrehaut: as far as I know bean doesn't access private fields, does it?
16:08brehauthiredman: oh right. of course
16:08jondot2brehaut, thanks i was actually looking for that, my memory fails me.
16:08pjstadighiredman: should have been called refraction instead
16:09amalloymagic-mirror
16:09hiredmanand actually I needed a bunch of private fields
16:10hiredman(let [{x :somePrivateField y :someOther z :andAnother} (mirror something)] ...)
16:14TimMcamalloy: No, just a joke about how terrible Java's so-called type system is.
16:14amalloyTimMc: i was referring to hiredman's name "mirror"
16:15TimMcah
16:23technomancysamaaron: the plan is to release a preview of lein2 for ClojureWest
16:23technomancyalthough it's starting to look like it might be ready earlier
16:24samaarontechnomancy: perfect - my plan was to not spend the time switching until lein2 was out
16:24technomancysamaaron: the main things blocking the preview is integration of the new repl and native-deps.
16:24samaaronso I only had to update all the Overtone docs once :-)
16:24technomancyonce Raynes lands native-deps you might be ready to roll
16:25samaarontechnomancy: great - I can also test the native-deps stuff with my monome lib
16:25technomancyright now all that stuff is commented out; Raynes volunteered to bring it back in line with 2.0 since I threatened to release the preview without it. =)
16:27technomancywe're also missing shell-wrappers, javac, and trampoline; those won't land till after the preview.
16:30samaarontechnomancy: what's the difference between compile and javac?
16:31technomancysamaaron: compile does Clojure AOT
16:31TimMccompile does AOT compilation on Clojure, right?
16:31technomancyin 1.x it implicitly called javac, in 2.x it's a bit different
16:31samaaronah ok :-)
16:32technomancyjavac can probably be addressed by just updating the plugin; it doesn't necessarily need to be fixed in lein itself
16:33samaarontechnomancy: does Leiningen's moustaches improve in 2.0?
16:33samaaronso/does/do/
16:33amalloytechnomancy: did lein ever solve the problem of co-dependency between java and clojure? eg, if you have some java code that depends on a clojure deftype you need to AOT-compile the deftype, then compile java, then do whatever else is left
16:34technomancysamaaron: actually the image on the new stickers are done from scratch since the old ones weren't high-res; I would say that they have a more regal shape to the nose.
16:34technomancymoustache remains about the same though. =)
16:34samaaron:-)
16:34samaaronit would be fun to see it grow as the tool matures ;-)
16:35technomancyamalloy: I told nathanmarz to go ahead implement that in a plugin, but he never did =)
16:36samaarontechnomancy: so what was it about the new stickers that you weren't quite happy with?
16:36technomancyI don't imagine it would be too tricky to just accept sequential :source-path/:java-source-path alterations
16:37technomancysamaaron: they have a transparent background
16:37samaarondidn't you expect that?
16:37technomancylooks fine on a white or metal laptop; not so hot on a black one
16:38samaaronah, so Leiningen fades into the black background
16:38technomancyI think I just didn't read through the printing order form or something
16:38samaarondid you want a white background?
16:39technomancyyeah, that's what the first run had
16:39technomancyand also what successive runs will probably have
16:39technomancysince I personally have a black laptop =)
16:39samaaroni definitely need to get my mitts on a few transparent ones then ;-)
16:39samaaronlimited edition!
16:39jsabeaudryIs it possible for a macro to expand to 2 sexps instead of 1?
16:40technomancyhehe
16:40ordnungswidrigjsabeaudry: wrap it in progn
16:40amalloyjsabeaudry: no
16:40technomancyit'll look fine on black if you put the sticker on a white mailing label or something
16:41jsabeaudryordnungswidrig, Doesn't really apply here, and you probably mean in do (i think prog is in common lisp
16:41jsabeaudryamalloy, alrighty, too bad thanks for the info
16:41amalloyi'm sure there's a simple way to do what you want to do, though
16:42amalloy(ie, you're attempting to solve an impossible subproblem isntead of a tractable real-problem)
16:43ordnungswidrigjsabeaudry: yes, it was common lisp.
16:45jsabeaudryamalloy, Yes, well two short macros are not much long to write than one short macro I guess :)
16:45jsabeaudryamalloy, I'm not really providing abstraction I'm DRYing
16:48ordnungswidrigis there a smart way to check a reader for more to come?
16:49ordnungswidrigis it safe for a pushbackreader to read and unread a single byte for this?
16:54technomancyanyone know of a dependency of :type "pom" I could test against for a Leiningen bug?
16:58TimMctechnomancy: That was discussed last week, I think. Let me check my logs.
17:01Raynesyaml.load(open(os.path.expanduser('~/.refh.yml')).read())['token']
17:01RaynesClojure has too many parentheses.
17:02gtrakwtf is that ruby?
17:02RaynesNo. Python.
17:02gtrakha, I actually know python
17:02TimMctechnomancy: [org.kohsuke/pom "2" :type "pom"] [javax.media/jai_core "1.1.3" :type "pom"] I think
17:02technomancyTimMc: thanks!
17:02TimMcDon't take my word for it.
17:05technomancyapparently eclipse freaks out if you have pom files in lib =(
17:05mabesdoes 1.3 world have something like re-gsub (http://clojuredocs.org/clojure_contrib/clojure.contrib.str-utils/re-gsub) ?
17:06amalloy &(doc clojure.string/replace)
17:07amalloy(there wasn't really any reason to use re-gsub in 1.2 either; it's a holdover from 1.1 i think)
17:08diginetso, I've heard clojure is the most "pure" lisp
17:08diginetor
17:09diginetthe most purely functional
17:09TimMcWho told you that?
17:09diginet(LispKit, and other notwithstanding)
17:09diginetpeople in #lisp
17:09mabesamalloy: thanks
17:09TimMcdiginet: Well, it does have that focus on immutability, so that's a +
17:09Raynes&(doc clojure.string/replace)
17:09lazybot⇒ "([s match replacement]); Replaces all instance of match with replacement in s. match/replacement can be: string / string char / char pattern / (string or function of match). See also replace-first."
17:10technomancyso... leiningen will place directories in lib/ on the classpath right now, sort of by accident
17:10diginetso, is it possible to write clojure code without side effects?
17:10technomancywould it be horrible to be stricter and only use files in lib/? if you need dirs on the classpath you should use :extra-classpath-dirs anyway
17:11TimMcdiginet: Sure. (+ 2 2) is probably simpler than you wanted, though.
17:11digineterr, what I mean is write anything non-trivial without side effects
17:11TimMcIf you start asking about I/O monads I'll have to refer you to a Haskeller.
17:12diginetno I know, I tried Haskell, but I found the syntax not to likable
17:12diginet*too
17:12technomancydiginet: it's customary and idiomatic to avoid side-effects in as much code as possible, but the compiler will not catch you if you accidentally sneak one in.
17:13TimMcAnything interesting involves side effects, or is a lib for something that does. The designers of Clojure put a lot of work into increasing the safety and reasonableness of how those side effects are coordinated.
17:13diginetwell, that sounds what I'm looking fo
17:13diginett
17:13diginet*for
17:13diginetobviously, at the end of the day, without side effects we just have a hot CPU, but minimizing them is preferable IMO
17:14mintsoupyou can write code like that in any language though
17:14TimMcmintsoup: I dunno, is it even possible in Java?
17:14diginetsure you /could/
17:14diginetI wouldn't want to necesarily
17:15TimMcI have definitely written Cons.java once or twice. It was natural for the task, but did not fit the language one bit.
17:20tjgilliesjust started seriously looking at clojure the other day. Now I think its the best language I've ever seen
17:21tjgillieshow are "lines of code" counted in lisps? or do you just say how many s-exp there are?
17:21TimMcSource lines. *shrug*
17:22TimMcI'd like to see a comparison of that with source forms, but I assume it's proportional.
17:22technomancygaming LOC can be done in any language
17:22tjgillieswhats a source line?
17:23TimMcLIne with sourc eon it.
17:23technomancyI guess the main problem with counting source lines in Clojure is that all the existing tools penalize you for docstrings.
17:23TimMcNot blank or only containing a comment.
17:23TimMctechnomancy: penalize?
17:23tjgilliesTimMc: thnx
17:26amalloyTimMc: they count as source lines. technomancy is minimizing, not maximizing
17:26SomelauwI think clojure is actually nice to read. When I see some common lisp, I really need to think for a while what it is saying.
17:26TimMcah
17:26technomancyI'm assuming they know how to skip docstrings in CL/Scheme
17:27technomancysloccount and friends
17:27TimMcamalloy: As opposed to the GitHub situation.
17:31luciansame happens in othe rlanguages with docstrings
17:32luciani tend to find that loc in a sanely-written program is directly proportional to the effort to read it
18:17dgrnbrgHow does slingshot interact with map's laziness? If I map a function that throw+s an object over a collection, is there a good way to ensure I can catch the error at the site that I declare write the map short of using doall?
18:20technomancydgrnbrg: slingshot doesn't really factor into it; any exception will be thrown when the seq is realized, not when it's created
18:20technomancyyou either need to perform the catch inside the function you're mapping or force it to be realized with a doall inside the appropriate try/catch
18:21dgrnbrgThanks, that's what I thought would be the case
18:21dgrnbrgI just wasn't sure if slingshot had other features to assist
19:11mabesis there a with-out-writer macro alternative in clojure 1.3?
19:12amalloy&(doc with-out-str)
19:12lazybot⇒ "Macro ([& body]); Evaluates exprs in a context in which *out* is bound to a fresh StringWriter. Returns the string created by any nested printing calls."
19:12amalloyor did you just want (binding [*out* (writer f)] ...)?
19:15mabes (binding [*out* (writer f)] ...)
19:15mabeswell, and it uses with-open to make sure the writer is closed
19:18phil___is there a way to let a defrecord implement IAssociative in clojure or is this cljs only?
19:21dnolenphil___: not necessary, Java has interface inheritance, defrecord implement IPersistentMap which extends Associative
19:23phil___dnolen: so should i just implement clojure.lang.Associative or must I do it for all classes like PersistentMap/Vector/Set etc?
19:23unlinkWhat is the Ring equivalent to SCRIPT_NAME/PATH_INFO?
19:23dnolenphil___: you can't implement it, it's been implemented for you.
19:23TimMcphil___: Aren't records already associative?
19:25phil___dnolen, TimMc: oh yes, indeed - ok, is there a way to overload assoc for a specific... idk entity (whatever that might be)?
19:26phil___i thought defrecords might be a good fit, but they are already maps
19:26dnolenphil___: you cannot change assoc for records
19:27phil___so either change it globally or dont change it at all?
19:27TimMcphil___: What's the bigger picture?
19:29phil___TimMc: i want to be able to store the "mutation history" of an object, i.e. if i do (def a (assoc b :key 5)) then a would be {:actions [[:assoc :key 5]] :entity b}
19:31TimMcHmm, I think storing it inside the object is a bad idea.
19:31TimMcI've implemented an undo/redo feature in a GUI program using two stacks of state, stored in refs.
19:32TimMcIf that's what you're up to, I can get you a GitHub link to that.
19:34_philTimMc: yes id like to take a look! what im after is having purely functional event handlers - i.e. if a handler is called it receives some old state, doest something to it in terms of assoc etc and returns a new state, which is then "run" by behind the scenes
19:35_phil-by
19:35TimMcYeah, store everything in a state map in a ref, then swap it in a transaction.
19:36_philyea, thats what id do, but id also like to know what the event handler changed... and short of diffing the old and the new state storing the "assoc history" is the only thing i can think of right now
19:37TimMcYou can assoc a key-value pair indicating what produced the new state.
19:38TimMcI'm a little reluctant to show you this code, since it was written when I was just learning Clojure, so it contains some fairly non-idiomatic code, like overuse of records instead of maps, and var naming...
19:38_philyes, but then the event handlers would need to use some custom assoc function and if they used the regular one then the changed state wouldnt be detected
19:38TimMchttps://github.com/timmc/CS4300-HW3/blob/master/src/timmcHW3/core.clj
19:39_philTimMc: doesnt matter, im after the bigger picture right now, not code style :)
19:39_philthx!
19:39pandeiro_phil: use an atom watcher?
19:39TimMcI should clean that code up some day.
19:40TimMcpandeiro: That's a thought. Might need some finagling.
19:40_philpandeiro: but then every bit of data would need to be wrapped in an atom :/
19:40TimMc_phil: or a ref or var
19:40TimMcThey all support watchers.
19:40pandeiro_phil: or just have one mega-state-atom?
19:41TimMcpandeiro: That's the ticket.
19:41_philTimMc: yea some mutable state thingie
19:41aphyrrea
19:41pandeiroi just implemented undo/redo with ClojureScript (right before reading that the Google Closure Editor already has an undo/rego plugin)
19:41_philpandeiro: but the problem is that i dont wanna have (swaps! ...) in the event handler because that would effectively make them impure
19:42_phili wanna have smth like event-handler :: Input -> Output and everything is pure inside
19:43_philthen the "main loop" or whatever you wanna call it "runs" the changes made in the event handlers and (swaps!) them into the mega-atom
19:56alexykanything shorter than: (Integer/parseInt "12") ?
19:56amalloy12
19:57amalloy~rimshot
19:57clojurebotBadum, *tish*
19:59seanmread-string maybe?
20:00seanmthough that's likely overkill
20:00technomancy,(Integer. "12")
20:00clojurebot12
20:00alexykseriously, no str2int in std lib?
20:02jeremyheilerall it would do is what was already mentioned
20:03emezeskejeremyheiler: and possibly be portable across e.g. Clojure, ClojureScript, and whatever the CLR one is called
20:03technomancydoesn't JS's integer constructor expect a string?
20:04technomancyoh wait... JS doesn't have integers
20:04emezeskerofl
20:04seanmwomp womp
20:04emezeskewell, there's that...
20:05jeremyheileremezeske: undestandable. not sure how much of a priority that is for Core, though.
20:05emezeskejeremyheiler: yeah
20:07alexykwhy not (int "12")?
20:08TimMc&(doc int)
20:08lazybot⇒ "([x]); Coerce to int"
20:08TimMc'int is intended for casting and coercion of other numerics
20:09jeremyheilerdunno.. https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/RT.java#L1068
20:11jeremyheilerah (missed what TimMc said)
20:12alexykso coerce doesn't say "numeric"
20:12seanm,(int "12)
20:12clojurebot#<ExecutionException java.util.concurrent.ExecutionException: java.lang.RuntimeException: EOF while reading string>
20:12seanm,(int "12")
20:12clojurebot#<ClassCastException java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Character>
20:12TimMcCharacter is apparently the last thing it tries.
20:12alexyktrue, the question is that this semantics may be too limiting
20:13TimMcYou could (defn int-by-hook-or-by-crook ...)
20:14jeremyheilerheh, when doesn't an open source project need better/clearer docs
20:17alexykwhere do I get uniq now from?
20:18alexykfor sort | uniq kind of thing
20:18alexykor via a set?
20:18technomancyyeah, just call set on your collection
20:19hiredman(doc distinct)
20:19clojurebot"([coll]); Returns a lazy sequence of the elements of coll with duplicates removed"
20:19technomancyor sorted-set I guess
20:19TimMc_phil: Event handlers *are* impure, they're responding to events!
20:20unlinkDoes anyone deploy Ring applications under a context root? Or is it assumed that Ring has the whole web server to itself?
20:20_philTimMc: its possible the "outside world" is impure, but why should event handlers be impure by definition?
20:21TimMcTheir job is to mutate something.
20:21_philTimMc: their job is to return a new state derived from an old state... this doesnt necessarily imply mutation
20:21TimMcI mean, if you turn the universe inside out, sure, you can make them pure.
20:23_philTimMc: well, idk, but if i already ditch java for clojure, dont see why i should be programming like i did in java with the additional benefit of first class functions and macros
20:23_philbut still with mutable state all around the place
20:23TimMcIf you can make them transformers instead of mutators, then go for it -- but I wouldn't try to restructure too much of the rest of the program to accomodate that.
20:24TimMcAt some point you have to frob a ref.
20:25_philTimMc: its a new project so i can architect it any way i want... thats why right now im trying to get as many points of view as possible
20:25TimMcAh, OK.
20:26_philTimMc: and yes, sure, at some point you gotta mutate some ref / atom / etc, but this is gonna be at *one* place only and well tested
20:26_philand the rest of the program consists of pure functions that can be easily composed and tested
20:26TimMcTrue, the more you can localize your side effects, the better.
20:26devnDCI in Clojure... Anyone know anything about that?
20:27TimMcDCI?
20:27TimMcDigital Chicken Interleaving?
20:27jeremyheilerDependency Companion Indicators?
20:28alex001data, context, interraction ?
20:28_philTimMc: do you see any obvious disadvantages to any of this? or would you rather say clojure's philosophy is "minimize mutation but dont try too hard" and i should do it the old fashioned way?
20:29jeremyheilerunlink: im not sure, but doing that has always been a pain unless you programatically create URLs, or hard code them :-/
20:30jeremyheilerunlink: I suppose you can have somethign re-write them *shrug*
20:32jeremyheilerdevn: Seriously, what is DCI?
20:33TimMc_phil: It's not as discouraged as it is in some languages -- because the STM is so awesome.
20:34TimMcBut the general philosophy is to avoid mutation when practical.
20:35jeremyheilerI hate articles that claim to talk about something, and after the first two paragraphs don't really say what it is they really are talking about (trying to figure out what DCI is...)
20:35technomancyyou mean like every article on dependency injection out there?
20:36technomancyor OSGi?
20:37jeremyheileryes, exactly. (except for martin fowlers article on dependency injection.)
20:38_philis implementing clojure.lang.Associative (i.e. overwrting assoc) in a deftype a bad idea?
20:38brehautis your type associative?
20:39_philbrehaut: as much as any random type is associative, i.e. it is a container that could hold any type, also associative types
20:43unlinkjeremyheiler: It's trivial for typical servlets, however.
20:45brehautunlink: i presume you are talking about deploying a ring app via the ring servlet adapter
20:45unlinkbrehaut: yes. The line that troubles me is: :uri (.getRequestURI request)
20:45brehautunlink: why?
20:45brehautunlink: because it gets an absolute url?
20:45brehauterr uri
20:46unlinkbrehaut: Servlet applications should have no knowledge what context root they are deployed under.
20:51unlinkbrehaut: I see that this was discussed (inconclusively) on the ring-clojure google group. http://bit.ly/AiCYIt
21:09brehautunlink: both compojure and moustache use :path-info (ie, context aware :uri) where available. it seems the talked about wrap-context middleware hasnt made it into ring though
21:09brehaut(both compojure and moustache allowed for nested handlers which is the same usecase as context roots for servlets)
21:12brehautunlink: you should be able to use :servlet-context to generate :path-info in a middleware as needed
21:13aaelonyI have a macbook pro that absolutely refuses to give a repl for Clojure 1.3.0. It accepts Clojure 1.2.1 though just fine. It drives me crazy though and would love to get this fixed. Any ideas? http://pastie.org/3286336
21:16brehautaaelony: what version of lein are you running?
21:16aaelonyLeiningen 1.6.2 on Java 1.6.0_29 Java HotSpot(TM) 64-Bit Server VM
21:17brehautlion ?
21:17aaelonynot Lion, 10.6.8
21:17aaelonysomewhere there must be something 1.2.1 that conflicts
21:18aaelonyi have no clue as to where
21:18brehauti cant really help much, but i have the same lein and jvm on lion and im not having trouble, but i cant easily go test on snowleopard sorry
21:20aaelonybrehaut: well thanks for trying at least.
21:20aaelonyI have another machine that doesn't have this problem as well. I know there is something that got funky on this machine but looking to correct that somehow
21:26muhooaaelony: try a different jvm?
21:27aaelonymuhoo: how can I try that?
21:28muhoouninstall the one you have, and install a different one
21:28aaelonyok, will look into that
21:28muhoohttp://www.oracle.com/technetwork/java/javase/downloads/index.html
21:28aaelonythanks
21:28yazirianon OS X you can check the 'Java Preferences' control panel (spotlight it)
21:28yazirianand choose between whichever jvms you have
21:29yaziriani have 3 i think, a 7 and 2 different 6's
21:29muhoomy guess is hotspot is optimizing away something that clojure needs
21:30apwalkfwiw: i am using those exact versions of lein, jvm, and clojure.
21:30aaelonyok
21:30yaziriani have used those together as well on both OS X 10.6.8 and 10.7
21:31yazirianwhat happens if you try to run the repl directly? i.e. java -cp /path/to/clojure-1.3.jar etc etc
21:31aaelonyIn the General tab of 'Java Preferences' I see Java SE 6, both 64-bit and 32-bit are checked
21:34aaelonyyazirian: what other options do i need to include to try running the repl directly? I have java -cp lib/clojure-1.3.jar
21:35aaelonyI don't have much of a java background
21:35yazirianjava -cp lib/clojure-1.3.jar clojure.main
21:35aaelony java -cp lib/clojure-1.3.jar clojure.main
21:35aaelonyClojure 1.2.0-master-SNAPSHOT
21:35aaelonyuser=>
21:36aaelonyweird
21:36yazirianyeah that is clearly wrong heh
21:36aaelonyI wonder where it is coming from
21:38aaelonyrunning a find on that ...
21:39xeqiaaelony: try running `echo $CLASSPATH`
21:40aaelony$CLASSPATH is not set
21:40xeqithats good
21:41yazirianeven the name clojure-1.3.jar is wrong, it should be clojure-1.3.0.jar
21:42aaelonyfind found 2 files named clojure-1.2.0-master-SNAPSHOT.jar
21:43yazirianwhere?
21:43clojurebot#<ClassCastException java.lang.ClassCastException: clojure.lang.Cons cannot be cast to clojure.lang.IPersistentStack>
21:43aaelonyyazirian: that is my typo
21:43aaelonyjava -cp lib/clojure-1.3.0.jar clojure.main still gives the 1.2.0-master-SNAPSHOT
21:43yazirianwhere are the weird 1.2.0-master-SNAPSHOT files located?
21:44aaelonyyazirian: ~/clojure/clojure-1.2.0-master-SNAPSHOT.jar and ~/tmp/clojure/clojure-1.2.0-master-SNAPSHOT.jar I'm perfectly willing to rm them both
21:44ltmitch49?
21:47yazirianwas wondering if one got stuck into the JAVA_HOME area someplace
21:49yazirianlike how rt.jar doesn't need to be in CLASSPATH to be found
21:49tjgilliesin clojure speak does synchronous == blocking?
21:49aaelonyin 'Java Preferences' in the Network tab there is a cache. I wonder if there is something there?
21:49aaelonydeleting the cache files to see if that helps
21:56aaelonywhen I do "java -cp lib/clojure-1.3.0.jar clojure.main" where does the resulting answer message "Clojure 1.2.0-master-SNAPSHOT" come from ?
21:59jeremyheileraaelony: Looks like it comes from the pom.xml
21:59aaelonylooking for a pom.xml
22:00jeremyheilerWhich gets torn apart into the *clojure-version* var
22:00jeremyheilerin core.clj
22:00aaelony]: java -cp lib/clojure-1.3.0.jar clojure.main
22:00aaelonyClojure 1.2.0-master-SNAPSHOT
22:00aaelonyuser=> *clojure-version*
22:00aaelony{:interim true, :major 1, :minor 2, :incremental 0, :qualifier "master"}
22:00jeremyheileryes.
22:00jeremyheilerhere: https://github.com/clojure/clojure/blob/master/pom.xml#L8
22:02jeremyheileractually.... it comes from a version.properties file as well
22:02jeremyheilerhttps://github.com/clojure/clojure/blob/master/src/clj/clojure/core.clj#L6199
22:02xeqiaaelony: what happens if you run `java clojure.main`
22:03aaelonyif I do "lein pom" it generates a pom.xml file, but without reference to 1.2.0. Otherwise there is no pom.xml file in my dir
22:03aaelony: java clojure.main
22:03aaelonyClojure 1.2.0-master-SNAPSHOT
22:03jeremyheilerDid you download the source for clojure?
22:03aaelonyuser=>
22:03aaelonyI might have, perhaps ages ago. If I did, how would I clean it out?
22:04jeremyheilerclone it from github
22:04jeremyheilerhttps://github.com/clojure/clojure
22:04aaelonyI guess it can't make it worse... ;)
22:05aaelonycloning now
22:05jeremyheilerWhat is your motive behind knowing were the version string comes from?
22:05aaelonyhttp://pastie.org/3286336
22:07xeqiaaelony: `ls /System/Library/Java/Extensions`
22:07xeqiI think thats the mac directory
22:07aaelonyls /System/Library/Java/Extensions/
22:07aaelonyAppleScriptEngine.jar j3daudio.jar jai_core.jar libJ3DUtils.jnilib* mlibwrapper_jai.jar
22:07aaelonyMRJToolkit.jar j3dcore.jar libAppleScriptEngine.jnilib* libQTJNative.jnilib* vecmath.jar
22:07aaelonyQTJava.zip j3dutils.jar libJ3D.jnilib* libShark.jnilib*
22:07aaelonydns_sd.jar jai_codec.jar libJ3DAudio.jnilib* libmlib_jai.jnilib*
22:08xeqik, not in there, and you mentioned classpath was not set
22:08xeqitheres gotta be a 1.2.0-master jar somewhere for the `java clojure.main` to have made a repl
22:08aaelonyeasier to peruse here: http://pastie.org/3286519
22:09aaelonyyes, $CLASSPATH is empty
22:12aaelonyxeqi: I agree, but where the devil is it?
22:13aaelonyrunning this: sudo find / -name "*1.2.0-master*"
22:13xeqithat was my next suggestion
22:13tjgilliesstate mutation would be a cool band name
22:15aaelonyfound it
22:16aaelonyhttp://pastie.org/3286544
22:17aaelonyI guess I can just rm that
22:17xeqiyeah
22:18yazirianthe case of the haunted extensions dir
22:18aaelonyok, removed that. Now eerily I get: ]: java clojure.main
22:18aaelonyClojure
22:18aaelonyuser=>
22:18muhoogood to know.
22:18tjgilliesis there a way to see a history of state for a structure?
22:19muhooi remember reading that variables keep a history of the last 5 states, like bash history, but i don't remember reading how you can actually LOOK at those
22:19muhooor maybe i misread it entirely.
22:20brehautmuhoo: what do you mean by variables? i think most clojure programmers would think you mean on of lexical variables defined by lets and params etc, or perhaps Vars
22:20aaelonyinterestingly, removing the clojure-1.2.0-master broke leiningen! Lein version even bombs now
22:21aaelonydoing lein upgrade
22:21muhoobrehaut: then i misremembered it with incorrect terms as well :-)
22:22brehautmuhoo: do you mean an STM Ref ?
22:22muhooprobably, an agent or ref perhaps
22:25brehautmuhoo: i suspect you are confusing some of the ref machinary (but i dont know for sure). Agents dont appear to have any history storying mechanism
22:26brehautmuhoo: refs have a history, but i dont know if its intended for use outside the transactional machinary
22:26muhooi should wait until i finish this joy of clojure book then. most of my knowlege so far of clojure is like free-associational dream-logic fragments, culled from reading language refs, various tutorials, videos, and my own experimentation.
22:26muhooit's like a soup of terms and concepts. but the book is organized, so i'm starting to get some structure now.
22:26brehautmuhoo: sounds a lot like mine then ;)
22:27muhooso much of the mental pictue i have of clojure right now is "not even wrong"
22:29muhooi read sentences like this 8 times and still have NFI what they mean: "Destructuring allows us to positionally bind locals based on an expected form for a composite data structure."
22:29muhoototally!
22:29muhoobut after i finish this chapter, i'd damn well better understand that sentence :-)
22:30xeqiaaelony: any luck?
22:30brehautmuhoo: a "composite data structure" is something like a list, vector map etc ie its made up of other smaller parts (in contrast with scalars like numbers or characters)
22:31muhoobrehaut: that helps, thanks
22:31brehautmuhoo: "positionally bind locals" means that the local variables are bound to the items in the data structure based on their position in the destructuring expression
22:31aaelonyremoving the 1.2.0 jar broke leiningen. Now re-installing lein.
22:31brehautmuhoo: eg, if you have a vector [:first :second :third] then
22:31aaelony java clojure.main yields "Clojure" and gives me a repl too
22:32brehautyou can bind local variables a b and c with let like (let [[a b c] [:first :second :third]] …)
22:32aaelony*clojure-version* is unbound
22:33JanxSpirit'
22:34xeqiheh, can you (+ 1 2)?
22:34aaelonyhmmm... lein is quite unhappy now.
22:34muhooaaelony: lein requires clojure 1.2 iirc
22:34aaelonyhaha, looks like it!!
22:35muhoolein does some magic i don't understand to run in its OWN clojure, 1.2, separate from whtaever clojure you may be actually running (1.3, git HEAD, whatever)
22:35muhoothis is done, IIRC, to keep the build environment separate from the run environment
22:36aaelonylein is now missing the 1.2.0 jar it needs and I think that that must have been the earlier problem as well... that something needed a missing jar and was thus unhappy.
22:36muhooaaelony: CLOJURE_JAR="$HOME/.m2/repository/org/clojure/clojure/1.2.1/clojure-1.2.1.jar"
22:37muhoo(clojure, i'm still lost in the woods, but bash, i understand :-)
22:37aaelonymuhoo: indeed... Now the question is how to start over fresh...
22:38muhooaaelony: i'm kind of brutal with this stuff, i'd blow away ~/.m2, blow away all clojure, start over
22:38xeqiaaelony: was there anything else in the "/Library/Java/Extensions/" directory?
22:38muhooblow away ~/.lein too
22:38aaelonyoh, there is no ~/.m2. I'm trying to get it back, but https://raw.github.com/technomancy/leiningen/stable/bin/lein throws an exception now
22:39muhooaaelony: what's in ~/.lein ?
22:39yazirianjust clear out ~/.lein and let it re-bootstrap itself?
22:39aaelonyjust nuked ~/.lein
22:39muhooaaelony: yazirian <--- what he said
22:39aaelonythat seemed to help
22:40aaelonylein tries to re-install and now eventually throws an exception
22:41aaelonyCaused by: java.io.FileNotFoundException: Could not locate leiningen/core__init.class or leiningen/core.clj on classpath:
22:41clojurebotI don't understand.
22:41aaelonyperhaps I'll move this to the leiningen area then...
22:43muhoobrehaut: thanks, that was the stuff that i needed to unpack. makes sense now.
22:45brehautmuhoo: no problem
22:54nuclearsandwichtechnomancy: I'm trying to run a standalone swank-clojure server (for Slimv) and I've noticed that ~/.lein/bin/swank-clojure has `/home/phil` hard coded in it.
22:54nuclearsandwichtechnomancy: where's the best place for me to follow up with it/find and submit a fix?
23:00tjgilliesanyone know how i can fix this?:
23:00tjgillies /Users/tyler/penumbra> lein native-deps
23:00tjgilliesThat's not a task. Use "lein help" to list all tasks.
23:03tjgillies(i installed leiningen with mac homebrew if that matters)
23:03brehauttjgillies: lein version
23:05tjgillies /Users/tyler/penumbra> lein version
23:05tjgilliesLeiningen 1.6.2 on Java 1.6.0_29 Java HotSpot(TM) 64-Bit Server VM
23:09brehauttjgillies: you have the apropriiate plugin installed?
23:12tjgilliesbrehaut: lein plugin install native-deps?
23:12brehauttjgillies: no idea
23:13tjgilliesok
23:13brehautbut it lookjs like a good guess
23:34devnjust showed overtone to someone who has been trying to do generative music in javascript
23:34jeremyheilerdevn: did you have to fix their jaw?
23:34devni have a feeling he's not going to go to work tomorrow
23:34devnlol
23:35jeremyheilernice
23:35devnyeah, basically had to help him off the floor
23:36devnThe whole repl-driven music generation thing was making him crazy, plus the concurrency story and timing stuff
23:36devnI've worked with other languages and generative music -- clojure is a dream in so many ways
23:38devnjeremyheiler: sorry for bailing earlier. figure out what DCI is?
23:39jeremyheilereh, i found the wikipedia article and kind of gave up lol
23:43nuclearsandwichDCI? Drum Core International?