#clojure logs

2012-12-12

00:04ambrosebsCurious, does anyone use https://github.com/frenchy64/analyze in their projects?
00:07Sgeo|webI tried naively hooking it into clojail but that didn't work. Now trying mexpand-all although that's imperfect too :/
00:07Sgeo|webFewer errors though
00:07Sgeo|webusing analyze seems to sometimes turn + into .. some Java interop call. Wonder if that sort of thing is part of it
00:07Sgeo|webI didn't look that closely
00:07ambrosebsI didn't seriously think people would use it.
00:08ambrosebsIt's just a little hack on top of the analyser
00:08Sgeo|webI'm not really much of a person who should be looked at as an example of someone with typical usage patterns
00:08ambrosebsSgeo|web: + inlines
00:08Sgeo|webI wonder if analyze can be used to make delimc actually work properly
00:09ambrosebsSgeo|web: What's wrong with it?
00:09dr1I'm running a repl and popping up a GUI by running (project.core/-main)… which works great. However, when I modify any code and reload the project with (use 'project.core :reload-all) and show the GUI again, it keeps the original state. Is there a way to reset it or do I pretty much need to close the repl?
00:10Sgeo|webWell, partly that it looks for raw symbols, so if you just require it, instead of using all symbols, and proceed to, for example, use shift as though it's part of a namespace rather than a magic symbol, it breaks
00:10Sgeo|webBut I suspect there may be other issues too
00:11Sgeo|webBeing able to easily distinguish between special forms and function calls, and not have to worry about macroexpansion... oh, hmm.
00:11Sgeo|webNot sure how that would actually work then.... oh, just look for the function call to shift, I guess
00:11ambrosebsSgeo|web: analyze cannot be customised.
00:12Sgeo|webWell, shift is a macro, but easy to imagine it as a function that takes a lambda, I think
00:12devnambrosebs: ive been looking at analyze, but im not sure if it can help me. i haven't spent enough time to figure it out.
00:12Sgeo|web...takes a lambda. I'm tired. *takes a function
00:12devnambrosebs: id like some of the functionality of analyze to extend codeq's schema
00:12Sgeo|webambrosebs: I don't think I need it to be customized
00:12devnso you could query for sub-expressions, or find codeqs which include a call to clojure.core/map
00:12Sgeo|webFor this potential usage
00:13devnand possibly extract that inner expression
00:13ambrosebsdevn: and you always want fully mexpanded forms?
00:14Sgeo|webambrosebs: I think a useful addition might be a thing to search for every function call, or perhaps a way to see and modify every function call, leaving the structure intact
00:14devnambrosebs: heh, again, not real sure. analyze seems to provide a lot more granularity for things i could query about codeqs, but maybe i have that wrong?
00:14Sgeo|webAlthough that doesn't seem general enough, something ... more general than what I asked for
00:14Sgeo|webBecause I can imagine that as a use case
00:14Sgeo|webbut seems like it might be difficult to write by hand currently
00:15devnambrosebs: some things seem like they just wouldn't be open to analysis, since it needs to basically just operate on text. I suppose you could read-string and then use analyze on that? again, im not real sure.
00:16arohnerin lein2, how do you disable AOT?
00:16ambrosebs`analyze` just throws a form at the CLJ analyser and then works on the output. You're stuck with all the inlining & other optimisations.
00:17Sgeo|webI wonder if a macroexpander that's based on studying what forms each special form passes to the analyzer and macroexpanding that might be useful?
00:18Sgeo|webRather than using the analyzer directly, more like a port of some parts of it?
00:19ambrosebsOf course this exactly the question `analyze` is supposed to evoke. The answer is usually CinC.
00:20bbloomambrosebs: i want to make the analyzer more useful
00:20bbloomthe cljs one that is
00:20bbloomi'm working on some improvements, but i'm not sure how to get them pushed through other than to pester dnolen
00:20ambrosebsbbloom: Cool, what are you working on?
00:21bbloomi was working on the CPS transform
00:21bbloombut i've been pounding my head on the wall repeatedly on the same few issues
00:21bbloomambrosebs: some notes here http://dev.clojure.org/display/design/Formalize+AST
00:22bblooma few things missing from there too
00:22ambrosebsAwesome!!
00:22ambrosebsVery exciting.
00:22bbloomyour feedback would be appreciated
00:23ambrosebsWhen we say "formalising AST", are we thinking about Clojure JVM also?
00:23ambrosebsas in, potential issues/conflicts?
00:23bbloomambrosebs: maybe?
00:24bbloomwe need a spec or something for the AST
00:24ambrosebsOne problem I usually think about: having "implementation-only" AST nodes, like `instanceof`
00:24bbloomeven better if it's a schema that is an executable validator
00:25bbloomambrosebs: cljs already has js* which is an implementation detail
00:25bbloomwhat else do you think about those types of nodes?
00:27ambrosebsHow do we handle them in such a schema..?
00:28ambrosebs:)
00:28bbloomheh.
00:28bbloomi want to break the analyzer up into passes
00:29bbloomso you could have a different schema for a particular backend
00:32ambrosebsdo you mean, one pass for standard Clojure nodes, then another for others?
00:32bbloomyes, but also lots more simpler passes
00:33bbloomright now there is analyze and emit
00:33bbloomi'd like to break analyze up quite a bit
00:33bbloomit already does a lot of things: parse, built up an environment, infer type tags, etc
00:33ambrosebsah got it.
00:33bbloommacro expansion
00:33bbloometc
00:34bbloomit's getting harder and harder to maintain
00:34bbloomand it's preventing us from adding new and more sophisticated optimizations
00:34ambrosebsso I'd be easier to reuse parts for different impls?
00:35bbloomyes
00:35bbloomand so we can ultimately get self hosting
00:40ambrosebsbbloom: how much work do you expect that to be?
00:40ambrosebssorry, I meant cutting up the analyser
00:40ambrosebsIs it mainly design effort?
00:40bbloomi think it's relatively straightforward
00:40bbloomi've already done a lot of these changes before in bits and pieces
00:40bbloombut yeah, design buyoff is necessary
00:41bbloomalso, the more we focus on this, the easier it gets :-P
00:42ambrosebswhat kind of feedback do you want on this design page? It needs the usual Problem statement/tradeoffs/solution.
00:42ambrosebsWe need to dress it up so people can't ignore it.
00:43bbloomambrosebs: i'm bad at that :-P you wanna take a crack at making it a bit prettier?
00:43ambrosebsambrosebs: I'll try...
00:44ambrosebs:)
00:44devnambrosebs: do you think there would be any use in extending codeq's schema to include some of the information analyze brings to the table?
00:45ambrosebsdevn: are inlining & other optimisations too much information?
00:45devnyeah, i think they might be?
00:45ambrosebsthen no.
00:45devnbtw ambrosebs -- i keep referring to you as ambrose bierce in conversation
00:46devnambrosebs: well, i guess i take that back. i mean, there doesn't seem to be any harm in capturing that information...
00:47devnambrosebs: could you clarify what you mean by "other optimizations" -- does analyze show you optimizations that are happening under the clojure hood?
00:49ambrosebsdevn: lol sounds better than BS
00:49ambrosebsI am full of it apparently.
00:49devnha!
00:50ambrosebsdevn: analyze shows every little detail. eg. calls to instance? are converted to a special instanceof AST node.
00:50devnambrosebs: idk man -- im just thinking out loud here. i think it would be cool, in addition to querying for the history of "clojure.core/map"
00:51devnif you could query for all of the fns in 100 clojure repos, which contain :method-name "add", for instance
00:51ambrosebssure, that sounds useful at some level.
00:51devnambrosebs: id like to build a Hoogle for clojure
00:52devnive been playing with this idea since like 2008
00:52ambrosebsdevn: please please please do
00:52devnambrosebs: i think the stars are just starting to align
00:52devnwith your work, codeq, datomic
00:53bbloomdevn: hoogle is super cool
00:53ambrosebsI am prepared to do whatever you need to help you to this end.
00:53ambrosebs:)
00:53devnambrosebs: how would that work? you don't eval forms in analyze, right? could analyze operate on "(defn foo [x] (+ 1 x))"?
00:53devnor would I need to read-string all over the place?
00:54SgeoWondering if I could make a little factor-like DSL for Clojure
00:54bbloomSgeo: you can :-) i have one
00:54Sgeobbloom: awesome
00:54bbloomdidn't publish it yet
00:54bbloombut actually, it's not really a DSL
00:55bbloomwell, i dunno what to call it
00:55ambrosebsdevn: You can just feed it through `analyze-form.
00:55bbloomit's an interpreter
00:55bbloomnot like some fancy macro for normal clojure functions
00:55ambrosebsI'm not 100% about the side effects of doing that.
00:55ambrosebsI think the var will be declared.
00:55SgeoI'd say something like Factor showing how everything could live in a ->, but syntax words sort of break that
00:56devnambrosebs: bbloom: I'm going to hold you to your statements. We have all of this code out there in gists, pastebins, and in repos. Imagine if there was a service where you could search hoogle-style, or an "idiom finder", where based on analyzing 100+ clojure repos and gists, you could say: "show me the most common use of letfn"
00:56bbloomSgeo: yeah, the interesting bit is that side effects read left to right
00:56SgeoI .. think I kind of prefer Clojure macros over Factor syntax words, but not sure
00:56RaynesFactor is nice.
00:56RaynesBut the community basically does everything in its power to keep people from using it.
00:56devnambrosebs: can we have a hoogle without static types everywhere?
00:56SgeoThe thing that annoys me about reading Factor code though is if.
00:57RaynesThey never release anything, no beginner documentation.
00:57devnRaynes: kind of like Io. Io was so cool, but they don't even have releases.
00:57bbloomRaynes: agreed. #concatenative is moderated :-/
00:57bbloomwanted to ask a simple question
00:57SgeoAnd basically anything with quotations. Need to remember to keep reading to find out what, exactly, happens to the piece of code I just read
00:57Raynesdevn: Yeah, Io is a good example of how to ruin a perfectly good language.
00:57devnambrosebs: what would hoogle without static types look like? Could analyze get us 80% there?
00:57bbloomRaynes: i found that the main guy's researchy paper thing is actually a great tutorial
00:58RaynesSgeo: I like fries.
00:58devnresearchy papers!
00:58SgeoIs the convenient call/cc convenient to implement in Factor because of its concatenativeness?
00:58SgeoOr is it not actually that convenient, and there's VM support or something?
00:59devnambrosebs: one thing that seems like it would be wrong is using (ast) within the codeq namespace when importing a git repo
00:59devnyou'd get :ns {:name codeq.core} or something instead of the ns it actually resides in
01:00devnbut i suppose there may be a clever way to make that work
01:00devnthe codeq schema scares me
01:01ambrosebsdevn: `ast` is slightly dumb, but easy to use.
01:01ambrosebsAll the building blocks should be exposed.
01:02ambrosebsdevn: hoogle - static types = I don't know, but curious :P
01:02ambrosebsperhaps we don't want hoogle at all?
01:02devnyeah it seems to expose everything. it's more like the paradox of choice form my current point of view
01:02devnambrosebs: yeah, i dont think we do, but I think we could get close-ish
01:03devni want to go to a website and say: "show me function bodies where the input is a string, and it returns a sequence of characters" or something like that...maybe
01:03ambrosebsdevn: maybe look at `analyze-form-in-ns`
01:03devnambrosebs: mm! thank you.
01:04ambrosebsdevn: But I'm not sure if it actually works!
01:04devnambrosebs: btw, you probably don't hear this enough. your work is really great and inspiring.
01:04devnthanks for all the work you do
01:04devnsame to you bbloom
01:04Sgeo...I feel like such a hypocrite
01:04devnand Raynes
01:04devnhugs all around.
01:04ambrosebsdevn: thanks!
01:05ambrosebshugs!
01:05bbloomnow if only i can find somebody to pay me to do this all the time :-P
01:05devnSgeo: why's that?
01:05RaynesNaw, man. All ambrosebs does is shit rainbows.
01:05devnbbloom: all in good time, my friend.
01:05SgeoTotally reject all Schemes because the Scheme community is so fragmented that there's not much of a community around any of them -- start being interested in a language with even less of a community
01:05RaynesAin't that right, ambrosebs?
01:06devnbbloom: i advocated for clojure where i work for a couple of years, and now i have way too much clojure work.
01:06devnbe careful what you wish for :)
01:06ambrosebsambrose: BS rainbows
01:06ambrosebslol, talking to myself
01:06ambrosebsRaynes, rather ^
01:06devnrambose
01:06devnlike Rambo
01:07ambrosebshaha
01:07devnsince you're an aussie: http://scm-l3.technorati.com/10/04/30/12345/rambo.jpg
01:07devnjust in case you aren't familiar
01:07devnframboise when you're in france
01:09ambrosebsI like Ambroise
01:09ambrosebsmy french relatives call me that, "ambruzz"
01:10devndamnbros
01:10devnwhen you're in New Jersey
01:17ambrosebsif there was someone interested in a screencast of me diagnosing and stamping out a bug in Typed Clojure related to inference of monadic code (higher-kinded), I suspect they're in this room.
01:17ambrosebsI might just do that today.
01:19devnplease do!
01:21ambrosebsI'm also taking requests. If unsure, "more" is sufficient.
01:30brainproxyattempting to define/describe web forms in a datomic schema, idea being to centralize all the various info that drives how forms are rendered and processed
01:30brainproxyanyone worked on something similar?
01:46bbloomdammit javascript, your semantics suck.
02:00devnbrainproxy: i doubt it
02:02ambrosebsdevn: I think Clojure Contributors thinks ur usename is `defn`.
02:11Apage43command line arg parsing, anything recently maintained?
02:20bbloomambrosebs: i posted to clojure-dev regarding my first two proposed breaking changes to the cljs AST. you're feedback is wanted on that thread :-)
02:22ambrosebsbbloom: Reading. I may not get around to changing the dev page today.
02:22bbloomambrosebs: no rush/obligation
02:23bbloomdnolen is just a busy guy and no one else with commit bit seems to really care...
02:24ambrosebs:loop seems like a good idea.
02:25ambrosebsI'm always giving :is-loop (well, the equivalent to my Clojure library) a special case.
02:25bbloomambrosebs: what's your github?
02:26ambrosebsfrenchy64
02:26ambrosebsmy analyze library is a great way to get an idea of how Clojure's analyser works
02:27ambrosebsWell, what it returns.
02:27bbloomambrosebs: yup
02:27bbloomi've seen it before, but hadn't looked at it recently
02:27bbloomlooking now
02:27ambrosebs:is-loop seems to be an artefact from Clojure?
02:27bbloomambrosebs: yeah, as best i can tell it's an implementation detail leaking
02:29ambrosebsClojure also has a bunch of interop nodes. CLJS just has js*?
02:30bbloomambrosebs: for the mostpart
02:30bbloomsymbols can also have the js/ namespace
02:31bbloomother differences: catch vs catch*
02:31bbloomor rather try vs try*
02:31bbloomb/c (catch e …) vs (catch Exception e ...)
02:33ambrosebscatch syntax is different in CLJS?
02:35bbloomambrosebs: no, it's the same, but javascript doesn't provide catching by type, so it's simulated
02:35bbloom(try (catch Exception e …)) is expanded to (try* (catch e (cond …)))
02:35bbloomhere's the full list of nodes: :no-op :var :meta :map :vector :set :constant :if :throw :def :fn :do :try* :let :loop :recur :letfn :invoke :new :set! :ns :deftype* :defrecord* :dot :js
02:36bbloomassuming my :loop
02:37ambrosebsAh, and there's no :defrecord* in CLJ.
02:38ambrosebsand CLJ has :the-var
02:39bbloomthe defrecord is because it's annoying to emit a bunch of javascript comments to document the record fields to make gclosure output fast constructors/types
02:39bbloomambrosebs: cljs doesn't have :the-var because there are no reified vars
02:39ambrosebsok
02:39bbloomsomething else i want :-P
02:40ambrosebsoh, is that possibly on the cards?
02:40bbloomwho knows
02:40bbloomi've been pushing for that one since i started playing with cljs
02:41bbloomanyway, your feedback is welcome on the mailing list so that maybe these changes can actually get made if somebody who cares sees :-P
02:42bbloomim gonna run for now, take care
02:43ambrosebsbbloom: see you
05:14tgoossensdamnit :p I proposed - in my working group at univ. - that instead of java i'll write my parts of the software in clojure, it compiles to java so they can use it
05:14tgoossensThey refused (obviously :p)
05:14rasputniktgoossens: you are making your professor feel inadequate
05:15tgoossensrasputnik: haha, no only my classmates, the professor doesn't botter about the code
05:15tgoossensour project just needs to work
05:15tgoossens*bother
05:16devntgoossens: just do it anyway
05:16rasputnikeasier to ask forgiveness than get permission
05:16tgoossensdevn: they will pick on me for doing that
05:16tgoossenslol
05:16devnthere is a lifetime of other people cramming their garbage programming language choices down your throat
05:17devnthere's no better time to say no than right now
05:17tgoossensbecause then they cannot read my code anymore
05:17tgoossens(or so they think)
05:17devnhelp them
05:17tgoossensdevn: if they are not open-minded for such things, then the only thing they will do is
05:17tgoossensbe mad at me
05:18devntgoossens: do both maybe
05:18devnshow them how much nicer it is
05:18tgoossensdevn: hmm interesting
05:18devnshow them "before" and "after"
05:18tgoossensmmyes
05:18ivaraasenkill bad code before bad code kills you
05:18devnthey may still not agree to use it
05:19devnbut you may get them on your side if you show them it is easier to read and manage
05:19tgoossensbut in order for my code to interopt with theirs, they need "classes"
05:20tgoossensno experience with that. Can't i just use protocols?
05:20tgoossensi believe they compiled to actual classes
05:21fredyrinterface even
05:21tgoossenseven better
05:21tgoossensso this means
05:22tgoossensi can actually write my code entirely in clojure. And in principle (if they wouldn't ask for the source code) they would not know it was written in clojure?
05:22fredyryes
05:22tgoossensthat sir
05:22tgoossensit frickin' genius
05:22fredyrthat's pretty much how the java api for datomic works
05:23vijaykirantgoossens: you might be interested in http://skillsmatter.com/podcast/scala/impromptu-rich-hickey-lightning-talk
05:23borkdudetgoossens sometimes it's better to ask for forgiveness than permission in clojure/java world ;)
05:23ivanthey might notice the clojure.lang.RT
05:23tgoossensivan: yeah. But thats just "a library" then he
05:23borkdudevijaykiran anything interesting tonight at amsclj that you know of?
05:23vijaykiranborkdude: Free conj T-shirts!!!!!! :)
05:24borkdudevijaykiran how many… will there be a fight over the 3 t-shirts? ;)
05:24tgoossensborkdude: perhaps. yes
05:24vijaykiranborkdude: pretty much - the number isn't revealed in the thingie btw. So there will be blood.
05:25borkdudetgoossens or just write it in both languages, as an exercise and you accidentally swap in clojure instead of java, while having it stand by to correct quickly if needed ;)
05:25tgoossensyeah
05:25tgoossensthe project takes a lot of time and in the mean time i want to practice clojure
05:25tgoossenscould be nice combination
05:26borkdudetgoossens "look, I reduced that Java code to a single line of clojure: …..))))})}))}])
05:27tgoossenslol
05:27tgoossensfor the record
05:27vijaykiranborkdude: btw, are you the same guy who sent the clojure project for students thingie ?
05:27borkdudevijaykiran yes, that's me
05:27tgoossensits a project with the java leJos library for lego nxt
05:27tgoossensborktude: please help me to have a project on clojure at my univ then! :p
05:27borkdudetgoossens ah cool, we're also using that in our education (I have no experience with it, but saw that a clojure version of it exists?)
05:28vijaykiranborkdude: did you find anything ?
05:28tgoossensEVERYTHING here is in java
05:28tgoossensreally everything
05:28tgoossensi'm sick o fit
05:28borkdudevijaykiran yes, already three companies are willing to co-operate
05:29vijaykiranborkdude: awesome, I'll watch your blog then :)
05:29borkdudevijaykiran we need only one though, unless we make some kind of tool that is more generally applicable
05:30tgoossensits really hell here
05:30vijaykirantgoossens: c'mon java isn't that bad :)
05:30tgoossensno java is not that bad
05:30tgoossensbut the point is
05:31tgoossenseverything here
05:31tgoossensis based on java
05:31tgoossenscourses, projects
05:31borkdudetgoossens it's the same here, that's the reason I started using clojure, so I can still relate to the Java-world
05:32borkdudetgoossens I bet your lecturers wouldn't mind making assignments in an extra language, just for fun and profit
05:32tgoossensmmm
05:33tgoossensthats exactly what i'm doing
05:33tgoossensfor a course OOP we had to create a fairly complex piece of software
05:33tgoossensi'm now rethinking it in clojure and next semester i'm going to try to get an opinion of the prof.
05:33rasputniktgoossens: if i were you, I'd focus on the JVM as much as you can rather than the Java language. that's not going anywhere. and if you want to be a good java dev, just grab the clojure source from github and walk through it sometime
05:35tgoossensrasputnik: i'll keep that in mind. What do you mean with "on the jvm"
05:35tgoossensdo you mean jvm languages?
05:36rasputniktgoossens: no, the mechanics of things like Hotspot, JMX, the generational GC bits - the platform for all JVM languages. rather than doing extra credits on language features like generics or suchlike
05:40fredyri agree, this is good advice
05:40fredyresp reading the clojure source imo
05:40tgoossensthanks
05:40ivaraasenthe Clojure source is great
05:40ivaraasenI believe there's a PDF explaining most of it
05:41vijaykiranhttp://daly.axiom-developer.org/clojure.pdf
05:41vijaykiranwarning looong PDF ^^
05:41ivaraasenvijaykiran: that's the one. really cool stuff
05:45muhooomg, i'm using lein-pedantic, and it's giving me a huge list of conflicts, telling me to put the :exclusions in my project.clj, but i already have those exclusions in there!
05:46muhooeverything it's telling me to do, i've already done. is there some weird local state it's saving?
05:47borkduderasputnik what book do you recommend on the jvm internal things
05:49ambrosebshow can I pprint while preserving defrecord tags
05:53rasputnikborkdude: there really aren't very many, annoyingly. i've got the "Java Performance" one from sun/oracle press, it's ok.
05:53rasputniktbh i'm a systems engineer, not a developer. 99% of all java books are no use to me, but a good tuning guide is worth it's weight in gold
05:53rasputnikvijaykiran: nice looking pdf, thanks.
05:53vijaykiranborkdude: "Programming for the Java Virtual Machine" is dated, but interesting.
05:53vijaykiranand there's always spec :)
05:54muhoooh, nm, i see, it keeps adding more items to the vector of exclusions
05:54muhooit's not throwing the same error over and over, it's throwing a more complex version of the same error each time :-). think i got it
05:55muhooany clojure app that uses anything that uses httpclient is in deep, deep dependency hell
05:57vijaykiranrasputnik: yw!
06:01degDoes Clojure have a built-in function to find positions of a vector in another vector? E.g, (f [:a :b :c :d :e :b :c :d] [:b :c]) => (1 5)?
06:02degIf not, how inefficient would it be to position of partition of the vector?
06:02fredyri've been looking at core.logic lately, but i feel like i'm not having a good sense of what restrictions there are to mixing in ordinary clojure constructs inside
06:03fredyrany pointers on that
06:04ambrosebsfredyr: see `project`
06:04ambrosebsOnce you start using non-relational goals like project, you lose the ability to run backwards.
06:05fredyrah, i have read something about that briefly
06:05fredyri'll take a closer look, thanks
06:05ambrosebsnp
06:05Raynescemerick: Yikes. I just came about an inch from buying your book when I realized that Julie gave me a copy when it was finished that I have in an email attachment somewhere.
06:06RaynesI almost gave you money, man. Close call.
06:06cemerickRaynes: 'lo, and here I was so close to avoiding debtor's prison. Glad you could save the $20, though.
06:06cemerick:-P
06:10cemerickRaynes: Do you actually have the final PDF, or the final "prepress" PDF? (The latter doesn't have the bird on page 1, and no index, for all the good it'll do you.)
06:10Raynescemerick: Good question. I'll look up the email.
06:15muhooRaynes: wow, isn't it like 6am where you are?
06:15Raynesmuhoo: It is 5AM.
06:15RaynesAnd no, I haven't slept.
06:15muhoostill hard core
06:16muhoowell i made it through dependency hell. app i wrote in april, under continuous use, has not bitrotted since then. yay clojure.
06:17muhooplus i was able to look at it after not looking at it for almost 6 months, and quickly figured out how the hell it works. again, yay clojure.
06:18Raynescemerick: I can't actually find the email now. :\
06:19muhoothough, i sure should refactor it https://www.refheap.com/paste/7529 :-/
06:20borkdudeso what will be the clojure book of 2013?
06:20Raynesborkdude: Whatever that ClojureScript book is, probably.
06:20cemerickRaynes: http://images2.wikia.nocookie.net/__cb20100702150415/simpsons/images/6/6a/Mr_Burns_evil.gif
06:20RaynesEveryone is cookoo for cocopuffs.
06:20Raynescemerick: :p
06:21clgvborkdude: suggestion "Clojure 1.5 in a nutshell" ;)
06:21cemerickborkdude: people keep asking about when a second edition is going to happen. I actually don't think there's enough new stuff to warrant one.
06:21cemerickJoC 2nd ed will be a very big deal
06:21borkdudecemerick The Joy is being revised on clojure 1.5
06:22cemerickRight; but, 1st ed there was based on 1.2 (with 1.1 notes, IIRC?)
06:22Raynescemerick: If you ever need help with a second edition, let me know and I'll ignore you.
06:22RaynesI mean, help you.
06:22RaynesI'll totally help you.
06:22cemerickDude, that PDF is sooo going to get lost in the mail.
06:23borkdudeThe Rich Hickey diaries: how many hammocks does it take to create a following
06:24cemerickReducers and tagged literals are the biggest changes that aren't covered in @ClojureBook. (Any others of import?)
06:24cemerickThat's not much to prompt a 2nd ed.
06:24borkdudecemerick maybe a batteries included book on clojure web dev: compojure, authentication, clojurescript, nice full examples, pitfalls, etc?
06:25cemerickmaybe
06:25RaynesI'm not sure how I feel about books like that.
06:25RaynesThings change so fast.
06:25cemerickI won't be writing it though :-P
06:25RaynesLike, I did that talk at the conj and then basically rewrote Clojail.
06:26borkdudeRaynes yes.. maybe in a few years, Enterprise Clojure web dev ;)
06:26cemerickI have an idea for another Clojure book, but am in no hurry about it.
06:26clgvRaynes: you just wanted to create material for the next talk *jokingly* ;)
06:26Raynesclgv: Hah. It probably would be worth another talk now. It has some cool serializable function stuff in it now.
06:27ivaraasendeg: would something like this be of use? https://www.refheap.com/paste/76fa8ae0b4e3666d2ed019af9
06:27clgvRaynes: are the 4clojure performance issues history yet?
06:27Raynesclgv: That's what the serializable functions were for. It's much faster now.
06:27clgvRaynes: and already in use on 4clojure?
06:28RaynesWell, it has been that way for several months.
06:28RaynesSo yes.
06:28clgvgreat. need to resubmit my solutions that had strange timeout behavior :D
06:29RaynesYeah, they will probably work now.
06:52clgvCan I add criterium as dependency in ~/.lein/profiles by adding it as dependency to the :user profile? I tried but it does not get download on lein repl
06:52penthiefWhat is the meaning of the convention for suffixing variable names with an asterisk? map* ch* run*.....
06:54Raynespenthief: Usually means "This does something similar but somewhat different than the thing without the asterisk". Some people also use it to mean "This is an internal function used by the function without the asterisk."
06:54RaynesI just avoid ever using it at all.
06:54penthiefthanks
06:55Raynespenthief: One example in Clojure itself that uses the former interpretation is list vs list*
06:55Raynes&(list 1 2 3 4)
06:55lazybot⇒ (1 2 3 4)
06:55Raynes&(list* 1 2 '(3 4))
06:55lazybot⇒ (1 2 3 4)
06:57SgeoIs it normal to find Factor insanely difficult to read?
06:57SgeoIt's not J, but it's still a bit annoying
06:58RaynesSgeo: Yes.
06:58RaynesIt takes a long time for it to make sense.
06:58SgeoIs the project still active?
06:58SgeoWill there ever be distribution of libraries outside the project itself?
06:59RaynesSgeo: It isn't that active, and Slava doesn't work on it anymore.
06:59Sgeo:/
07:02Sgeoo.O at the claims about Lisp http://www.reddit.com/r/programming/comments/9pudj/a_survey_of_domainspecific_languages_in_factor/
07:03RaynesSgeo: http://rosettacode.org/wiki/Bulls_and_cows#Factor This is the most code I've written in factor.
07:03SgeoMore than I've written
07:04RaynesSgeo: I'm looking at it right now, nearly 3 years later, and I couldn't tell you what this did if there were instructions with it.
07:04borkdude,(doc list*)
07:04clojurebot"([args] [a args] [a b args] [a b c args] [a b c d & ...]); Creates a new list containing the items prepended to the rest, the last of which will be treated as a sequence."
07:04Sgeoinc-bulls and inc-cows should use change-bulls and change-cows
07:04SgeoI think
07:05degivaraasen: tjx
07:05degwhoops, thx
07:06RaynesSgeo: I don't think that existed when I wrote this.
07:07Sgeo: inc-bulls ( score -- score ) [ 1 + ] change-bulls
07:07SgeoRaynes: ah
07:07Sgeooh, forgot ;
07:12SgeoI wonder how one could go about sandboxing Factor
07:13SgeoThreads are co-operative. Maybe allow the user only a dictionary with words prepared such that yield will be forced
07:15cemerickRaynes: factor isn't active any more?
07:15p_lSgeo: or do an in-process version of how Android sandboxing works
07:16Sgeop_l: I have no idea how Android sandboxing works
07:16p_lSgeo: it load stuff into common "Zygote" process and then fork()s into processes running with different permissions
07:17p_la bit work and you can mmap() common data
07:17cemerickLast dev drop was yesterday, and the git repo is hopping.
07:18alfborgeIs clojars.org down?
07:21Raynescemerick: It isn't entirely non-active, but it isn't nearly as active as it was when Slava was around. But releases have always been a problem.
07:22cemerickWhat is he doing, if not Factor?
07:22RaynesActive or not, if they're not going to do releases and beginner documentation...
07:22SgeoThere was one release after Slava left, I think
07:22cemerickI missed the "Slava quits Factor" announcement, whenever that happened
07:25SgeoThere's an xkcd vocabulary included with Factor
07:25SgeoI just want to know why there's an XKCD: parsing word
07:26alfborgeNope, seems clojars.org is up but that I can't reach it :(
07:26Raynescemerick: Last Slava commit was a year ago.
07:27Sgeo: still-parsing? ( lexer -- ? ) [ line>> ] [ text>> length ] bi <= ;
07:27SgeoI actually understand that!
07:27SgeoIt looks simple now
07:27RaynesIt's a squiggly thingy, obviously.
07:28Sgeo(I mean, I would have understood it before, but it seems more intuitive now
07:28SgeoHow often are the spread and apply conbinators used?
07:28alfborgeAre there any clojars mirrors?
07:28SgeoI'd imagine those are less intuitive than cleave
07:29RaynesSgeo: I know nothing about Factor, just fyi. I've forgotten everything.
07:29SgeoOh
07:29Raynesalfborge: No. If it's down, you're free to panic.
07:29SgeoI was obsessed with it some years ago
07:30RaynesOh, you said it was up.
07:30RaynesBut yeah, no mirrors.
07:35alfborgeRaynes: I can't access it, but it seems to be a routing issue.
07:36alfborgeRaynes: a traceroute from my computer stops at router1-atl.linode.com.
07:39alfborgeSeems to be a fucked up routing table from my ISP. :/
07:40Raynesalfborge: Do you have a VPS or a server somewhere?
07:40Raynesssh -D 4000 you@yourserver.com gets you a SOCKS that you can set your network to use. I do that all the time because the mac app store doesn't like my Sprint connection.
07:41RaynesOr my sprint connection doesn't like the mac app store. Don't know which.
07:41RaynesEither way, SOCKS fixes it.
07:43alfborgeRaynes: Yeah, I've already done that :)
07:44alfborgeJust need to get lein to use my proxy :)
07:44Raynesalfborge: What OS?
07:45RaynesOn OS X, you can set your whole computer to use the proxy via advanced network settings.
07:45RaynesI would expect you to be able to do the same on other operating systems, but I don't know
07:45alfborgeRaynes: Unfortunately it's windows 8
07:45RaynesGet out of my internets.
07:46alfborgeAnd I have no idea how to run this thing :/
07:46RaynesHehe
07:48cemerickalfborge: you should be able to set the http_proxy env var; lein should pick that up
07:48Raynescemerick: On Windows?
07:49cemerickanywhere
07:49RaynesOkay.
07:49RaynesI believe you.
07:49RaynesBut your memory wanes in your old age.
07:49cemerickhttps://github.com/technomancy/leiningen/blob/master/leiningen-core/src/leiningen/core/classpath.clj#L87
07:49cemerickgtfo
07:49cemerickRaynes: but, of course, you're right
07:55alfborgethanks
08:48acron^is there an inverse to select-keys ?
08:49fredyrhttp://blog.jayfields.com/2011/01/clojure-select-keys-select-values-and.html
08:49fredyrthis maybe?
08:51acron^mmmm not quite
08:51acron^i mean i want something to exclude a key
08:51acron^(exclude-key {:a 1 :b 2} [:a]) => {:b 2}
08:53fredyri'll probably do an into {} filter
08:54acron^could you show me? i'm kinda new to clojure/
08:54ambrosebs,(disj {:a 1 :b 2} :a)
08:54clojurebot#<ClassCastException java.lang.ClassCastException: clojure.lang.PersistentArrayMap cannot be cast to clojure.lang.IPersistentSet>
08:54ambrosebsI forgot the name?
08:54ambrosebsdissoc
08:54acron^dissoc ?
08:55ambrosebsIsn't that what you want?
08:55acron^.(dissoc {:a 1 :b 2} :a)
08:55ambrosebsuse a comma
08:55acron^,(dissoc {:a 1 :b 2} :a)
08:55clojurebot{:b 2}
08:55acron^perfect
08:55acron^thank you!
08:55ambrosebs:)
08:56ambrosebsacron^: and if you have a sequence of keys to remove, use apply.
08:56fredyrah even better
08:56acron^,(apply {:a 1 :b 2 :c 3} [:a :c])
08:56clojurebot1
08:56acron^?
08:57ambrosebsapply dissoc
08:57acron^,(apply {:a 1 :b 2 :c 3} (dissoc [:a :c]))
08:57acron^,(apply {:a 1 :b 2 :c 3} (dissoc [:a :c]))
08:57clojurebot1
08:57clojurebot1
08:57ambrosebs,(apply dissoc {:a 1 :b 2 :c 3} [:a :c])
08:57clojurebot{:b 2}
08:57acron^cheers :<
08:58acron^I'll get used to this ;)
09:09hyPiRionApply takes a function, but a map can be treates as a function (lookup)
09:09hyPiRions/treates/treated
09:11acron^it's interesting
09:11acron^,(apply dissoc {:a 1 :b 2 :c 3} [:a])
09:11clojurebot{:c 3, :b 2}
09:12acron^why is the map now unordered?
09:12acron^I maps don't have 'ordering' as such
09:13hyPiRionMaps do not have ordering, no.
09:13hyPiRionYou could do sorted-map
09:13acron^Just seems odd :p
09:13hyPiRion,(sorted-map :a 1 :b 2)
09:13clojurebot{:a 1, :b 2}
09:14acron^the ordering isn't important to me
09:14hyPiRionAh.
09:16ToxicFrogacron^: it's not "now unordered", it was never ordered in the first place.
09:17acron^You know what I mean though
09:17ToxicFrog,{:a 1 :b 2 :c 3}
09:17clojurebot{:a 1, :c 3, :b 2}
09:17acron^ordered in the typographical sense
09:17acron^^ that's all I'm curious about
09:17acron^Why it gets re-arranged
09:17acron^It's not a problem for me
09:17ToxicFrogBecause when printing a map, it prints the keys in the order it walks them rather than collecting all of the keys, then sorting them lexicographically, and then constructing the output.
09:18acron^So why does it walk 0,2,1 ?
09:18ToxicFrogThey print "out of order" because that is the most convenient order in which to traverse the contents of the map.
09:18ToxicFrogFor a more detailed answer one of us will have to look at the map implementation.
09:18hyPiRionAnd here it is: http://blog.higher-order.net/2009/09/08/understanding-clojures-persistenthashmap-deftwice/
09:19hyPiRionIn case you're curious
09:19ToxicFrogIt doesn't walk "0,2,1". That implies ordering, and there isn't any. The "order" in which stuff is stored in the map has no relation to the order in which it's (assoc)'d or listed in the original {...}
09:20hyPiRionToxicFrog: It does walk a tree though.
09:20acron^ToxicFrog: Surely at the lowest level there is something indexable
09:21ToxicFrogacron^: that doesn't mean that the "index order" bears any relationship to what "looks" like the order when you write the map declaration, though
09:21acron^ToxicFrog: of course, you're right
09:22acron^ToxicFrog: it's just quirky to me that it would not translate directly
09:22acron^ToxicFrog: I'm sure there is a good reason
09:23ToxicFrogIn this case it looks like it's based on hash code (and I have no idea how the mapping from :symbols to hash codes works), with additional funtimes that mean internal map order neq hash code order.
09:28acron^Ok, back to noob mode
09:28acron^i defn'd the apply dissoc into an 'exclude-keys' function
09:29acron^e.g. (exclude-keys {:a 1 :b 2 :c 3} [:a])
09:29acron^how can i apply that fn to all maps in a list
09:30hyPiRion(map #(exclude-keys % [:a]) list-of-maps)
09:30hyPiRionBefore you ask:
09:30hyPiRion#(exclude-keys % [:a]) is the same as (fn [%] (exclude-keys % [:a]))
09:31acron^perfect again
09:39acron^this is so awesome
09:39acron^i love clojure
09:39acron^i could write my web app on a postcard it's that tiny
09:40fredyr:)
09:50degDoes clojure have a built-in function to collect the reduction steps (for lack of a better name) of a sequence. I.e, I'd use it to collect the first differences of a sequence of numbers: (f [1 2 3 5 6 7]) => [1 1 2 1 1]
09:52deg(typo'd "[" for "(" there, oops)
09:54hyPiRiondeg: reductions?
09:54hyPiRion,(reductions + [1 2 3 4 5])
09:54clojurebot(1 3 6 10 15)
09:54mdeboardhuh.
09:54hyPiRionOr wait, I read that wrong.
09:54mdeboardneat.
09:55hyPiRiondeg: I usually do ##(map (fn [[a b]] (- b a)) (partition 2 1 [1 2 3 5 6 7]))
09:55lazybot⇒ (1 1 2 1 1)
09:56deghyPiRion: Not quite... In your example, result should be (1 1 1 1)
09:56degoops, answered to your first one. one sec.
09:56hyPiRion,(partition 2 1 [1 2 3 5 6 7]) ; split
09:56clojurebot((1 2) (2 3) (3 5) (5 6) (6 7))
09:56degYup, that would do it. Does the partition add much inefficiency?
09:57hyPiRionI think it's lazy
09:57hyPiRion,(take 5 (partition 2 1 (range)))
09:57clojurebot((0 1) (1 2) (2 3) (3 4) (4 5))
09:57hyPiRionYeah, it's lazy, but it's possibly a bit slow. Though I wouldn't be too concerned unless that
09:57hyPiRionis an issue of yours.
09:58degI usually need all the results, so laziness doesn't buy me much. I'm more concerned about the cons'ing of the temp structure. Is that significant, or does Clojure optimize much of it away?
09:59squidzfor anybody who thinks 'The Joy of Clojure' gets difficult to understand at some point, what point would that be?
10:00degsquidz: I read it before writing a line of Clojure (but with significant long-ago lisp experience). I did fine on most of the bug, but got lost on some of the interop stuff and on zippers. (and maybe a few other parts near the end; it's been a few weeks so not sure)
10:00degs/bug/book/
10:00hyPiRiondeg: Well, do you work on a sequence?
10:01squidzdeg: thanks, I just wanted to know where I should take it particularly slow
10:01hyPiRion,(let [coll [1 2 3 5 6 7]] (mapv - (rest coll) coll))
10:01clojurebot[1 1 2 1 1]
10:02deghyPiRion: Yes, doing this on a sequence.
10:02degNice... never saw mapv before.
10:02hyPiRionThen the above wouldn't generate temporary elements. mapv is eager, map is lazy.
10:03hyPiRion(and creates a vector vs a lazy seq)
10:03degThanks, that looks perfect for me.
10:03hyPiRionanytime
10:04hyPiRion:)
10:04deg(I'm writing a tiny game, mostly to teach myself seesaw, to duplicate a hack that I wrote years ago, and just mentioned to my kids ... who of course now want to see it)
10:05degBasically, the player has to pick numbers and the computer tries to predict what the next number will be... it is incredibly hard for people to come up with numbers that are random enough that a simple program can't much better than blind chance.
10:06degSo, of course, my 12 year old thinks she can do so, and I'm trying to prove her wrong and learn some new APIs along the way.
10:06hyPiRionOh, cool.
10:10acron^hyPiRion: what's considered "lazy" in this context?
10:12ucbdeg: sounds cool, I'd like to learn a bit more about the prediction algorithm
10:15degucb: Well, I last wrote this about 1984, and no longer have the source code, so I'm recreating it now. But, I do recall that it was amazingly trivial and yet the only way I could beat it was by putting in "non-random random numbers" like lists of phone numbers. Any attempt to even randomly slap the keyboard would give patterns that the program could pick up.
10:15degSo far, I've just looked for the longest earlier subsequence that exactly matches the last numbers typed.
10:15degThat is if the user had typed [0 1 2 0 1], I would guess 2
10:16degEven this does well enough that it took my daughter a few minutes and a hint before she figured out how to beat it.
10:17degNext, I'm looking a first differences repeating, so if I see [0 2 4 6] I can guess that 8 is next.
10:17degThen, I'll look at interleaved subsequences so from [0 9 4 9 2 9 6 9 4 9 8 9 3], I'd predict 9
10:18ucbyeah, makes sense
10:18degAnd, finally, if the program finds no matches, it just guess randomly. Since it only has to beat random (that is, get it right more than 10% of the time on decimal integers), this let's it at least not lose ground when it sees no pattern.
10:18ucbsurely there's a way to automate that pattern-finding
10:19degMy guess is that this is all I'll need to have the computer win nearly always.
10:19ucbpossibly :)
10:20degucb: Not sure what you mean? meta-rules to capture each of those cases?
10:20ucbdeg: well, a way of discovering those meta-rules
10:20ucbdeg: if the computer played many people, perhaps those could be discovered automatically
10:20degProbably so, but meta-rules are really not much more than common subroutines, since the total "AI" code here is a few dozen lines, tops.
10:21ucbsure
10:21degMost of my time is going to figuring out seesaw and the underlying java graphics, to display this all nicely.
10:21degI need that for my real work, so it justifies this time playing.
10:21hyPiRionacron^: lazy means that the values aren't generated before they're used
10:21ucbI heard that seesaw will hide all the swing nasties from you, so it should be good :)
10:22ucbdeg: I was about to ask why not have a web interface which should be easier/quicker to implement
10:22degSpeaking of which, is anyone online here now who knows seesaw? I have some questions about it.
10:22hyPiRionacron^: That's a very short way of saying it.
10:22acron^hyPiRion: so if that values are definitely going to be used (I'm returning the maps as json), it's quicker to use mapv ?
10:23degucb: I've not yet looked at web interfaces from clojure. What are the best-practice libraries to use?
10:23hyPiRionacron^: I've not seen the implementation of mapv, but theoretically, yes.
10:23hyPiRionIt doesn't have the laziness overhead at least.
10:23TimMcUse map unless there's a need to do otherwise.
10:23acron^TimMc: trying to understand if this is a need to
10:24acron^deg; I'm using Noir and it's pretty good
10:24ucbdeg: not sure about best practises, but ring+compojure seems popular, then you have noir which is also popular
10:24ucbdeg: there aren't afaik, django/rails -like frameworks for clojure
10:24degSeesaw looks excellent, but under-documented. (Or maybe just assumes more jswing knowledge than my zero)
10:25hyPiRionucb: ring+compojure is more Clojure-idiomatic (close to no mutability) whereas noir has a lot of mutability
10:25ucbhyPiRion: ah, good point
10:26acron^moustache as well, but not updated in a while
10:26hyPiRionI'd say Noir is good to get working with Clojure for people new to it
10:27hyPiRionPeople tend to go compojure after some time with Clojure though, at least that's the trend I've seen.
10:27degk, I'll look at Noir. Any others?
10:28ucbdeg: noir is mostly for routing, page serving, auth and stuff, you'll need a way of rendering webpages. Noir has hiccup but I know there are other templating systems out there
10:28hyPiRionHiccup is probably the most used for templating.
10:30hyPiRionBoth compojure and noir users use it
10:30degI'd probably be looking more client-side web programming. I'd guess that the best starting path is clojurescript, but I've not had a chance to look at it at all.
10:31borkdudeWhat is the expected behavior when I press "run" on a CCW project in Eclipse?
10:32degAre the web-based tools sufficiently "ready for prime time" that I should ignore seesaw? For my purposes, I don't care if I'm browser-hosted or desktop-hosted, so if I shouldn't be wrestling java graphics, maybe I should move on.
10:33hyPiRiondeg: I don't know client-side, but the server-side stuff is pretty robust
10:33ucb+1
10:33degWow, either I'm reading very carelessly or my IRC client is doing weird stuff. Looking up, I see lines that I could swear were not there when I was typing earlier replies.
10:34nDuffdeg: The clojure/west slides talk about that (re: Seesaw usability for folks who don't know Swing already)
10:34degTotally missed the compojure lines above. Sorry if I gave some out-of-place replies.
10:34nDuffdeg: ...the doc strings _are_ pretty darned extensive.
10:35nDuff...but that said -- it's something that happened _because_ of the thou-shalt-know-Swing expectation that was there previously.
10:35degNDuff: I looked at that talk. It's excellent, but didn't take me far enough. For example, I can't figure out how to change the color of a text box after it has been already displayed.
10:35clgvdeg: do you know about seesaw.dev/show-options and show-events?
10:36degnDuff: I'm absolutely not criticizing the quality of the seesaw docs. They are amazingly good. Just, not enough examples once you get past the areas they've discussed.
10:36nDuff*nod*.
10:36degclgv: yes.
10:37clgvdeg: well, at some point you gotta read something about swing widgets. would be the same in any other GUI lib/framework ;)
10:37degI think the biggest piece I'm missing is the redisplay and dispatch models, that are presumably implicit to JSwing. Without that understanding, the rest of the pieces don't hang together well enough yet.
10:39degclgv: Yes, agreed. But, per above, maybe my tme is better spent learning the javascript/clojurescript world, rather than learning decade-old JSwing.
10:40clgvdeg: well swing is production approved and has this nice clojure wrapper. clojure script is still alpha though a lot of projects start to use it.
10:40deg(last decade+ my windowing background is Android and J2ME. Before that, Microsoft MFC, and before that many years of Symbolics. I've managed to bypass most of the J2SE/J2EE java worlds)
10:40degSounds like I need to play with both and learn all the toolsets.
10:41degSigh, life was so much easier when we just had to bang rocks together and hunt the occasional bison.
10:46TimMcYou don't find it easier now that all rocks conform to ISO 23089902?
10:50borkdudeis there a separate channel for ccw users?
10:51clgvborkdude: sometimes when lpetit and cemerick are around. but nothing permanent. but there is a ML
10:54clgvborkdude: what is your question?
10:55borkdudewhat should happen when I press run on a ccw project? should all clj files be loaded or not? (a blank repl starts) -- this is not really an issue for me, but a colleague is trying out clojure and he didn't expect this
10:55borkdudeand maybe one extra feature: if it's a ccw/leiningen project, should it obey the :main namespace(function) line?
10:59clgvborkdude: ah ok, that sound more like "bug report" or "feature request". you should make an "issue" on CCWs googlecode page.
11:02matthavenerlol TimMc
11:02ravsterhello everyone
11:03clgvborkdude: I usually start the repl by CTRL+S in the namespace I want to run it at first
11:03clgvborkdude: and eclipse's run should definitely use :main in a leiningen project
11:04borkdudeclgv ctrl+s just saves right?
11:05clgvborkdude: right. CTRL+ALT+S
11:05clgv"send to repl"
11:07borkdudeclgv another bug: when I create a new namespace and send it to repl:
11:07borkdudeclgv send a defn to repl that is: #<Namespace foo2>
11:07borkdudeCompilerException java.lang.RuntimeException: Unable to resolve symbol: defn in this context, compiling:(NO_SOURCE_PATH:2)
11:08borkdudeclgv I mean, when I just create a new namespace, but only send a fragment from that new namespace to the repl
11:08acron^is there any way to get Jetty to print the GET when running Noir with "lein run"? Literally banging my head against a wall
11:09clgvborkdude: oh never tried that. if you can reproduce it please create a detailed "issue"
11:09clgvborkdude: for convenience http://code.google.com/p/counterclockwise/issues/list ;)
11:14borkdudeclgv http://code.google.com/p/counterclockwise/issues/detail?id=484
11:15clgv:)
11:17borkdudeclgv http://code.google.com/p/counterclockwise/issues/detail?id=485
11:18clgvborkdude: ah you were the one giving a course using clojure ;)
11:18borkdudeclgv yeah, I'm preparing a bit for when it's running again… so Eclipse time ;)
11:19acron^http://pastebin.com/J1een60E
11:19acron^Can anyone see what's wrong? :/
11:19acron^It's just 404-ing
11:19mdeboardYes, you're using pastebin
11:19mdeboardyou're also missing a paren
11:20mdeboardline 3
11:20borkdudeacron^ how are you running the noir website?
11:20mdeboardneed another paren
11:20acron^borkdude: lein run
11:20borkdudeacron^ what mdeboard says
11:20nDuffmdeboard: You're willing to use the advertising-ridden POS that is pastebin.com for random strangers? I admire your altruism.
11:20acron^it didnt even error...
11:21borkdudeacron^ I advise you to explicitly require all your views in server.clj
11:21borkdudeacron^ this takes away much pain
11:21acron^how do you mean?
11:22borkdudeacron^ like this https://www.refheap.com/paste/7532
11:25acron^borkdude: is that in place of server/load-views-ns ?
11:25borkdudeacron^ yes
11:25acron^this will catch syntax errors?
11:25borkdudeacron^ probably you will see an error then
11:25borkdudeacron^ also load-views doesn't work properly within an uberjar (been bitten by that several times)
11:26borkdudeacron^ noir is being too clever sometimes
11:26acron^Ok, I'm giving this a go
11:26acron^I need to use an IDE or something really
11:26acron^I don't have any vim styles set up
11:27borkdudeI'm going now.. to a #clojure meeting !
11:27acron^Cool, have fun
11:27borkdudetnx
11:37mdeboardnDuff: What can I say
11:52bordatoueis there any way to import a buch of .jar files specified in the resource-path folder rather than explicitly specifying each one of them
11:54bordatouecurrently in my project.clj i have to specify each jar separately (for eg. :resource-paths ["etc/file1.jar" ... ... ]
11:55joegallojust for clarification, why can't you make them a normal dependency?
11:56bordatouejoegallo: i don't want them to be installed as a local repo
11:56dnolen`lynaghk: ping
11:57joegalloyou could concatenate them all into a single jar
11:57joegalloyou could write a leiningen hook that will do what you want
11:57bordatouejoegallo: this is one of major problem i am facing with lein
11:57callahadHey Raynes & nDuff -- I'm from the Persona team at Mozilla. bmaddy mentioned that you guys were having some issues?
11:58bordatouejoegallo: why can't it just work as lein v1
11:58clojurebotlein2 is Leiningen 2
11:58joegalloi don't know, i'm just some guy
11:59lynaghkdnolen`: pong
11:59bordatouejoegallo: apart from concatenating all into one jar , do you know about any other slolution to this
11:59dnolen`lynaghk: sorry for the delay I finally added the first cut of :when support to core.logic
12:00dnolen`lynaghk: http://gist.github.com/4269466
12:00lynaghkdnolen`: no prob---does that also include the constraint map stuff?
12:00dnolen`lynaghk: that's what I meant - the constraint map stuff.
12:00lynaghkah, yeah. awesome
12:01lynaghkdnolen`: mind if I pm you?
12:01dnolen`lynaghk: sure
12:02clgvI want to select the exception info object that has a certain JSchException as cause with Slingshot - how do I do that?
12:02clgvI tried several approaches but failed
12:05ravsterhow do I use ring to print out the body and headers of a request?
12:05weavejesterravster: In Ring a request is a map
12:05weavejesterThe body is on the :body key
12:05weavejesterThe headers are on the :headers key
12:06lynaghkdnolen`: we just shipped a consumer-facing ClojureScript-based iOS app to testers
12:06ravsterweavejester: ohokay. So I'll just pprint it.
12:06callahadtechnomancy: I saw in the logs that you mentioned Conkeror wasn't working with Persona. I'd really appreciate it if you could add more detail here: https://github.com/mozilla/browserid/issues/2858
12:07weavejesterravster: Yeah, though the :body is an inputstream, so you'll need to slurp it
12:07lynaghkdnolen`: have you heard of anyone else working in that space?
12:07ravstersweet, thanks.
12:09nDuffcallahad: heh, howdy. I was just complaining about the lack of interop with OpenID -- if I already have an OpenID identity with dual-factor auth &c., if I'm going to have a Persona identity as well, I want to be able to link the latter to the former.
12:09dnolen`lynaghk: SWEET
12:10dnolen`lynaghk: just embedded WebKit or are you going semi-native via JavaScriptCore?
12:10bordatoueis there any other alternative to lein when working with clojure
12:10lynaghkdnolen`: yes and no---it started as a really nice Cljs+C2 app, but then I had to rip out all of C2's DOM-walking stuff in favor of innerHTML-replacement string templating and start using JSON instead of CLJ for data interchange because the cljs reader is too damn slow =(
12:11lynaghkdnolen`: just embedded WebKit via Cordova (formerly PhoneGap)
12:11dnolen`lynaghk: yeah ... more stuff to work on!
12:11dnolen`lynaghk: still that's great would love to see a blog post on that
12:12clgvno slingshot users around? :(
12:12callahadnDuff: np, mind if we hop over to private messages to avoid spamming #clojure? :)
12:12nDuffSure.
12:13lynaghkdnolen`: yeah, it was definitely a "if I had a blog, this would be a good thing to write up" =)
12:13lynaghkdnolen`: I'm going to New Zealand for the next two months, so I might find a week in a cabin to sit down and put together a big comparison of different ways to mix cljs and js and perf numbers for iOS.
12:14lynaghkdnolen`: even if we end up using JavaScript data structures in the future, ClojureScript as CoffeeScript+ is still pretty rad.
12:15dakroneclgv: what was the slingshot question?
12:16clgvdakrone: how do catch the exceptioninfo that has a certain exception type as cause?
12:17solussddoes anybody know if Monger (the clojure MongoDB library) supports DBRefs? Also, does anyone have any strong feelings about DBRefs?
12:17NonIncGood evening! This noon I was watching part of the "Clojure for Java Programmers" screencast at blip.tv linked to at clojure.org . Now all the clojure related videos seem to be gone. Any hope of a mirror of some sort?
12:17dakroneclgv: I believe you can still use (catch MyExceptionType e ...) /cc scgilardi-
12:18dnolen`lynaghk: that would be awesome. Yeah I definitely there are many kinds of applications where dropping to JS data structures for perf reasons is necessary. especially on mobile hardware.
12:19scgilardi-dakrone: right, any valid catch cause for try is a valid catch clause for try+
12:20clgvno, the scenario is that I have root exception nested into some layers that were thrown with throw+ but the outermost wrapper is a normal exception
12:20clgvand I want the first exception info the one that has MyExceptionType as :cause
12:22dakroneI'm not sure about that, you may have to catch more than you're looking for and manually unwrap/rethrow
12:22clgvI thought slingshot does that for me?
12:22clgvor can slingshot only do that if everything is an ExceptionInfo?
12:22bordatouecan someone please provide suggestion on adding mulitple jar files using freaking lein2
12:23dakronebordatoue: you may have more luck getting a response in #leiningen
12:23dakroneclgv: it might do that for you, I'm not sure; I'd ask scgilardi-
12:23technomancybordatoue: you can put them in a remote repository or install them locally with lein-localrepo
12:23bordatouedakrone: thanks, just one question , is there any alternative to lein
12:23clgvscgilardi-: I also know the ":type" in the map of the first throw+
12:24dakronebordatoue: maven? O_o
12:24bordatouetechnomancy: i don't want to install them locally
12:24clgvscgilardi-: but that does not seem to work when the outermost wrapper is a normal exception
12:24technomancybordatoue: that's just how it works
12:24bordatouetechnomancy: i wanted to have them working as it did in lein v1
12:24technomancylein1 was silly
12:25bordatouetechnomancy: if use add-classpath in from repl can i add the jar files dynamically
12:25technomancyit only supported that because the tooling at the time (emacs, etc) sucked
12:25bordatouedakrone: i stay away from Maven
12:26dakronebordatoue: a wise decision
12:27scgilardi-clgv: for compatibility with try, slingshot doesn't do any special processing (e.g., unwrapping cause chains) of normal exceptions. in this case you'll have to do it yourself.
12:30ppppaulhey guys
12:30mpanhi
12:31ppppauli'm running a hello world ring server and i want to print the request to my console.... running via 'lein ring server'
12:31S11001001bordatoue: not really; it'll work in some contexts, not in others, because add-classpath only works sometimes
12:31ppppauli'm using (pprint request) as a middleware
12:31ppppaulnothing is being output to my console (not running in repl)
12:31S11001001bordatoue: but if you're just fetching resources, reading jars isn't hard
12:31bordatoueS11001001: is there any way to check the current classpath from the repl
12:32S11001001bordatoue: not really. You can get the java.class.path system property, but that's only an approximation
12:33S11001001the ClassLoader interface allows you to do more than fetch from particular filesystem and URL locations, so "the current classpath" isn't really meaningful
12:36bordatoueS11001001: i tried using add-classpath from repl, it say classloader is not dynamic
12:37S11001001bordatoue: yeah, that's what I said
12:43NonIncDoes anyone know what happend to the screencast link? It 404s sadly.
12:45ivanNonInc: which screencast
12:46NonIncthat one linked from clojure.org. actually it links to clojure.blip.tv which 404s for all clojure related videos
12:46technomancyblip.tv is annoying
12:47technomancythey stopped providing downloads to anyone not logged in via facebook a while ago
12:47S11001001technomancy: http://polsy.org.uk/play/blip/
12:47ivanwell, I have all the videos that were on blip, now you just have to get permission for me to copyright-violate
12:47technomancyS11001001: nice; thanks
12:47NonIncpersonally i did not know about it till today. i was just watching a tutorial about clojure there and now i cannot finish it wich i am kinda sad about because i liked hickes talk.
12:48S11001001technomancy: may have to set referer on download to http://blip.tv/
12:48S11001001they keep messing with it
12:49ivanNonInc: hasn't been brought up on the list yet
12:49NonInchttp://blip.tv/clojure/clojure-for-java-programmers-1-of-2-989128 on S11001001 s site does not work anymore either
12:50NonIncyou do not eventually have a download of that videos or a mirror? eg i found a mirror of the sequence related screencast on the list
13:04dnolen`not sure how many people have written core.logic code that tests output involving fresh vars
13:04dnolen`but I'm changing _.0 -> _0, since the former is not a valid symbol for actual Clojure source.
13:05scottjNonInc: I'm not logged into blip, but it looks like all the clojure videos have been removed. perhaps they're moving them to another service in preparation for uploading the conj videos.
13:05NonInci hope so thanks for the info
13:05pyrtsa+1 for _0 etc.
13:19dnolen`core.logic 0.8.0-beta3 going out
13:20ivaraasendnolen`: sweet. I'm using core.logic it to aid my uni studies
13:21dnolen`ivaraasen: very cool! how are you using it?
13:22ivaraasendnolen`: basically to learn more about declarative programming. I'm having a course next year teaching programming paradigms using Oz/Mozart
13:23dnolen`ivaraasen: ah, that's great :)
13:28gtrakhow do I copy arglist metadata from another function into my new function?
13:32ivaraasendnolen`: also, I believe some of my professors use Prolog for simulations (to do domain decomposition/grid partitioning). will definitely be exploring this option with core.logic
13:36gtraknm, I got it, (defn new-fn {:arglists (-> #'old-fn meta arglists)}...
13:36gtrak(defn new-fn {:arglists (-> #'old-fn meta :arglists)}... rather
13:37cemerickRaynes: bultitude should str-ify prefixes so you can provide symbols
13:38ohpauleezcemerick: When you have some downtime, I want to pick your brain on Clojure Web stuff - totally not urgent
13:39amalloyppppaul: *out* doesn't demultiplex from N threads to one stdout. messages sent from non-repl threads vanish into the void unless you change their *out*
13:39cemerickohpauleez: Sure :-) Catch me Friday; mostly heads-down today and tomorrow
13:40ohpauleezcemerick: will do! Thanks
13:40lynaghkcemerick, ohpauleez: when are we going to podcast?
13:40lynaghkHacker real world?
13:40cemericklynaghk: so many opportunities past!
13:40ohpauleezlynaghk: cemerick: Not a bad idea - it'd be cool to do it in person
13:40cemerickWorks for me, but that's a while from now
13:41cemerickI was planning on hitting the west coast in January, but it might be Amsterdam instead
13:41lynaghkcemerick: come out to New Zealand or Japan and we can party over there
13:41cemericklynaghk, ohpauleez: Skype friday?
13:42ohpauleezcemerick: lynaghk: depending on the time, that would work for me
13:42lynaghkcemerick, ohpauleez: yeah, I could do that; my schedule is flexible
13:42cemericklynaghk: dunno if I could keep up with your worldwide rave
13:42ohpauleezample time for the community to hound us with questions
13:42ohpauleez:)
13:43lynaghkohpauleez, cemerick: shoot me an email with a good time for both of you---I really am free all Friday (at the moment).
13:44ohpauleezdnolen: quick question - do you think the constraint stuff is mostly locked in? I want to use it to solve the Coin Change Kata (as an example)
13:44cemerick_awaylynaghk: let's say 1pm EST, and ohpauleez can complain if necessary ;-)
13:44ohpauleezworks for me 1-2ish
13:45dnolenhttp://github.com/namin/TAPL-in-miniKanren-cKanren-core.logic/pull/1
13:45dnolenDan & Will's quine generator now really works in Clojure.
13:45lynaghkohpauleez: you should gist that. aperiodic and I tried to solve it a bar using core.logic and we ran into some snags
13:46ohpauleezdnolen: sick!
13:46ohpauleezlynaghk: Dec 20th (sadly you're gone), Clojerks swarm coding on the Coin Kata
13:46ohpauleezaperiodic: ^^
13:46ohpauleezif you can make it
13:47ohpauleezlynaghk: so all code will be gist'd and/or in a repo somewhere
13:47lynaghkohpauleez: maybe I can dial in from the south pacific.
13:47ohpauleezlynaghk: That would be sick - the remote session will be on one of my servers (west coast data center)
13:47technomancywe've thought about doing all-virtual swarming
13:48technomancyI think it's a cool idea, but I think mixing it with an in-person one would be awful unless you had a serious pro-level AV guy
13:48lynaghktechnomancy, ohpauleez: isn't there a Y-combinator startup that puts ipads on segways or something? Remote telepresence.
13:49ohpauleezhahahaha
13:49ohpauleezthat joke never gets old
13:49technomancyheh
13:49technomancyvideo is easy; audio is insanely difficult
13:49technomancyhe said as a remote worker for a company that is mostly based out of an office
13:50ravsterhow do I send a break signal from emacs into nrepl? I've got a function that starts a server, but then it doesn't give me my prompt back.
13:51jasonbrayC-c C-b
13:51ravsterthat did it, thank you jasonbray
13:54weavejesterdakrone: clj-http redirect bug fix sent your way :)
13:55dakroneweavejester: awesome, thanks
13:59TimMcTAPL in miniKanren and core.logic? This is relevant to my interests.
14:50ravsteranyone with ring.middleware.basic-auth experience here? We're having issues with using its 'wrap-basic-auth' function. Keeps giving errors of the 'wrong number of arguments' type
14:50gfredericks,in-ns
14:50weavejesterHow many arguments are you giving it? :)
14:50clojurebot#< clojure.lang.RT$1@1cdce97>
14:52ravster2 , one handler and one 'authenticate' function that we made.
14:52ravsterweavejester: which basic auth system do you use?
14:52weavejesterravster: Where is the library repo? I've tried the ring.middleware.basic-authentication, but not basic-auth
14:53weavejesterThough in the end I just wrote my own because I wanted something slightly different
14:53ravsterhttps://github.com/remvee/ring-basic-authentication, weavejester
14:54weavejesterravster: That's the one I used for a bit
14:54ravsteroh
14:54weavejesterravster: It seemed to work for me
14:54weavejesterravster: What does your code look like?
14:55ravster(wrap-basic-auth (POST ....stuff ....) authenticate )
14:56weavejesterravster: wrap-basic-auth or wrap-basic-authentication ?
14:57ravsterwrap-basic-auth
14:57weavejesterI thought you said you were using: https://github.com/remvee/ring-basic-authentication
15:00ravsteroh yikes, I think I'm using weird code.
15:12aaelonyI have a silly question.. How do I determine the correct namespace to use or require for user-agent-utils (https://clojars.org/user-agent-utils) ?
15:13noidiaaelony, for Java libraries, you have to use import
15:14aaelonynoidi: thank-you
15:14noidi(ns aaelony.project.core (:import nl.bitwalker.useragentutils.Application))
15:15aaelonyperfect, thanks.
15:15noidiif you have to import multiple classes, you can use a list as a parameter to import:
15:15noidi(ns aaelony.project.core (:import (nl.bitwalker.useragentutils Application Browser)))
15:15aaelonyyeah, I'll be using :import
15:15noidithat way you don't have to repeat the package name for each class/interface
15:16aaelonyalthougth I tend to use (:import [ … ] )
15:16aaelonywith square brackets
15:18noidiyeah, vectors work too, but the reason I prefer lists is that they signify that the first item is special and different from the rest
15:18noidiif you drop Browser onto the next line, the text editor will indent it under Application
15:19noidibut if you use a vector, it will get indented under the package name
15:19aaelonyfor some silly reason, i like the vector version
15:19aaelonye.g. (:import [nl.bitwalker.useragentutils Application Browser BrowserType DeviceType Manufacturer OperatingSystem RenderingEngine UserAgent Version])
15:20noidiyeah, I used to prefer vectors too, until I heard this rationale from someone (I think technomancy) and then I switched :)
15:20aaelonyI'm open minded :)
15:20tomojif you could have nested prefix lists it would seem to matter more
15:21aaelonysuppose I have log line with escaped strings embedded, is there an elegant way to unescape?
15:22noidiwhat do you mean by escaped strings?
15:23noidii.e. is this a text editor question or a clojure question? :)
15:23aaelonystuff like "\"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_5_8) AppleWebKit/534.50.2 (KHTML, like Gecko) Version/5.0.6 Safari/533.22.3\" \"-\""
15:23aaelonyperhaps ring.util.codec/url-decode will help me...
15:24aaelonyor something similar
15:25tomojwhat prints it?
15:25aaelonytomoj: I'm a downstream consumer, that's how it appears for me
15:26aaelonyI'm currently doing .replaceAll style cleanings, but I'm sure there are better ways
15:26tomojbut you don't know what prints it? how can you expect to unescape it correctly?
15:26noidiso the input string is (in Clojure literal notation) "\\\"Mozilla ...\\\"" and you want to turn it into "\"Mozilla\"" ?
15:27aaelonyI know what prints it, however I must accept and process it the way it appears.
15:27aaelonyyes
15:27hcumberd`Hi ;)
15:28aaelonymore precisely, I'd like to prepare it such that useragentutils can munge and parse it
15:28tomojso what prints it? not a jvm?
15:28hcumberd`What do you think is the avg. income of a clojure specialist in the US?
15:29arkxhcumberd`: why do you care?
15:29aaelonytomoj: yeah, not the jvm. probably node.js
15:29hcumberd`Had a discussion with someone from a company
15:29tomojso the reader won't really work
15:29hcumberd`About that it wouldn't be possible to get resources and so on
15:29TimMchcumberd`: Hmm, check glassdoor.
15:30tomojyou'd have to find some unescaper specifically designed for js, no?
15:30hcumberd`What's glassdoor?
15:30tomojor replaceAll :)
15:30aaelonytomoj: that's what I've found as well, but if I prep it, it might...
15:30aaelonyreplaceAll works pretty well, kinda ugly though
15:31TimMchcumberd`: A salary reporting website. You post your position, location, industry, and salary, and you get to see stats on other people's reports. I have an account, but I don't want to use it while I'm at work. :-P
15:31hcumberd`0 salaries found for clojure
15:31tomojreplaceAll works for the subset of escapes you're currently interested in, presumably?
15:31eggheadlol
15:31eggheadquick let's all post our salaries
15:31eggheadyou first
15:31TimMcI can't imagine it wouldn't be much different than for other programming positions.
15:31aaelonytomoj: yes, but I'd prefer a more general, battle-tested solution
15:32noidiaaelony, clojure has one built-in, after all, it has to read all the string literals in your source code :)
15:32noidi,(let [input "foo \\\"bar\\\" baz"] (read-string (str \" input \")))
15:32clojurebot"foo \"bar\" baz"
15:33aaelonyvery cool. I'll try read-string
15:33hcumberd`TimMc: there are not so many people on the market
15:33hcumberd`so prices are higher than JEE and so on
15:34noidiaaelony, don't be confused by the name. it's for reading any clojure data structures _from_ strings, not for reading strings!
15:34noidi,(read-string "[1 2 3]")
15:34clojurebot[1 2 3]
15:34TimMchcumberd`: It's hard to hire *any* programmers right now anyway.
15:34aaelonyi get it
15:34tomojbut that's for clojure string literals, not js
15:34hcumberd`I know. Will be self-employed in 2013
15:34tomojdifferences might not bite you, I don't even know what they are
15:34brehautTimMc: things i'd never want to do include signing into a salary / jobs site with my social network credentials
15:34aaelonyit may work, will test it
15:34aaelonythanks again for the tip :)
15:35TimMcbrehaut: I'm on there, but I don't have it connected to any SNS.
15:35nDuffTimMc: ...so, I'm at Indeed; looking at GlassDoor would be competitive analysis. :)
15:35brehautTimMc: it wanted me to sign in using my facebook credentials
15:35brehaut(which i dont have)
15:35TimMcbrehaut: Huh. That's... cute.
15:36brehautthats certainly one way to spell fail :)
15:36TimMcnDuff: Indeed does a similar thing?
15:36hcumberd`Haha ;)
15:37nDuffTimMc: I think we've rolled functionality like that at some point, though our core focus is and has always been job search.
15:38FoxboronI have a theory. I believe the only reason why someone want to learn CLojure is because they have secret desires after an afro and a beard.
15:38brehautFoxboron: i think you are thinking of core.logic
15:38TimMcFoxboron: *gasp* my secret is out!
15:39hcumberd`mhhh beards ;)
15:40TimMcIt's not difficult for me, though -- I inherited crazy hair via my Scottish + Jewish ancestry.
15:41Foxboronbrehaut, core.logic contains code to let someone grow an afro and beard?
15:41Foxborondayum
15:42brehautFoxboron: http://skillsmatter.com/podcast/scala/the-refined-clojurist
15:42tomojone.test/ensure-ns-loaded: "We need this because in some situations, we wind up trying to run code that depends on a namespace that isn't available yet, due to asynchrony in the browser."
15:42tomojwhat does that mean?
15:43hcumberd`In germany are only a few clojure people out there ;(
15:43tomojsituations other than putting the one compiled cljs file in the head or at the bottom of the body?
15:43hcumberd`Scala seems to be more popular. Maybe because it is much worse compared to java...
15:43tomoj<script async ...> ?
15:47arkxhcumberd`: I don't think Clojure (or Scala for that matter) is at the stage where you have a good supply of people who already know it available. It's a mistake to only look for "Clojure people", look for people interested in FP instead.
15:48hugoddnolen: great to see the core.logic release :)
16:19Raynescallahad: Oh hi.
16:19hcumberd`arkx: yes, you're right
16:19degWhat is the best convention for indenting cond clauses in Clojure? Standard indentation seems not to work as well as in Lisp, since the predicates are not nested inside each clause.
16:20Raynescallahad: I can't really remember what nDuff was talking about yesterday, but I don't have any gripes myself. technomancy notes that Persona doesn't work with his web browser, Conkeror (not the KDE browser with a K).
16:20Raynescallahad: The context is my pastebin, https://www.refheap.com
16:21hcumberd`what is the most awesome feature of emacs? ,)
16:21hcumberd`org-mode?
16:21hiredmanmaybe ask in #emacs?
16:21AimHereM-x psychoanalyze-pinhead
16:21cmiles74easy customizability?
16:21technomancyhcumberd`: being written in lisp is the only feature that matters
16:22nDuffRaynes: ...FWIW, my principal beef was lack of delegation to OpenID -- something on the roadmap to be fixed for major providers quite soon; perhaps less so for my own personal (less usual) use case, but that's not as much of a big deal.
16:22RaynesnDuff: Tell callahad, not me. :p
16:22RaynesOh, I guess you already did then
16:22Raynes?
16:22hcumberd`technomancy: are you also programming CL?
16:22nDuffRaynes: Did already -- just summarized a longer conversation I had with callahad this morning for the case where you were interested.
16:23nDuffs/already/indeed/
16:23RaynesOh, great.
16:23RaynesYeah my backlog doesn't go back that far.
16:23technomancyhcumberd`: no, I gave up on CL in 06
16:23hcumberd`;(
16:26RaynesDamn it, technomancy even talked to him about conkeror.
16:29technomancyI had my blog hosted on CL for like 6 months at one point
16:30tomojhuh, 1.21s on "SSL" for login.persona.org/include.js
16:30TimMcnDuff: Apparently they've fixed whatever was preventing Persona from working with Firefox's password manager, at least in source.
16:31TimMcI may give it another go, lack of OpenID support notwithstanding.
16:31tomojwonder if it would be safe to load include.js async?
16:32tomojrarely I have to wait 5+ seconds for persona before anything shows up on refheap
16:34tomojmaybe that's just a conkeror problem
16:35tomojor my shitty connection..
17:00hcumberd`Does ring automatically keep track of tempfiles?
17:05nDuffIs there anything out-of-the-box for taking a series of lazy sorted sequences and efficiently emitting a single, sorted stream of output?
17:05amalloynDuff: https://github.com/flatland/useful/blob/develop/src/flatland/useful/seq.clj#L259
17:06nDuffamalloy: nice; thanks!
17:14lynaghkI'm trying to call the -main fn of a Java program from my Clojure code. This works great, but it's filled with statics and I'd like to call it in parallel
17:14lynaghkIs there any clever way of doing this? Or do I need to maintain a queue in my Clojure program and ensure that this Java thing is being accessed in serial by my things?
17:15callahadTimMc: Let me know if you have any questions / run into any problems. The team hangs out in #identity on irc.mozilla.org
17:17hiredmanlynaghk: there is no mechanism like that, but depending on what you want you might be able to just use an agent
17:17lynaghkhiredman: yeah, I was just looking at the docstring
17:17callahadRaynes: Gotcha, thanks! ^ goes for you. The Persona team would love any/all feedback you have. (And if you're ever in MN, I'm sure that I, bmaddy, and tmarble would love to see you stop by clojre.mn ;))
17:17lynaghkthe parallelization is for downloading stuff; I think the processing is actually very fast, so I might just pmap the downloads and then run the processing.
17:17callahads/clojre/clojure
17:18Raynescallahad: Thanks. :)
17:18amalloyoffer to buy him a drink. he always gets a laugh out of that
17:18RaynesHah
17:18RaynesIndeed.
17:19brehautRaynes: if ever you are in NZ i'll buy you a drink
17:20Raynesbrehaut: Eh, I can actually drink in NZ.
17:20brehautyup
17:20brehautthe jokes not so funny now eh
17:20brehautsorry
17:20RaynesIt's funnier when they offer me a drink because they don't know my age.
17:21technomancymurica is weird like that
17:21hcumberd`Raynes: how old r u ?
17:21Raynesi r 18
17:21hcumberd`wow,... awesomeness
17:21brehauttechnomancy: i think the drinking age should be put back to 21 here too
17:21hcumberd`me @ 18 = php
17:22Raynes;)
17:22hcumberd`drinking age here = 16 - 18 depending on drink
17:22technomancybrehaut: well ideally people should just learn to act like adults sooner in life, but I know that's a lot to ask
17:22brehauttechnomancy: yeah that would be nice wouldnt it. instead we have more drunken idiots vomiting and fighting in town.
17:24pipelineputting back the drinking age doesn't fix anything
17:24pipelineyou just have 21 year olds getting hammered and fighting instead of 18 year olds
17:25brehautobviously
17:25bbloomas somebody who was given wine sometimes as a kid, but never really had any caffeine, i can say with certainty that my initial learning experience with coffee was far more disastrous than my 21st birthday
17:25brehautbut less idiots fighting is still an improvement
17:25callahadI'd like to age_driving > age_drinking
17:25callahadFigure that stuff out before you have access to heavy machinery
17:25technomancybrehaut: surely you have police? =)
17:26pipelinecallahad: that seems impossible in america
17:26pipelineyou need a car
17:26mthvedti think in general it's a poor strategy to increase responsibility by delaying it
17:26pipelinealso drunk driving is pretty much a way of life in most of the country
17:26brehauttechnomancy: yup. they spend all the time dealing with drunken idiots
17:26pipelineif america were serious about drunken driving as a problem, we would have much stricter laws
17:27bbloompipeline: if america was serious about drunk driving as a problem, we would have much BETTER PUBLIC TRANSIT
17:27bbloom:-P
17:28pipelinebbloom: tbf public transit doesn't work very well anywhere in the world
17:28pipelinebut that is a huge and difficult off-topic discussion ;)
17:28technomancypipeline: it's amazing in Singapore
17:28nDuffpipeline: The Shinkansen line is bloody amazing.
17:28technomancybecause they tax cars >100%
17:29lynaghkhiredman: the pmap approach works but the remote server is angry about the multiple connections; is it possible to limit the number of threads used by pmap?
17:29pipelinesingapore and the shinkansen are both mass transit in extremely high density areas
17:29cemerick_awaygiven autonomous cars, public transit is a waste
17:29pipelinemost public transit in most countries is busses
17:29pipelineand busses do not work well
17:29pipelinepeople people overwhelmingly prefer not to ride them
17:29technomancymy sixth-grade brother took the train across the entire country on his own
17:29hiredmanlynaghk: not really, pmap kind of stinks
17:29nDuffpipeline: ...but even short of that -- the mass transit system is part of why my fiancee wants to get back to Chicago RSN.
17:29pipelinebus rapid transit works very well, but it only costs slightly less than other forms of mass transit and has massively less capacity :(
17:30nDuffcemerick: I can't agree at all -- making cars autonomous only fixes a small part of the problem.
17:30hiredmanlynaghk: seq chunking can interfere with pmap, so if you unchunk the seq you might get fewer threads
17:30hcumberd`Idiots are idiots, regardless of drinking age or whatever
17:30cemericknDuff: not clear what problem we're talking about ;-)
17:30hcumberd`They will even vomit and fight without alcohol
17:30lynaghkhiredman: I'd prefer to have explicit control, I'll keep digging around
17:31pipelinetechnomancy: singapore has something even more awesome than transit: realistic road taxes and real-time congestion prices
17:31hiredmanlynaghk: have you seen sequeue?
17:31pipelinetechnomancy: i would kill to have singapore-style congestion pricing in nyc
17:31hiredmanseque
17:31hiredman,(doc seque)
17:31clojurebot"([s] [n-or-q s]); Creates a queued seq on another (presumably lazy) seq s. The queued seq will produce a concrete seq in the background, and can get up to n items ahead of the consumer. n-or-q can be an integer n buffer size, or an instance of java.util.concurrent BlockingQueue. Note that reading from a seque can block if the reader gets ahead of the producer."
17:31technomancypipeline: it is a sight to behold
17:31technomancyvery unamerican though
17:31pipelinemanhattan is not like anything else in america though
17:32technomancyI suppose not
17:32pipelineand already has unamerican things going for it, like no minimum parking rate for office space
17:32nDuffcemerick: ...the set of problems, rather -- public health, scalability (resizing roads to increase automobile throughput is extremely expensive), storage/ownership costs (the amount of prime real estate spent on parking is insane)...
17:32hiredmanlynaghk: you can create your own seque + futures pmap kind of thing
17:32lynaghkhiredman: oh, that looks promising. thanks!
17:32technomancypdoseq!
17:32amalloyhiredman: seque has some serious problems too, gorgeous an idea as it is
17:33hiredmanamalloy: yes, but I've never used it so I can completely ignore those :)
17:33amalloy1.5 includes a patch from me to fix one of the issues: it no longer leaks threads all over the place
17:33cemericknDuff: once cars don't need drivers, the number of cars on the road should drop significantly
17:33lynaghkamalloy: it l
17:33nDuffcemerick: self-driving cars help some of the equal-accesss issues, have potential to reduce loss-of-life, and _can_ help with parking / ownership costs if private ownership is reduced in favor of a large-scale carshare model, so it's better than nothing, granted...
17:34technomancycemerick: because the cars will find a nice country garage in which to settle down and be done with all those annoying humans for good? =)
17:34lynaghkamalloy: it leaks threads? my use case is just batch downloading and processing, but it's going to take a few days so if stuff is leaking that could be an issue
17:34nDuffcemerick: ...but a bunch of tiny ICUs is still not nearly as efficient as a train engine, and you still don't have nearly the high-density throughput (or the public health benefits) of short-distance cycling.
17:34amalloylynaghk: it leaks threads depending on your performance profile. iirc if you can consume items faster than they're produced, you lose one thread per time you call seque
17:35hcumberd`do you like cars?
17:35hiredmanI would do queues and executors
17:35cemericktechnomancy: either that, or they'll all start causing head-on collisions in order to thin the herd
17:35nDuff...well, you _could_ probably get good throughput if you allowed *only* self-driving cars on the roads, but that's a way off.
17:35hiredmanone threadpool executor limited to the number of concurrent downloads you want, one single threaded executor doing the execution of whatever java
17:35amalloyanother issue is that because seque uses agents under the hood, if you try to call it from within an agent action you're just deadlocked forever
17:35TimMcnDuff: Just don't take away my bicycle.
17:36cemericknDuff: I take cars + optimism as a given. :-)
17:36amalloyi do have https://github.com/flatland/useful/blob/develop/src/flatland/useful/seq.clj#L286 available which uses a future instead of an agent; i've never gotten around to doing it "right" with a custom executor like hiredman suggests
17:36hiredmanyou submit all your download tasks, and as they finish they submit tasks to run the java
17:37lynaghkhiredman: yeah, that sounds good to me. I was just wondering if there were Clojure wrappers for that knid of stuff
17:37hiredmannope
17:37lynaghkhiredman: I'll give that a shot, thanks for the info
17:38hiredmanmy only complaint with executors is the lack of delegating
17:39hiredman"give me a schedule executor that schedules tasks on this other executor"
17:48dsopanyway to get leinigen filespecs to work with ring war?
18:23tomojhmm.. if we're validating 'if arity, shouldn't we also check whether there are too many arguments?
18:31ravsterI have nrepl and nrepl-interaction-mode enabled in emacs. I can do the load-buffer command and that works. But when I change the definition of anything and I C-xCe it, it doesn't show up as a different value in the buffer.
18:32ravsterhow do I get this fixed so that the repl syncs up with the changes?
18:33technomancyravster: I think you need to do C-c C-k first
18:33technomancywhich is really annoying IMO
18:33dsevillaguys, I suppose this has been asked thousand times
18:33dsevillabut I don't quite find what I need
18:33ravstertechnomancy: so I should C-cC-k everytime I make a change?
18:34dsevillaI would like to have a somewhat fast guide to Clojure given I know Common Lisp and Emacs Lisp
18:34technomancyravster: oh, it should be just once
18:34dsevillaTexts I've seen are so much introductory
18:34technomancymaybe you're talking about a different problem
18:34nDuffravster: Can you give a more explicit description of how to reproduce the behavior you're seeing?
18:34dsevillaand too long for one that knows some lisps
18:34nDuffravster: in the general case, changes made from nREPL take immediate effect. There are exceptions, but they're... well, exceptional.
18:34technomancydsevilla: the "Clojure for Lisp programmers" video formerly on blip.tv was the best for that particular audience
18:34technomancydsevilla: unfortunately they seem to have removed it
18:34technomancysomebody mentioned having it saved locally though
18:35technomancysomeone in this channel
18:35dsevillatechnomancy: mmm... I'll look for it, thanks
18:35ravsternDuff: done C-cC-k to get file loaded in repl. Changed something. Did a C-xC-e after that sexp, and then the change wasn't reflected in repl.
18:35nDuff"something" is vague. "wasn't reflected" is vague.
18:36ravsterI had '(def foo "foo")', which I changed to (def foo "bar")
18:36technomancyravster: it could be C-x C-e is using the wrong namespace
18:37nDuffravster: ...okay, that's a case that _definitely_ will work, if you're set up right.
18:37technomancymaybe check user/foo?
18:37technomancynrepl.el's method of calculating what namespace the current buffer should use is broken IMO
18:37nDuffravster: C-x C-e generally takes effect in the namespace declared in the buffer -- did the one in the repl match it?
18:37nDuff...what does your namespace declaration look like?
18:38nDuff(could you post the full contents of the buffer you're reproducing with?)
18:38ravsternDuff: yup, only one file right now.
18:38dsevillatechnomancy: seem to be slides with this same name by Hickey
18:39ravsternDuff: http://pastebin.com/pVMa7Nmz
18:39technomancydsevilla: the main gotchas are going to be: laziness, much fewer implicit progns, and vars as storage locations instead of symbols
18:39technomancydsevilla: if you haven't read Equal Rights for Functional Objects that's a great place to start
18:39nDuffravster: ...somewhere without animated ads, maybe?
18:40ravstersure :$ sorry
18:40nDuff(refheap is a favorite around here, btw)
18:41ravsterhttps://www.refheap.com/paste/7540
18:42dsevillatechnomancy: I'll take a look at it. Yes, I'm interested in laziness, and also in idiomatic data structures
18:45ravsterweird, right? I thought it would just update things.
18:45ravsterC-cC-k works, though
18:45nDuffravster: ...so, it works fine for me.
18:45ravsteroh, here we go.
18:45nDuffravster: (took a minute to be set up to reproduce)
18:46ravsterIn the minibuffer it displays '#user/bar
18:46ravsterbut the repl is using hello-world.core namespace
18:46nDuff...started nrepl, ran C-c C-k, (ns hello-world.core), foo, C-x C-e, foo
18:46nDuffravster: ...so, what's your workflow?
18:47ravsterI didn't do (ns hello-world.core)
18:47ravsterI did C-cM-o
18:47nDuffthen your repl is still in the user ns
18:47ravstersorry M-n
18:47nDuffNot familiar with that one, and my local emacs tells me it's undefined
18:48ravsterokay. Will try again. with (ns foo) call
18:50amalloynDuff: in non-ancient versions of nrepl.el, C-c M-n sets the repl ns to the buffer ns
18:55ravsternop. didn't work. C-xC-e still evaluates in the user namespace
18:57technomancyravster: maybe open an issue on nrepl.el
18:57technomancyI've argued against that implementation; maybe some more supporting evidence will help make a case for doing it the "right" way =)
19:00hiredmanclojurebot: ping
19:00clojurebotPONG!
19:05Rirzehello1
19:06Rirzeis anyone active?
19:06gtrakdoes anyone have an emacs shortcut that wraps the next 2 sexps in a def and runs it? would be useful for stepping through lets
19:07gtrakI guess I can use a macro
19:11RirzeDoes any have an idea on how to make a map function that goes through the entire (nested) arguments? (presume they are identical in shape)
19:12technomancyRirze: you could map over a tree-seq
19:12technomancyoh, but that won't preserve the shape
19:13mthvedtRirze: perhaps some kind of recursive fn that maps itself
19:14mthvedt(fn f [arg] (if (seq arg) (map f arg) (…)))
19:14RirzeI got that far, and it works for a specified num of args, but I can't make it argument-number-independent. (using & rest)
19:14mthvedtyou would have to make sure the leaves aren't seqs, or else a more complicated variation thereof
19:14Rirzei'm using sequential? for the if
19:14Rirzeis that equivalent?
19:15mthvedtbelieve so
19:15mthvedtactually, no
19:15amalloyno, cause sequential? will work and seq won't :P
19:15Rirze:)
19:16Rirzeso here's what I have
19:16Rirze(defn go-through ([op & args] (if-not (sequential? (first args)) (apply op args) ...
19:17RirzeI can't get it to recur correctly on the "else" statement.
19:17mthvedti'm not sure what this is trying to do, i may have misunderstood the question
19:18Rirzehmmm... ok, so I'm a bit new, so fix me if I am constructing this wrong:
19:18Rirzeit takes an function and the rest of the arguments are put into args
19:19RirzeI check if the first in args is a sequential and if it is, then I just apply the function
19:22mthvedtthought you were trying to map
19:24RirzeI am... but I want to deal with each element in a sequential individually.
19:24mthvedti don't think you can do anything like that using apply...
19:24mthvedt(apply f seq) will call f once, (map f seq) will call f n times
19:25Rirzeis there an other way?
19:25Rirzewell, actually I'm #(apply map %)
19:26Rirzethat's the part I'm trying to figure out- I didn't put that in the function definition.
19:28cemerickweavejester: I'm using a path like "/foo" with link-to and a with-base-url of e.g. "/bar" ... yet I'm seeing hrefs like "/bar/foo". What am I missing?
19:30mattmossZippers?
19:35ppppaulhey guys
19:35ppppauli'm having trouble with ring's session wrapper
19:36ppppauli'm not getting any session data generated and also no cookie is being applied to my responses
19:36mthvedtRirze: still don't understand… if you have something like [[1 2] [3 4]] do you want to be able to map inc and get something like [[2 3] [4 5]]
19:42ravstershould wrap-session go at the end of the handler evaluation, or at the beginning?
19:43xeqijcrossley3: I'm looking forward to seeing the immutant + openshift auto scaling stuff
19:44jcrossley3xeqi: me, too. we're so close.
19:44jcrossley3xeqi: actually, i think they have a fix. it just needs to be packaged
19:45jcrossley3xeqi: yeah, he added some patches today: https://bugzilla.redhat.com/show_bug.cgi?id=883944
20:04Rirzemthvedt, if you're still here, what I meant was a function can handle any depth of a sequential. It should handle any nested structure.
20:21gfredericksI just saw dnolen's (_.0 => _0) commit to core.logic, and am curious why let has different naming rules than the reader
20:21gfredericks,'_.0
20:21clojurebot_.0
20:22gfredericks,(let [_.0 42] :heh)
20:22clojurebot#<CompilerException java.lang.ClassFormatError: Illegal field name "_.0" in class sandbox$eval53, compiling:(NO_SOURCE_PATH:0)>
20:22gfredericksoh it's that dot
20:23gfredericks,(let [a.b 42] :yep)
20:23clojurebot#<CompilerException java.lang.ClassFormatError: Illegal field name "a.b" in class sandbox$eval79, compiling:(NO_SOURCE_PATH:0)>
21:00Rirze,(prn "Why so quiet")
21:00clojurebot"Why so quiet"
21:09Frozenlock*cricket*
21:11calstadDid something happen to the clojure videos that were on blip.tv? Cant seem to get to any of them.
21:12Frozenlock"404 - That Blip has sailed.
21:12FrozenlockWe can't find the page you're looking for, but we did find a few new shows you'll enjoy:"
21:12Frozenlocko_O
21:12FrozenlockNooooooo
21:13gfredericksare they clojure shows?
21:13gfredericksI haven't been keeping up with the latest clojure sitcoms
21:13FrozenlockNot even close
21:13calstadno...it was a lot of the conj talks from years past
21:13gfredericks"Two and a half parentheses"
21:14calstadheh
21:14Frozenlock"Game of recurs"
21:14mthvedtyou win or you loop infinitely
21:15gfredericks"Fresh Conso of ..."
21:15metellus"how i met your filter"
21:15FrozenlockI'm still waiting eagerly for this years conj videos...
21:15Frozenlock"Walking map"
21:16gfredericks"Code Improvement"
21:16FrozenlockOh nice one
21:16gfrederickskind of generic though
21:16gfredericks"clojure.tools Time"
21:16calstadwow
21:17FrozenlockI don't get this one
21:17gfredericks$google tool time
21:17lazybot[Home Improvement (TV series) - Wikipedia, the free encyclopedia] http://en.wikipedia.org/wiki/Home_Improvement_(TV_series)
21:17gfredericksBinford 6100 MacroHelper
21:18Frozenlock"Dr.[]"
21:18gfredericks"big! theory" --embarrassed anonymous contributor
21:19metellus"map men" "seq-ing bad"
21:19gfredericks24
21:19brehaut"Secret Agent Man"
21:19gfredericks(get smart)
21:21calstadI regret asking the question now
21:24amalloy(inc calstad)
21:24lazybot⇒ 1
21:24Frozenlock(dec frozenlock)
21:24lazybot⇒ 0
21:24brehautha thats been fixed
21:25Frozenlockbrehaut: Really? Perhaps I was at 1 initially :P
21:25brehautFrozenlock: no, it didnt let you dec your own karma previously
21:25Frozenlock(dec frozenlock)
21:25lazybot⇒ -1
21:25FrozenlockOh I see
21:26brehaut(inc Frozenlock)
21:26lazybot⇒ 0
21:26brehautyou shouldnt be able to inc your own karma though
21:26Frozenlock(inc frozenlock)
21:26lazybot⇒ 1
21:26brehautha
21:26brehautok its just broken
21:31Frozenlock&(-> {:a 1} #(get % :a))
21:31lazybotjava.lang.ClassCastException: clojure.lang.PersistentArrayMap cannot be cast to clojure.lang.ISeq
21:32Frozenlock&(-> {:a 1} (get :a))
21:32lazybot⇒ 1
21:32Frozenlocko_O
21:32gfredericks&'(-> {:a 1} #(get % :a))
21:32lazybot⇒ (-> {:a 1} (fn* [p1__11643#] (get p1__11643# :a)))
21:33gfredericks&(macroexpand-1 '(-> {:a 1} (fn* [p1__11643#] (get p1__11643# :a))))
21:33lazybot⇒ (fn* {:a 1} [p1__11643#] (get p1__11643# :a))
21:34gfredericksit's a special form
21:34gfredericksjust like fn for these purposes
21:35FrozenlockOh
21:36gfredericksthe important thing is the behavior of -> when you give it a (fn ...) expression
21:36sgeofn isn't a special form
21:36gfrederickswhich is that it has no idea that anything special is going on and just shoves it right after the fn* in the list
21:37gfrederickssgeo: I mean that fn* is like fn in this case, not that fn is a special form
21:37sgeoOk
21:59tomojhow do you round-trip unknown tagged literals?
22:00holois anyone experiencing "Heroku push rejected due to an unrecognized error." almost after starting push now?
22:00tomojoh, I guess just have them eval to a defrecord which prints correctly
22:03amalloybrehaut: no, lazybot just noticed that Frozenlock was different from frozenlock
22:03brehautamalloy: aha
22:03gfrederickslazybot is a wise wise man.
22:04FrozenlockInteresting... Nickserv isn't case sensitive but lazybot is.
22:10RaynesFrozenlock, amalloy: case sensitive nicks is a bug.
22:10amalloylazybot is a bug, man. a glitch in the matrix
22:11gfrederickseasiest bugfix ever
22:15TimMcgfredericks: No, we have to write a migration for the existing karma points!
22:16gfredericks$karma TimMc
22:16lazybotTimMc has karma 21.
22:16gfrederickswoah
22:16gfredericksI PM lazybot "(inc TimMc)" and he says "1"
22:16gfredericksI do it again and he says "2"
22:16gfredericksis this some sort of troll-trap?
22:16amalloygfredericks: karma is per-channel, and PM with you is a channel
22:18TimMcKarma I can't even see -- the *best* kind of karma.
22:19TimMc(I'm kidding, of course, about preserving karma scores. All that really matters is that the recipient sees the inc, not the cumulative score.)
22:20gfredericksno it is about ranking people from best to worst
22:20brehautTimMc: unless someone works out how to convert lazybot karma into craft beer at cons
22:20TimMcTrue.
22:21gfredericks(dec scala)
22:21lazybot⇒ -1
22:21brehautno beer for scala
22:21TimMcOh hey, I thought dec wasn't working.
22:22TimMc(dec dec)
22:22lazybot⇒ 0
22:22brehauti think you should only able to co-inc scala
22:59TimMctmciver: crosscram-ws doesn't list any bots
23:08sshackOkay, lein is confusing me.
23:09sshackI'm following instructions to install the immutant plugin. Added a line to my profiles.clj file, then there's something missing, now leon is supposed to have an immutant task.
23:09sshackWhat's the missing thing?
23:10tpopesshack: you have lein 2, right?
23:10sshackCorrect.
23:10sshack2.0.0-preview10
23:10tpopehave you successfully added any other plugins before?
23:10sshackI've never tried.
23:10tpopewhat's your profiles.clj look like?
23:11ohpauleezsshack: run lein deps :tree first so it pulls the new plugin deps
23:11ohpauleezlein repl should do it too
23:11ohpauleezafter that, it should recognize the plugin
23:12sshackHow would I check? I haven't seen any notices about downloading jar files or whatnot
23:13ohpauleezsshack: Just try those two commands, at the start of them, you'll see that lein is pulling new deps (hopefully)
23:14ohpauleezlein deps :tree
23:14ohpauleezand lein repl
23:14sshackOkay, i don't think it was.
23:15sshackNo, I don't see immutant anywhere.
23:15sshackDo I have to add it to a project for the plugin to install itself?
23:15ohpauleezno, but you can
23:15ohpauleezin this case
23:16ohpauleezMaybe lein cached some results
23:16ohpauleezBut when you type lein, you still don't see the immutant task listed?
23:16sshackNo, I don't see immutant listed.
23:17sshackWhere will leon download plugin jars to?
23:17sshack~/,m2?
23:17clojurebot/Projekt/swank-clojure/ is where I keep the cloned git repo
23:17ohpauleez~/.m2
23:17ohpauleezyeah
23:17clojurebotHuh?
23:17ohpauleezYou might also want to try a new: lein new some-project
23:17ohpauleezand see if in that new project, lein picks up the plugin
23:18ohpauleezI've had this happen once before, but it remedied itseld
23:18ohpauleezitself
23:18TimMc~leon
23:18clojurebotleon is a good sign it's time to turn off auto-"correct"
23:18TimMc:-)
23:18sshackThat hasn't done it.
23:19tpopeI still think it's a good idea to double check ~/.lein/profiles.clj is correct
23:20sshacktpope: That's a good idea. it was named plugins, not profiles.
23:23tomojhmm, seems difficult to make one.test work nicely for promises
23:25sshackSorry guys, I feel stupid for making that error.
23:25tpopehappens
23:26sshack"Is the cable plugged in? Is it switched on?" Isn't actually a bad troubleshooting step.
23:27tpopewell that's where I started :)
23:28sshackYou know, toyota based an entire company on something like that.
23:28sshackIt's called mistake-proofing in the toyota production system.
23:29TimMcIs there a way of asking lein what plugins it knows about?
23:40devnTimMc: like, locally?
23:41devnin a repo? system-wide plugins? remote plugins?
23:45TimMcdevn: Whereever it is invoked.
23:52TimMcI think it's a bug that (clojure.java.classpath/classpath) returns a bunch of Files with %20 in their paths when run from a dir with a space in the name.