#clojure log - Apr 01 2014

The Joy of Clojure
Main Clojure site
Google Group
List of all logged dates

0:03 tmciver: chare: if I understand you, you may be looking for (use :reload . . .)

0:03 chare: or (require :reload . . .)

0:03 arrdem: tmciver: chare is the resident troll. fair warning.

0:04 clojurebot: chare |is| the resident troll. please do not feed.

0:04 amalloy: he's been pretty reasonable today

0:04 arrdem: I can't tell :P

0:04 now that erc and irssi are actually persisting my ignore lists...

0:05 tmciver: poor chare . . .

0:07 chare: I am not a troll

0:19 xpera: I've been waiting quite a long time to report a big limitation in Leiningen: https://github.com/technomancy/leiningen/issues/1484

0:19 bob2: troll or child, hard to tell

0:20 xpera: bob2: I'm 17 minutes late

0:20 bob2: oh, not you

0:28 arrdem: xpera: I'm actually pretty opposed to PC-CLOJURE, just because 16 bit processors and OSs need to die

0:29 xpera: there's a reason that MS-DOS is now open... it's a worthless platform

0:29 chare: we need to make windows die

0:29 linux only

0:33 aedon: Anyone use lighttable? I'm looking for some clever way to have a 'scratch area' for interactive evaluation at the end of a file that doesn't normally get evaluated? Comments won't work, because lighttable will evaluate the comment. Any ideas?

0:35 xpera: arrdem: but PC-CLOJURE needs all the help it can get

0:36 arrdem: xpera: PC-* is dead. let it moulder with nonpaged computers

0:36 oh. 4/1

0:36 * xpera snorts

0:36 arrdem: ,(apply head #'desk)

0:36 clojurebot: #<CompilerException java.lang.RuntimeException: Unable to resolve symbol: head in this context, compiling:(NO_SOURCE_PATH:0:0)>

0:37 xpera: arrdem: I'm shamefully trying to get some votes at https://news.ycombinator.com/newest

0:37 arrdem: damnit... I was gonna post actual content today...

0:38 xpera: the noise to signal is high today

0:40 arrdem: I wonder how long it'd take to build urbit-clojure...

0:40 and whether I could finish if I all night and ditch this morning's test...

1:03 noprompt_: WebSocket connection to 'ws://localhost:3000/ws' failed: One or more reserved bits are on: reserved1 = 1, reserved2 = 0, reserved3 = 0

1:03 fuck you

1:23 bellkev: I have a quick question regarding vars: Does anybody know exactly why they are callable, but you need to dereference them to do other things with them?

1:24 This occurred to me when trying to understand the syntax for (run-jetty #'my-app ...) to enable wrap-reload to work with compojure routes...

1:24 bob2: is anyone using lein's repository auth stuff? it looks a lot to me like it's not sending auth headers and I can't figure out why.

1:25 akhudek: bellkev: usually it just gets the value of the var

1:25 bellkev: but in the case of things that want dynamic rebinding you want the symbol instead, I think

1:25 bellkev: so that when you change whta the var references, the code can pick that up

1:28 bellkev: akhudek: I get that you only need to use the var in the case of jetty-run to get the dynamic reloading behavior, but after you do that, the app handler you pass it gets called as a function. I'm wondering why it was decided that you can just call a var (i.e. that implements IFn), instead of having to dereference it first, e.g. with var-get

1:28 akhudek: bellkev: ah, I do not know

2:19 noprompt_: Raynes: conch so awesome.

2:55 tsdh: What's the right predicate for testing if something is a composite form, e.g., a funcall? list? isn't it because it says true for '(foo 1 2) but false for `(foo 1 2). So I probably want seq?, right?

4:07 xsyn: How do I cons a java.util.regex.Pattern?

4:07 into a seq

4:08 pyrtsa: ,(let [xs ()] (cons #"foo" xs)) ;; why would you do that?

4:08 clojurebot: (#"foo")

4:14 broquaint: tsdh: Yeah seq? probably does what you want (although I'm not entirely sure what that is).

4:14 AeroNotix: ,(list #"foo")

4:14 clojurebot: (#"foo")

4:14 xsyn: I got confused

4:14 I put a cons and a join in the wrong order

4:15 tsdh: broquaint: Ok, thanks.

4:42 clgv: I want to get emacs 24 running with SBCL - is there any recent good guide to set up slime, paredit etc?

4:42 my old init.el from last year fails with strange errors

4:51 cmpitg: clgv: Perhaps it's better to ask in #emacs?

4:52 clgv: What errors did you encounter?

4:53 clgv: cmpitg: slime.elc:Error: Don't know how to compile nil

4:54 yeah maybe, I just know that here are usually a lot of helpful people knowing emacs ;)

4:54 cmpitg: Try removing all *.elc files?

4:55 clgv: cmpitg: *.elc are compiled files?

4:55 cmpitg: Yeah

4:55 find ~/.emacs.d/ -regex ".*\.elc$" -delete

4:56 elc files are byte-compiled from el

4:56 clgv: cmpitg: no that did not help

4:56 slime.el:Error: Don't know how to compile nil

4:56 cmpitg: Restarting Emacs doesn't work?

4:56 clgv: I installed slime.el:Error: Don't know how to compile nil

4:57 emacs startsup with that error message in the buffer

4:57 cmpitg: What's your Slime config?

4:58 And how did you install Slime?

4:58 clgv: version is slime-20100404.1

4:58 via the package-list-packages

4:58 currently just that https://www.refheap.com/70125

5:00 cmpitg: Strange, the version you have is too old

5:01 I'm using 20140320.1021 from Melpa

5:01 Try getting latest version then?

5:01 clgv: humm maybe it's the one provided with ubuntu

5:01 cmpitg: (add-to-list 'package-archives

5:01 '("melpa" . "http://melpa.milkbox.net/packages/&quot;))

5:01 (package-refresh-contents)

5:01 Then install

5:02 clgv: do I need to require anything before your add-to-list? since I get: "Debugger entered--Lisp error: (void-variable package-archives)"

5:03 cmpitg: Ah, it should be require'd by default if you're using 24. How about (require 'package) then add-to-list?

5:04 clgv: yeah added (require 'package) now

5:06 cmpitg: Does it work?

5:09 clgv: yes, thanks!

5:09 now lets see if I get all the features back^^

5:11 luxbock: hi, I don't completely understand how inline funcitons work (so I probably shouldn't be using them), but I have function that defines an anonymous function from a matrix, and then that anonymous function does lookups from the matrix based on the indices many times in a loop

5:11 clgv: cmpitg: is there a way to add all packages of a directory to the load-path?

5:11 luxbock: and the question is?

5:11 luxbock: I was wondering if I could expect a performance improvement by adding the :inline meta-data into the anonymous function definition?

5:11 cmpitg: clgv: Yes, gimme a moment

5:13 clgv: my emacs foo is weak ;) I just need it once a year for the SBCL course...

5:13 cmpitg: clgv: Something like this https://gist.github.com/cmpitg/f2c1b76329f7ff2a60d9

5:14 clgv: ah ok programatically. thanks!

5:14 cmpitg: Gladly :-)

5:14 luxbock: it would essentially be (fn [a b] {:inline (fn [a b] `(mget m ~a ~b)) } (mget m a b))

5:15 clgv: cmpitg: yes, my old init.el works now! thanks a lot!

5:16 luxbock: lambda functions (= anonymous functions) can not be inline

5:16 luxbock: alright, so my question doesn't make much sense then, good to know :)

5:17 cmpitg: clgv: :-)

5:17 clgv: cmpitg: damn one remaining problem. swank seems to be too old as well. I get a warning when I fire up slime

5:18 cmpitg: Do you use quicklisp?

5:18 clgv: cmpitg: not yet. but I could change that

5:19 cmpitg: clgv: It's highly recommended. Awesome package manager for CL :-)

5:19 Latest Slime from Melpa and Swank from Quicklisp work quite well

5:22 clgv: cmpitg: did try (ql:quickload "swank") but emacs still uses the old swank. would it work if I install it via quicklisp as root?

5:23 cmpitg: Ah, Emacs' Swank should come with Slime

5:23 Just restart your Emacs, ignore if it complains, and enjoy

5:55 doky: i want to ask: do i have to have installed clojure if i run my app as standole.jar which i built with leiningen uberjar ?

5:55 when i run in java -jar standolone.jar it fails with Exception in thread "main" java.lang.NoClassDefFoundError: clojure/lang/IFn

5:56 or what is the purpose that it fails im using lein2

6:13 broquaint: doky: Yeah clojure should be bundled in with your uberjar AIUI.

6:14 doky: in jar it already is

6:19 clgv: doky: you only need a Java Runtime Environment for standalone jars build with leiningen

6:20 doky: in jar file ? because i can run any jar for example i created by java etc

6:21 clgv: in jar file ? because i can run any jar for example i created by java etc

6:22 clgv: doky: yeah "lein uberjar" leads to my-project-standalone.jar which you can simply run per java -jar my-project-standalone.jar on any machine with a compatible java version

6:23 doky: clgv: but when i run it it fails with java.lang.NoClassDefFoundError: clojure/lang/IFn i have (:gen-class) only in file with main but in jar are all files i need

6:23 clgv: and also in jar file there is clojure and manifest is correct with Main-class

6:24 clgv: doky: sounds about right

6:27 doky: do you have a pure clojure project or some complex interop a la java uses clojure

6:27 doky: clgv: no only clojure, and i am using http-kit, it is a webapp with clojurescript

6:28 clgv: doky: it is not publically available on github?

6:28 doky: no :/

6:29 clgv: doky: just to eliminate weird cases did you try "lein do clean, uberjar" already?

6:29 doky: no i build it only with lein2 uberjar

6:29 clgv: i will try clean it

6:34 clgv: it still fails with same error

6:39 clgv: doky: can you post a complete stacktrace on refheap.com?

6:42 doky: clgv: here it is: https://www.refheap.com/70132

6:45 clgv: oh in jar under clojure directory there is no lang folder ... only core, data, java, tools

6:45 clgv: doky: well that's a problem then. did you add jar/uberjar exlucsions to your project.clj?

6:46 doky: clgv: no i haven't but i even dont know how to add it there ... :/

6:46 clgv: doky: can you post your project.clj?

6:46 oskarth: What'

6:47 What's a more idiomatic way to do this: {"email" (:email m) "address[line1]" (:address m) "address[city]" (:city m) "address[postal_code]" (:postalCode m)}?

6:47 doky: clgv: https://www.refheap.com/70133

6:48 clgv: oskarth: probably something using `reduce-kv` on the map and `name` to get the string from the keyword

6:50 doky: I dont see any reason in the project.clj which could cause that error.

6:55 doky: clgv: so how do i can get lang there ?

7:03 clgv: doky: if you try an empty project that just prints hello world in its main and build an uberjar from that you'll see that all of clojure ends up in the uberjar.

7:03 doky: I have no idea why it does not in your project...

7:04 doky: clgv: ok i will try it

8:03 noncom: hi, anyone working with CCW here?

8:05 Frozenlo`: I hate April 1st. The Internet is unusable.

8:05 CookedGryphon: yeah, feel it has jumped the shark a bit this year

8:06 though I did contribute to the noise a bit myself (using clojurescript and core.async) - http://www.swiftkey.net/en/blog/untap-your-potential-with-swiftkey-flow-hard/

8:07 core.async made throttling the prediction updates to the server really trivial, would have been a nightmare otherwise

8:16 wunki: In my ring handler I'm using the `:params` to fetch the id from the URI. But with ring-mock the `:params` key is not populated. Any tips how to test a handler like this?

8:40 AeroNotix: weird question-- is there something which acts like (str) but will convert nil to "nil" ?

8:40 ,(str nil)

8:40 clojurebot: ""

8:41 CookedGryphon: ,(pr-str nil)

8:41 clojurebot: "nil"

8:41 AeroNotix: CookedGryphon: cheers!

9:02 mskoud: trying to convert a list to a map, but would like to have a list for each record in the map. (into {} (map (fn [x] [(x :id) x]) [{:id 1 :data 2} {:id 2 :data 3} {:id 1 :data 4}])) ditch (as expected) :data 4 , but i would like to keep it...

9:02 '(into {} (map (fn [x] [(x :id) x]) [{:id 1 :data 2} {:id 2 :data 3} {:id 1 :data 4}]))

9:05 (group-by #(% :id) [{:id 1 :data 2} {:id 2 :data 3} {:id 1 :data 4}]) seems to work :-)

9:12 gfredericks: (group-by :id [...]) would likely do the same thing

9:12 brunov: mskoud: I think you can drop the #(% :id) and just use :id

9:13 gfredericks: you beat me to it by a millisecond :)

9:29 fro-: does anybody used orientdb with clojure? How it was, any pitfalls? Seems that native driver has'nt updated for 2 years..

10:40 Guest5277: is anyone having issues connecting to a lighttable project? When using the latest clojurescript 2197 it doesn't work. 2173 works fine.

10:53 gfredericks: having a library define print-dup for a 3rd-party type isn't as egregious as print-method...yeah?

10:56 cemerick: nice: stackoverflow in the CLJS compiler. This is going to be fun. :-P

11:28 germanmushroom: why does (defn grab-content [url]) (slurp url) return nil when called? Its a just slurp wrapper, calling slurp directly does grab the correct content

11:29 joegallo: if that's a 100% literal copy paste, then it's because you have a misplaced paren

11:29 germanmushroom: oh shit...

11:30 joegallo: ;)

11:30 germanmushroom: that didn't happen!

11:30 :p

11:33 cemerick: Wow: a CLJS codebase that compiled fine with 2173 was failing with a stackoverflow under 2197. Experimentation revealed that the -XX:TieredStopAtLevel=1 arg that Leiningen adds by default was the root cause; removing it yielded a clean compile.

11:34 Interestingly, leaving the tiered compilation args in as Leiningen defaults, but bumping up the thread stack size (doubling in my case, -Xss2m) also yields a clean compile.

11:34 dnolen_, technomancy ^^

11:35 I'm now inclined to always set _some_ :jvm-opts in lein-cljsbuild, so that lein's tiered compilation default args aren't added.

11:51 puredanger: could also ^:replace [] ? also, weird.

11:52 AmandaC: What exactly is the -> function thing? I’ve seen it crop up here and there, but I’m at a loss as to what it is

11:53 cbp: AmandaC: http://blog.fogus.me/2009/09/04/understanding-the-clojure-macro/

11:54 AmandaC: oooo, shiny

11:54 thanks, cbp

11:55 cemerick: puredanger: That's the effect of defining any :jvm-opts in project.clj. The defaults are omitted entirely in that case (e.g. :jvm-opts [])

11:56 puredanger: Is that true? I thought :jvm-opts was additive if you did not ^:replace ? (in which case empty opts has no effect)

11:56 cemerick: puredanger: but, yes. Makes a *little* sense, insofar as the tiered compilation stuff probably has more thread allocation overhead for cljsbuild's relatively short process lifetime (since it's interpreting for longer, rather than aggressively JIT'ing).

11:57 puredanger: Nope, empty [] replaces; verified via `lein pprint` and jvisualvm.

11:57 Also, my build working (or not) ;-)

11:57 puredanger: cool, that must have changed at some point

11:58 cemerick: I'm writing this up in a stable spot in a lein-cljsbuild issue, so people can gawk at it.

11:58 puredanger: <gawk>

11:59 if we just used sbt we wouldn't have these problems.

11:59 sorry, too much april foolery today

12:03 cemerick: puredanger: you need to be more subtle, that's too obvious :-P

12:18 rootex: what's stopping cljs from reaching version 0.1? ;)

12:24 devn: heh

12:25 cljs feels like it's at 1.6 to me

12:26 err 1.3-1.5, something in there

12:27 it'd be kind of nice if stable versions matched clojure releases

12:28 in other news, currently spinning at 800% CPU. Emacs is hung. Is it possible to `lein repl :connect` to save my session from dying? This task has been running for 4 hours and it might go for another 4, but I would like my emacs back.

12:28 It would be a bummer to kill it now, but I'm thinking I might have to

12:28 technomancy: ~tias

12:28 clojurebot: tias is try it and see

12:29 devn: technomancy: heh, i dont want to lose my session, so if you have a guess, that'd be helpful

12:29 i worry a bit that force quitting emacs will cause the server to die either way

12:30 technomancy: oh sure, if you jacked in then your session won't survive emacs quitting

12:30 I thought you were asking whether you could get it out of this hung state, which is harder to say

12:31 devn: technomancy: /me hands you a code of conduct and a lemonade

12:31 technomancy: you definitely should be able to connect to the process through a cli repl

12:31 devn: well, i /can/, but it hasn't shown me a prompt yet

12:31 justin_smith: sometimes you can rescue a program and turn a hang into a small error by connecting via gdb, stopping, popping up some number of stack frames, and resuming

12:32 devn: i assume because my there is a crazy amount of GC going on

12:32 justin_smith: though usually killing and starting over is sufficient and easier

12:32 devn: s/my//

12:33 I may start over either way just to try and figure out how to partition this work. I think I need some clojure perf action

12:33 no.disassemble time? maybe.

12:33 justin_smith: also, im going to keep bugging you until you get back to me about stopping out in portland :)

12:34 cemerick knows how persistent i can be. i think it's been 2.5 years and im still asking for him to hook me up with some source he promised.

12:40 clgv: devn: for higher level try "luyten" or "jd-gui"

12:44 gfredericks: oh man java.util.Random is not very random

12:45 seeds 0=>4095 will give a number between 0.5 and 1.0 when you call nextDouble

12:46 I guess the seed has to be pretty random too O_O

12:51 ToxicFrog: gfredericks: Java, per the spec, uses a very simple LCG. It's kind of shit.

12:52 devn: gfredericks: mersenne twister

12:53 gfredericks: does this mean that test.check's habit of using currentTimeMillis for the seed is a bad idea?

12:54 and (.nextLong (java.util.Random. (System/currentTimeMillis))) would be a better seed?

12:55 bbloom: gfredericks: http://docs.oracle.com/javase/7/docs/api/java/security/SecureRandom.html

12:55 amalloy: gfredericks: actually i'm surprised Random doesn't let you ask what seed you would need to use to get a Random like this one

12:56 there's no way test.check needs cryptographically secure randomness

12:57 gfredericks: amalloy: oh surely not

12:57 reiddraper: gfredericks: not sure i follow, currentTimeMillis returns something like 1396371284007, not 0-4095

12:57 gfredericks: reiddraper: right, I just didn't know if there would be other ranges of seeds that give constant output for certain operations

12:58 reiddraper: ah, quite possibly

12:58 admitedly its not something i've looked into much

12:58 gfredericks: gen/boolean gives true for 0->4096; what if it also gives true for some month-long range of currentTimeMillis?

12:58 amalloy: probably there are, but i doubt it makes much difference to test.check

12:58 gfredericks: I guess that only affects the first round of tests

12:59 amalloy: maybe the first coin you flip always comes up heads, for a period of several minutes. even if that's true, the coins after that in each run will be different

12:59 gfredericks: amalloy: righto; good points all; test.check is teh best

12:59 amalloy: and a single run of test.check flips a lot of coins, i bet

12:59 gfredericks: I made a for-gen macro

12:59 or gen-for; or whatever a good name is

12:59 amalloy: gfredericks: so it's like bind, with :when/:while/:let, or what?

12:59 gfredericks: it can replace bind, fmap, and such-that

13:00 amalloy: yeah, but I don't think :while makes sense?

13:00 amalloy: probably not

13:00 gfredericks: I think I wrote this like a year ago and can't remember if reiddraper thought it would fit in test.check

13:00 s/year/6-months/

13:00 amalloy: gfredericks: well, bind can already replace fmap and such-that, so you're really just replacing bind, right

13:01 reiddraper: gfredericks: likely, yes. i still intend to get nested-property support in sometime soon, now that things have picked up steam a bit

13:01 gfredericks: clojurebot: amalloy is right again

13:01 clojurebot: Ik begrijp

13:02 * amalloy embarks on a campaign to discover if it's possible to get tired of being right

13:02 gfredericks: april 1st is a good day to experiment with being wrong

13:02 amalloy: oh man

13:02 i could just give terrible advice in #clojure all day

13:02 "why don't you try type-hinting that"

13:03 "just use defstruct"

13:03 gfredericks: I know a 5yo who just learned about april fools and thinks it's just saying arbitrary false things followed by "April fools! <uproarious laughter>"

13:03 llasram: That's adorable

13:04 amalloy: awww



13:04 technomancy: gfredericks: that sounds like how my kids do knock-knock jokes

13:05 amalloy: every year i toy with the idea of an april fools joke on 4clojure, and i always decide i shouldn't spend much effort on confusing newcomers

13:05 gfredericks: technomancy: how is line 3 constructed?

13:06 technomancy: gfredericks: haven't been able to discern much of a pattern so far

13:06 gfredericks: are line 3 and 5 related?

13:07 technomancy: yeah, 3 is just a truncation of 5, which is a random phrase

13:07 gfredericks: oh nice

13:07 knock knock

13:07 llasram: Who's there?

13:07 gfredericks: rich hickey

13:07 llasram: Rich Hickey who?

13:07 gfredericks: rich hickey invented scala! april fools!

13:08 llasram: Adorable!

13:08 technomancy: unrelated http://achewood.com/index.php?date=01072002

13:08 well, tenuously related

13:08 AmandaC: o.o

13:09 llasram: Awww. As an immortal child, Philippe does not himself comprehend death

13:13 gfredericks: reiddraper: should we just call it for?

13:14 reiddraper: gfredericks: seems reasonable to me

13:14 or maybe 'let'

13:14 depends on the shape of it, i suppose

13:16 gfredericks: I figured it could include :let and :when the same way clojure.core/for does

13:17 reiddraper: gfredericks: you have a couple of example uses of it?

13:18 gfredericks: I could drum one up

13:22 reiddraper: https://gist.github.com/fredericksgary/9918722

13:23 apparently :when is harder to write than I thought

13:24 reiddraper: gfredericks: thanks, i'll take a look during lunch, shortly

13:25 seangrove: ,(let [a (atom [])] (swap! a conj a))

13:25 clojurebot: [#<Atom@efd40d: [#<Atom@efd40d: [#<Atom@efd40d: [#<Atom@efd40d: [#<Atom@efd40d: #>]>]>]>]>]

13:26 amalloy: seangrove: you get a stacktrace in your repl, but during printing, not during the swap!

13:27 seangrove: amalloy: Ah, I thought it was interesting since it just came up on the ml

13:27 amalloy: i don't really read the ML anymore

13:28 SegFaultAX: amalloy: You don't see the ML anymore? Just functor... monoid... monad...

13:33 seangrove: amalloy: Why's that?

13:33 It's been kind of nice for seeing what people are working on. Not mission-critical though.

13:34 amalloy: a few reasons. the first was just that the rss feed stopped working for me, and i realized i didn't really mind

13:35 but it's just so much slower than irc, and i only have so much time. if someone's in here, they have a question that they *can't* surround with five paragraphs of context that they think will be useful but really just obscures the problem

13:35 and i can answer in a sentence without seeming rude for not writing a couple paragraphs

13:37 gfredericks: IRC: Like ML but for busy professionals.

13:37 rasmusto: ~ML

13:37 clojurebot: Cool story bro.

13:37 hiredman: the mailing list lacks the darwinian forces that are at work on irc

13:38 amalloy: hah

13:38 technomancy: ken wesson and cedric greevy wouldn't last a day on freenode

13:39 hiredman: I saw an email on the list that recent began with "I am a post technical pm"

13:39 seangrove: amalloy: Interesting points

13:39 hiredman: recently

13:39 * rasmusto can't wait to be post-technical

13:39 seangrove: hiredman: It's a pretty good filter, someone has to at least find it. Perhaps better pre google-groups

13:41 gfredericks: hiredman: that just means "I quit programming"?

13:41 hiredman: gfredericks: yeah, I had to ask around to see if anyone knew what that meant

13:41 justin_smith: "I got promoted from writing code to making people who write code meet deadlines"

13:44 locks: I was a post rock bassist once

13:44 am I qualified for a post technical position?

13:53 moquist: We're trying to switch our otherwise open source project from datomic-free to datomic-pro, and running into the [aparently] usual questions about depending on it. I put a :repositories entry in my ~/.lein/profiles.clj to add my.datomic.com so we aren't putting it in our project.clj in github. lein is, of course, telling me to "See https://github.com/technomancy/leiningen/wiki/Repeatability".

13:53 Is there a better way? Google has not told me the answer so far.

13:55 technomancy: moquist: ignoring the question of whether it makes sense to have open source that can't run without proprietary software, you should put the repositories you need into the project.clj file and configure credentials for this file to read from the environment or from credentials.clj.gpg

13:58 moquist: technomancy: Yes, I'm [somewhat] ignoring that question for now, too. I'm inclined to switch the dep to datomic-free and keep datomic-pro in a production profile.

13:59 justin_smith: will using nginx in front of http-kit with websockets be a total pain in the ass?

14:00 (I have used nginx in front of http-kit, and websockets in http-kit, but not both together)

14:01 amalloy: justin_smith: i think i used iptables instead of nginx for my websocket stuff. my understanding is that ngnix doesn't like to have lots of long-lived connections (which is one of the main use cases for websockets)

14:01 justin_smith: cool, thanks

14:01 moquist: technomancy: thx, BTW

14:02 technomancy: moquist: sure. I'm inclined to agree that private repos are more trouble than they're worth fwiw.

14:03 devn: aw man, sad face, "connection broken by remote peer"

14:10 marcuscreo: exit

14:10 \exit

14:14 seangrove: ~exit

14:14 clojurebot: exit is There is no exit

14:14 rasmusto: ~^D

14:14 clojurebot: Excuse me?

14:16 justin_smith: ~

14:16 clojurebot: I don't understand.

14:16 justin_smith: it is cool that you can send an EOF to IRC

14:18 doky: can anybody help with this issue ? https://www.refheap.com/70323 im using enfocus for templating

14:19 dnolen_: doky: more context is needed, what does your client side code look like?

14:22 doky: on the client side is enfocus and i'm trying to implement - user-list with users already in chatroom and so count of users varies and so i appending (even though not sorted) works but if i want to remove user who left the room its a problem

14:23 dnolen_: so this is it

14:23 dnolen_: doky: i mean like a gist or refheap

14:27 dbasch: has anyone figured out the “com.google.common.io.ByteStreams.limit(Ljava/io/InputStream;J)Ljava/io/InputStream;” exception when building clojurescript with optimizations?

14:28 doky: dnolen_: https://www.refheap.com/70326

14:29 dnolen_: any idea ?

14:30 dnolen_: dbasch: never heard of that issue

14:31 amalloy: dbasch: sounds like a version mismatch

14:31 but a real stacktrace would help, as always

14:31 dbasch: using cljsbuild 1.0.2, clojurescript 2173

14:31 stacktrace coming

14:31 dnolen_: doky: huh no idea, I don't know enfocus, ask on the ClojureScript ML

14:32 doky: ok i will try, thanks

14:33 dbasch: amalloy: full stacktrace http://pastebin.com/P78EJ8J3

14:34 amalloy: definitely a version mismatch

14:34 dbasch: google hints at a problem with the closure compiler and guava

14:34 amalloy: between what, i'm not sure. google.commons.io and closure, maybe?

14:35 dbasch: amalloy: ok, but I don’t know where to start looking

14:41 dnolen_: ClojureScript 0.0-2199 going out, just fixes annoying incorrect Google Closure warnings

14:44 dbasch: dnolen_: the problem I see has to do with a Guava method that doesn’t seem to be there

14:45 dnolen_: dbasch: sounds like a deps issues like amalloy said then

14:45 dbasch: I would check your deps tree to see what's up

14:47 dbasch: dnolen_: any ideas as to how to find out what’s bringing in an incorrect / old version of guava?

14:47 dnolen_: lein deps :tree

14:48 amalloy: also lein-pedantic should warn you of version mismatches, i think

14:48 that might even be in lein itself now

14:48 dnolen_: amalloy: I think `lein deps :tree` does this for you

14:48 well it definitely does here on my machine anyway

14:50 seangrove: dnolen_: You've mentioned it before, but what're the remaining issues for a 1.0 cljs release? I'm not especially worried about it, just curious

14:50 dbasch: [secretary "1.1.0"] -> [org.clojure/clojurescript "0.0-2156"] -> [com.google.javascript/closure-compiler "v20131014"] -> [com.google.guava/guava "15.0"]

14:52 actually, I found the problem

14:52 [com.google/bitcoinj "0.11.1"] -> [com.google.guava/guava "13.0.1"]

14:52 overrides

14:52 [org.clojure/clojurescript "0.0-2173"] -> [com.google.javascript/closure-compiler "v20131014"] -> [com.google.guava/guava "15.0"]

14:53 dnolen_: seangrove: various compiler things need fixing (tools.analyzer integration, main namespace), various perf things (multimethods)

14:55 speaking of which I'm thinking 0.0-2199 should probably be the last release of ClojureScript that doesn't require 1.6.0 - I'd like to move to the new hashing stuff, and macros etc.

14:55 dbasch: thanks dnolen_ and amalloy

14:57 of course, I need that library for my clojure build. Any elegant way to separate the dependencies other than commenting it out when I’m building clojurescript?

14:58 dnolen_: dbasch: doesn't it suggest exclusions?

15:01 justin_smith: http://lispm.dyndns.org/sbcl it looks like sbcl's april fool joke is clojure

15:06 bbloom: justin_smith: i know it's a joke, but i can't tell which part is the joke....

15:06 justin_smith: heh, I don't think we are the target audience

15:06 bbloom: justin_smith: is "haha clojure" a joke among CL people?

15:06 justin_smith: I wouldn't be surprised if it were

15:07 dnolen_: bbloom: I don't think so, only some CL people

15:07 bbloom: either way, i laughed harder at https://github.com/tpope/timl until i saw "763 commits"

15:07 technomancy: the best jokes are the ones that actually work

15:07 justin_smith: wow

15:07 tpope: bingo

15:08 bbloom: tpope: *clap*clap*

15:08 * technomancy gestures at https://github.com/technomancy/lein-xml

15:08 bbloom: technomancy: hahah, is it just mvn?

15:08 TravisD: poor tpope :(

15:09 dnolen_: bbloom: I thought the Haskell April Fool's joke was funnier https://groups.google.com/forum/#!topic/haskell-cafe/iMkWf7dlP8g

15:09 technomancy: bbloom: no, it's an alternate defproject syntax

15:09 bbloom: technomancy: looking at src now, hilarious. nicely done

15:09 technomancy: thanks

15:10 justin_smith: lol

15:10 (inc technomancy)

15:10 lazybot: ⇒ 104

15:10 technomancy: it sits on the auto-activated middleware stuff

15:10 AmandaC: bbloom: I hear you’re obsessed with trees? :p

15:10 bbloom: AmandaC: true story.

15:10 AmandaC: I found your talk rather amusing. :P

15:11 bbloom: tpope: i enjoy the file extension

15:11 tpope: turns me on tbqh

15:11 bbloom: AmandaC: i'm glad you enjoyed it!

15:11 tpope: is the the first lisp you've implemented? it's certainly a rite of passage, but you, my friend, are an insane person

15:11 tpope: yes it is

15:12 bbloom: tpope: did you get a warm fuzzy euphoria feeling?

15:12 or did viml preclude that?

15:12 tpope: nah it was a constant high to see shit work

15:12 dbasch: dnolen_: I was excluding com.google/guava, and it was com.google.guava/guava. That fixed it

15:13 thanks again

15:13 bbloom: tpope: awesome. congrats on a truly mad man success

15:13 tpope: I mean I reeeeeeaally understand syntax quoting after implementing it 4 or 5 times

15:13 one of them the right way, even

15:13 bbloom: haha that's entirely why i wrote backtick

15:13 AeroNotix: Does anyone know of any interesting discussions which happened about custom runtimes for Clojure?

15:13 dnolen_: tpope: can't believe you bothered with stuff like chunked seqs :)

15:14 ambrosebs: tpope: wow!

15:14 tpope: dnolen_ I had dreams of it being a viable language, man

15:14 that was a huge performance boost

15:14 amalloy: dnolen_: performance is even more important if you're compiling to viml, of course

15:14 bbloom: i am seriously grinning ear-to-ear

15:15 tpope: I mean I haven't completely given up that dream

15:15 but it's dubious enough that I haven't been able to get excited about working through the tedious stuff like documentation

15:16 bbloom: ... does your repl have a debugger...?

15:17 tpope: yeah but I think it's broken

15:17 bbloom: props for even attempting it

15:17 tpope: wouldn't be *that* hard to get working again

15:18 well by debugger I mean "start a repl within lexical scope", not a *real* debugger

15:19 bbloom: close enough

15:37 brainkim: Hey peeps!

15:37 What's the closest thing Clojure has to Haskell's `IVars` (i.e. a thread-local (I need it in clojurescript) reference type that can only be written to once (or twice if you ignore the initialization) and will drop all future writes))?

15:38 ztellman: a promise, if you ignore the thread-local bit

15:39 bbloom: could also use a core.async channel with a dropping buffer

15:40 brainkim: maybe step back a bit and tell us what you're trying to do & we can tell you the idiomatic solution

15:40 brainkim: bbloom: I like that solution! I've been pretty much replacing most reference types with channels of some sort.

15:41 I'm doing websocket stuff, need to set client id on the first message, but don't want it to ever change.

15:41 I dunno.

15:41 Thanks for the suggestions bbloom ztellman

15:42 bbloom: brainkim: sounds like both promises and channels would be overkill... why not simply (when (nil? channel-id) (swap! something assoc :channel-id 123

15:42 ... etc

15:42 brainkim: Yeah I guess I should just use an atom

15:43 The thing is I don't want the client to send any messages until it knows its canonical id

15:44 well, i guess i could just deref the atom and check if it's still nil

15:44 hmmm

15:46 What I basically want is a singleton core.async channel which will park a goroutine while it's empty and will emit the same value whenever it's `<!`ed

16:03 babilen: ban evasion

16:04 (ECHAN - don't do that!)

16:04 heh

16:09 coventry: brainkim: How about (async/onto-chan c (cycle ['v]))?

16:11 brainkim: Does to-chan/onto-chan play nicely with infinite seqs?

16:11 that's cool!

16:17 seangrove: In the interest of balanced discussion, I'd like to see what non-top analyst predict in regards to the topic

16:18 rasmusto: numbers will decrease

16:19 technomancy: numbers will converge on pi

16:19 seangrove: There's also the possibility that it's linked to quantum-levels of randomness

16:20 How come none of these possibilities are covered? Why do the corporate overlords of #clojure insist on censoring free speech? WHAT ARE THEY AFRAID OF?

16:20 bbloom: numbers will converge on e, but then oscillate back and forth and ultimately diverge

16:20 technomancy: clojurebot: wake up sheeple

16:20 clojurebot: Cool story bro.

16:20 coventry: Clojure will shortly be abandoned after the love child of Rich Hickey and Rasmus Lerdorf publically unveils serious misgivings about its upbringing.

16:21 * seangrove ponders such a love-child

16:21 zerokarmaleft: I have serious misgivings just about those words together in a sentence

16:25 ambrosebs: tpope: how do I lookup a deftype field in timl?

16:26 tpope: sorry just finding the docs

16:26 tpope: what do you mean "look up"?

16:26 deftype was right around where I started to trail off but you can see an example in timl.buffer

16:27 ambrosebs: tpope: I meant (deftype Abc [a]) (. (Abc 1) a)

16:27 tpope: oh right, that's it

16:27 ambrosebs: Is (. (Abc 1) -a) supposed to work?

16:28 tpope: no, I tried to emulate clojure not cljs in this regard

16:29 ambrosebs: cool, fwiw it works in clojure too

16:29 tpope: oh, does it work both ways in clojure?

16:30 I thought clojure was (. x attr) or (. x (method args))

16:30 ambrosebs: tpope: I think it disambiguates between a zero argument method and a field?

16:30 tpope: I copied that but left out (.foo x) because until I made a more definitive decision

16:31 in clojurescript it does

16:31 I thought in java you could only have one or the other, so it was moot

16:31 ambrosebs: ok, the syntax is implemented in clojure, it apparently doesn't do much

16:32 tpope: good to know. I intentionally left out (.foo x) to delay making a decision on that

16:32 rasmusto: tpope: what does Tim stand for?

16:33 justin_smith: I would have guessed Timothy

16:33 tpope: timl stands for tpope viml


16:33 bbloom: i vote for TIMproved Meta Language

16:33 ambrosebs: :)

16:33 rasmusto: TIMproved sounds good

16:34 seangrove: clojurebot timl is unresolvable

16:34 ordnungswidrig1: where is clojure for elisp bytecode?

16:34 seangrove: clojurebot: timl is unresolvable

16:34 clojurebot: Roger.

16:34 technomancy: ordnungswidrig1: I came really close to starting that project

16:34 ordnungswidrig1: but the fact that the emacs platform doesn't have immutable strings or lists made me hesitant

16:34 seangrove: technomancy: Did you get distracted with OCaml for elisp bytecode?

16:34 technomancy: hehe

16:34 ordnungswidrig: technomancy: when you do, then please no intermediate elisp. direct to the metal.

16:35 technomancy: "the metal" haha

16:35 bbloom: technomancy: amusingly, a text editor is probably one of the few places where mutable string constructs have an appropriate use case

16:35 technomancy: (I'm currently hacking forth, which makes me amused at every reference to "the metal" that still runs inside an operating system)

16:35 Bronsa: tpope: ambrosebs actually you can have fields/no-arg-method in java too

16:35 ordnungswidrig: bbloom: not at all, you want to have structural sharing for undo-trees!

16:35 technomancy: bbloom: actually you'd think so but that's really not true

16:35 Bronsa: tpope: ambrosebs http://sprunge.us/HGAV?clj

16:36 technomancy: bbloom: all the mutation already happens in elisp's buffer type

16:36 seangrove: Reminds me of e-texteditor, crazy authors

16:36 ordnungswidrig: technomancy: forth ist the only higher language that is authorized to talk about the metal.

16:36 ambrosebs: Bronsa: thanks

16:36 technomancy: bbloom: seeing strings that are bashed in place is actually super rare, and emacs's maintainers have expressed openness to making them immutable in a future release

16:36 tpope: Bronsa: oh weird, that's what I get for assuming

16:36 bbloom: technomancy: nevermind, i stand corrected. that's awesome

16:37 ordnungswidrig: the emacs maintainer. what are these? alle men with beards? long beards?

16:37 coventry: I had so much fun with forth on my trs-80 cc.

16:37 Bronsa: tpope: I only know this because I got bitten by a bug that assumed that that wasn't possible, so you're in good company :)

16:37 ordnungswidrig: forth is so low level that is becames powerful

16:38 technomancy: bbloom: OTOH it just makes it more frustrating that there are no guarantees =)

16:38 you write all your code assuming strings never change, but one day someone comes along and ruins your party

16:38 llasram: "I'm here for the immutable string party. This is it?"

16:39 Then -- out comes the nine-bladed mutator

16:39 bbloom: technomancy: i've seen so many bugged ruby programs that mutate strings that are used as keys in hashes

16:39 technomancy: sends shivers up my spine

16:40 seangrove: Are stings mutable in ruby?

16:40 technomancy: that's one thing JS got right, probably by accident

16:40 bbloom: seangrove: yes, keywords are not

16:40 technomancy: *undoubtedly by accident

16:40 bbloom: heh

16:40 seangrove: Jesus

16:40 bodie_: does anyone know whether Typed Clojure (i.e. Core.Typed) is a good thing?

16:41 ToxicFrog: I've used it with some success, although I want different names for some of its API functions because I think they look ugly.

16:41 I've never used it on anything really large, though.

16:43 seangrove: Wow http://stackoverflow.com/a/14779648

16:44 rasmusto: ~sugar

16:44 clojurebot: Huh?

16:44 amalloy: tpope, Bronsa: before the (.-foo x) syntax was introduced, on the jvm (. x foo) used to default to the field, and you could use (. x (foo)) to get the method instead. i didn't realize that had changed, but either way it's an interesting historical note

16:45 bbloom: it's an interesting case study on the complexities of host-agnostic host-interop :-P:

16:46 tpope: yeah my (apparently incomplete) understanding of that informed my decision to make (. x (foo)) the method invocation interface

16:47 bbloom: i didn't even realize vim had a concept of methods...

16:48 tpope: it supports a primitive form of prototype based inheritance, but the core language doesn't really use it

16:48 hence why I didn't have a problem hiding it behind that ugly ass syntax

16:49 ordnungswidrig: technomancy: are you still happy with your portable keyboard (I just built my ergodox)

16:49 hiredman: needs an april fools project to embed v8 in vim and switch to javascript for vim scripting

16:49 ordnungswidrig: hiredman: I hope you mean clojurescript *g*

16:49 hiredman: commit message "fixing vim's prototype based inheritence"

16:50 brehaut: when vim and emacs finally converge where will all the unspent nerd rage go?

16:50 technomancy: ordnungswidrig: yeah, I just made a few changes to the layout that have made it quite a bit nicer. I still prefer the ergodox for when I'm at home though.

16:50 tpope: hiredman: actually if that neovim project has its way you'll be able to target luajit

16:50 ordnungswidrig: technomancy: because of the split form factor?

16:51 justin_smith: brehaut: slashdot comment threads?

16:51 brehaut: wait wait wait, slashdot is still a thing?

16:51 ordnungswidrig: brehaut: bashing atom / sublime / ?

16:51 technomancy: ordnungswidrig: that and also because of less reliance on the fn layer

16:51 (more the latter)

16:52 ordnungswidrig: 42 is just a really small number of keys =)

16:52 hiredman: tpope: should have gone crazier and went with an embeddable common lisp

16:52 ordnungswidrig: well, thank god you do no APL programming

16:52 technomancy: ordnungswidrig: it's actually great for forth! so little punctuation.

16:52 ordnungswidrig: *g*

16:53 technomancy: parens on the home row is pretty great too though

16:55 ordnungswidrig: yes, I used the third layer of the neo keyboard layout for a while. has layer 3 on caps/# (which is qwerty '/") with parens, brackets and so on paired on the home row.

16:55 and a fourth layer for nav keys.

16:56 jgmize: /buffer codesy

16:56 technomancy: ordnungswidrig: using it as an external board attached to my laptop means I haven't bothered yet with f-keys or arrows; I just hit those on the internal board

16:56 but it's nice to have the option

16:56 ordnungswidrig: well, never thought about that option.

16:57 there's still ctrl-f/b/p/n

16:57 technomancy: yeah, it's not like I use the arrows in regular usage anyway

16:58 I actually physically removed the tab keycap from my ergodox in order to train myself to use C-i instead

16:58 ordnungswidrig: rip them out! and ESC as well! I remember using CTRL-3 because the terminal had no escape key!

16:58 physically? you mean in the firmware or the keycap?

16:59 technomancy: yeah, the actual plastic keycap

16:59 ordnungswidrig: replace it with nail :-)

16:59 technomancy: hardcore

16:59 Bronsa: amalloy: oh didn't know that. the change makes sense though.

16:59 ordnungswidrig: CTRL-I is actually easy to remeber: I is for indent!

16:59 amalloy: or just set it to launch an app you despise

17:00 Bronsa: what to me doesn't make any sense at all is ##(java.lang.Integer/MAX_VALUE)

17:00 lazybot: ⇒ 2147483647

17:00 ordnungswidrig: amalloy: yes, launch VI and remove the escape key first.

17:00 amalloy: Bronsa: meh. statics are known at compile time to be either methods or fields. i agree it's silly that it's allowed, but it's not really hurting anyone

17:01 rasmusto: C-[, c'mon

17:01 stuartsierra: Bronsa: It's a historical artifact. (Integer/MAX_VALUE) worked before Integer/MAX_VALUE did.

17:01 ordnungswidrig: rasmusto: rather difficult on german keyboards.

17:02 bbloom: amalloy: it hurt me, when i was implementing an interpreter

17:02 amalloy: i was like "wtf?"

17:03 it hurt my brain

17:03 Bronsa: amalloy: java allows for static fields and static no-arg methods to have the same name, I'm not sure there's a way to disambiguate in that case

17:03 rasmusto: Strg-Shft-8 :s

17:03 amalloy: you have a very resilient brain, bbloom. i'm sure you'll be fine

17:03 ordnungswidrig: rasmusto: no way on osx

17:03 amalloy: Bronsa: i would be unsurprised to find that Foo/BAR mapped to the field, and (Foo/Bar) the method

17:04 bbloom: amalloy: i'm confused by that comment, i'm not sure if my brain will ever recover from the cognitive dissonance you have caused me

17:04 rasmusto: ordnungswidrig: in ordnung

17:04 ordnungswidrig: rasmusto: verboten!

17:04 *g*

17:06 what was actually the reason there is no project yet to port emacs (the good parts) to clojure?

17:06 technomancy: ordnungswidrig: you mean deuce?

17:06 ordnungswidrig: deuce?

17:06 technomancy: https://github.com/hraberg/deuce

17:07 he's actually going for source-compatibility tohugh

17:07 ordnungswidrig: hmm

17:07 technomancy: so not sure if that counts as "the good parts"

17:07 ordnungswidrig: that's the part I would give up. as long there's still org-mode

17:07 Bronsa: amalloy: I just tested -- you're right.

17:08 ordnungswidrig: technomancy: he's exploring browser-first-js no legacy :)

17:08 technomancy: I'd be surprised if he gets org working

17:08 ordnungswidrig: *g*

17:08 technomancy: org is probably the craziest piece of elisp in existence

17:09 iirc it's the largest .el file in emacs by an order of magnitude

17:09 ordnungswidrig: surprisingly it's not yet collapsed under all that features

17:09 ambrosebs: tpope: what does this mean? https://gist.github.com/frenchy64/9923233

17:09 & seems to work with other functions

17:09 lazybot: java.lang.RuntimeException: Unable to resolve symbol: seems in this context

17:10 Bronsa: stuartsierra: I didn't know that

17:10 amalloy: Bronsa: the .-field syntax didn't add any capabilities to clojure or clojurescript that weren't already possible with the old syntax, it just made it easier to do things that were already possible, by changing the default of (.foo bar) to be what you "usually" mean, and adding (.-foo bar) to get back the less common meaning

17:11 tpope: ambrosebs: check (qf) to see where the error originated

17:11 I can look closer in a few

17:11 ambrosebs: holy crap! :)

17:11 this is awesome

17:12 bbloom: where else but #clojure could you have a type-system guy evaluating stuff in a lisp interpreter written in vimL?

17:12 stuartsierra: Org-mode version 8 is massively refactored into ~100 files.

17:12 bbloom: nowhere. that's where.

17:13 ambrosebs: I want to write my vim plugins in clojure! :)

17:13 stuartsierra: amalloy, Bronsa: actually, it did. (.foo bar) couldn't distinguish between a field lookup and a method call in ClojureScript.

17:14 In Java there's no ambiguity because a public field and a public method can't have the same name.

17:14 amalloy: stuartsierra: that second part isn't true

17:15 stuartsierra: as for the first: you could have made it act like "that's always a field", by expanding it to (. bar foo), and writing (. bar (foo)) when you want it to be a method

17:15 Bronsa: stuartsierra: http://sprunge.us/HGAV?clj

17:15 amalloy: I guess nobody wants to use the . op directly

17:15 bbloom: Bronsa: the brevity of that compared to the corresponding java is amusing

17:16 amalloy: Bronsa: right, and so the .- syntax was introduced to make it more convenient. but it wasn't a *necessary* addition; the existing notation in java was sufficient, except that it made you write annoying crap to be specific

17:16 stuartsierra: OK. I recall something, like in Clojure (JVM) the (. bar foo) form would always be interpreted as a zero-argument method call.

17:17 tpope: ambrosebs: error is wrong but looks like the problem is you're trying to recur to a different arity. that doesn't work in clojure either afaik

17:17 ambrosebs: tpope: the recur is correct, plus I copied it from clojure.core

17:18 tpope: yeah just figured that out

17:18 ambrosebs: tpope: the rest argument is 1 extra argument to recur

17:18 tpope: so apparently it's just timl that doesn't support that

17:18 stuartsierra: Yes, Bronsa, in your example, (. (x. 0) f) returns 1

17:19 I think early ClojureScript maybe reverted to an older definition of `.` which used parens to distinguish between fields and methods.

17:19 amalloy: i was under the impression that, before the .- change, Bronsa's first snippet would have returned 0 on clojure-jvm, but i just tried it and apparently that's not true

17:20 Bronsa: oh well, that (. (x. 0) f) returns 1 surprisese me

17:20 surprises*

17:20 stuartsierra: Yes, THAT was added as a "convenience" before (.method object) existed!

17:20 amalloy: Bronsa: (.f (x. 0)) just macroexpands to the former

17:20 so if one surprises you they both should :P

17:20 Rosnec: hey

17:21 stuartsierra: Lesson learned: syntax is evil. Write all your programs in pure untyped lambda calculus.

17:21 Bronsa: amalloy: right, it just *feels* wrong

17:21 amalloy: clojurebot: syntax is evil: write all your programs in pure untyped lambda calculus.

17:21 clojurebot: Roger.

17:21 tpope: ambrosebs: fixed the literal error but didn't check that it works as expected

17:21 stuartsierra: :)

17:21 ambrosebs: will check

17:21 tpope: actually unlikely that I did

17:22 Rosnec: is there something like future which ensures things are done in-order?

17:22 justin_smith: Rosnec: maybe an agent?

17:22 Rosnec: I want to do some output to a file, but I want it done in the background

17:23 justin_smith: agents preserve order?

17:23 amalloy: Rosnec: send N actions to a single agent; it queues them up and executes them one at a time

17:24 Rosnec: amalloy: I see

17:24 justin_smith: Rosnec: yeah, I am double checking, but it should execute first come first evaluated

17:24 Bronsa: while we're at it, (.someNonExistentMethod ^SomeClass (foo)) doesn't fail but simply produces a reflection warning, does anybody know why that would be desiderable behaviour?

17:24 amalloy: Bronsa: that typehint almost certainly gets discarded during macroexpansion

17:25 Bronsa: (I just fixed a typo in raynes/fs two days ago .toUrl => .toURL that would have been avoided if this wasn't true)

17:25 amalloy: no it doesn't

17:25 amalloy: (fn [^String x] (.foo x)) compiles fine

17:25 amalloy: no, i guess you're right

17:26 seeing a typehint on a list made me think of http://dev.clojure.org/jira/browse/CLJ-865 immediately, but that's not the problem here

17:27 Bronsa: amalloy: yeah sorry, was assuming (foo) to be a function call

17:27 amalloy: Bronsa: well, you can imagine it being useful for non-final classes: (fn [^IFoo x] (.foo x) (.bar x)) ;; x needs to implement two interfaces

17:27 obviously it's better to typehint x in both places; i'm just saying you can imagine wanting to call methods that aren't in the interface you've tagged as

17:28 chare: so in using clojure for web stuff how am i suppose to deal with csrf

17:29 brunov: chare: https://github.com/weavejester/ring-anti-forgery

17:29 ambrosebs: tpope: should this call the disj method? (. #{1 2} (disj 1))

17:29 Bronsa: amalloy: that makes some sense, thanks

17:30 tpope: ambrosebs: yeah but timl doesn't provide a disj method, just a function

17:30 Bronsa: ambrosebs: I don't know if it's more funny that timl exists or that you're seriously trying it out

17:30 amalloy: ambrosebs: disj isn't a method (on the jvm, anyway) - maybe you mean disjoin?

17:30 chare: brunov so why doesn't this web development with clojure book mention that?

17:30 ambrosebs: Bronsa: at 5.30am

17:31 Bronsa: ambrosebs: that might explain it

17:31 ambrosebs: tpope: how do I call it from timl?

17:31 brunov: chare: because the author was scarred by a bad romantic relationship with a girl named CSRF

17:32 ambrosebs: Bronsa: it's pretty amazing

17:33 tpope: ambrosebs: err uh you pull again first

17:34 chare: brunov you saying the book sucks?

17:34 brunov: chare: no

17:34 ambrosebs: nice

17:35 tpope: before I port it, clojure.set isn't hardcoded somewhere right?

17:35 :)

17:35 tpope: ambrosebs: nope, have at it

17:36 I've implemented most of the core collection interfaces but that's about it

17:36 Foxboron: tpope: love the readme, love timl. Awesome work!

17:36 tpope: :)

17:40 ambrosebs: well that was easy. seems to just work :O

17:41 tpope: what, all of clojure.set?

17:41 ambrosebs: yes

17:41 tpope: holy shit

17:41 ambrosebs: defined about 4 clojure.core functions

17:43 https://gist.github.com/frenchy64/9923722

17:44 actually that's half of clojure.set

17:44 try my luck..

17:45 bbloom: i expect to see benchmarks.

17:45 if it's not faster than C, TimL will never take off

17:46 ambrosebs: well the rest compile, update the gist

17:46 tpope: I didn't even know about max-key

17:47 bbloom: it's funny how much stuff is "hiding" in core

17:47 brehaut: bbloom: it doesnt have to be faster than C, just elisp

17:47 tpope: also your select-keys calls clojure.lang.RT, that won't work

17:47 although I think just a plain find will

17:47 bbloom: i've contributed to cljs, the compiler proper, clojure.core itself. studied the various tools analyzers/emitters, etc. implemetned an interpreter... and STILL i find new shit in core regularly

17:47 ambrosebs: ah cool. Looking for unit tests..

17:47 amalloy: bbloom: ##(doc when-first)

17:47 lazybot: ⇒ "Macro ([bindings & body]); bindings => x xs Same as (when (seq xs) (let [x (first xs)] body))"

17:48 amalloy: more shit nobody knew was in core

17:48 bbloom: amalloy: yup, you told me about that one like last week. blew my mind

17:48 amalloy: yeah, i couldn't remember if you were in that discussion, but i figured the channel would like to hear about it anyway

17:48 ambrosebs: when-first!

17:50 TravisD: Is there a more idiomatic way to map over a map than this? (defn map-map [m f] (into {} (for [[k,v] m] [k (f v)]))?

17:51 amalloy: the weird thing is you can't actually use when-first efficiently, because it makes you call seq again anyway, in order to get the rest/next

17:51 bbloom: amalloy: you know, now that you say that, i feel like i discovered when-first long ago and then wrote it off for that reason

17:51 clojurebot: Cool story bro.

17:52 bbloom: :-( stupid clojurebot

17:52 amalloy: and in fact the only place in clojure.core where when-first is used is in the expansion of (for)

17:52 Foxboron: best response

17:52 rasmusto: ,(into {} (map (fn [[k v]] [k (inc v)]) {:a 1 :b 2}))

17:52 clojurebot: {:b 3, :a 2}

17:52 rasmusto: TravisD: ^ ?

17:52 amalloy: rasmusto: isn't that exactly what he showed, and asked if there's something better?

17:53 rasmusto: not quite, he has a list comp

17:53 amalloy: oh

17:53 his is better

17:53 Foxboron: I was wondering, currently trying to write an AI for a competition, and its the first time trying Clojure for this. Anybody know for any path-finding algorithms examples in Clojure? Found a few A* algos from a few years back.

17:53 rasmusto: oh :)

17:53 TravisD: amalloy: Ah, what makes it better?

17:54 brainkim: Foxboron: Which competition?

17:54 amalloy: TravisD: my style preference is to usually use for, using map mostly if i'm using a named function; if i have to create a lambda for map, for usually reads better

17:55 Foxboron: brainkim: Norwegian one for a LAN party in 2 weeks time. Bomberman.

17:55 rasmusto: amalloy: is there a performance difference?

17:55 TravisD: yeah, that makes sense. I wasn't sure if there was a non-stylistic reason to prefer one over the other

17:56 brainkim: Foxboron: Sounds cool, I've had similar luck re finding A* implementations, shouldn't be too hard to implement yourself though right?

17:56 amalloy: rasmusto: i doubt if; if there is one you wouldn't notice it. (for [x xs] (f x)) macroexpands into something very close to the definition of map

17:56 rasmusto: amalloy: ok, thanks.

17:57 Foxboron: brainkim: well, new paradigm, new challenges, and i don't really know the algorithms to well to make some completely from scratch. Let alone Clojure itself

17:57 Randy__: Hey guys, I'm a student and I was wondering if there is a more efficient way to implement something like membero from core.logic? I'm trying to code a sudoku relation for a valid board

17:59 hiredman: win 15

17:59 * hiredman plays the classics

18:00 gtrak: anyone played with session yet? wondering how long it might take to ramp up from nothing and embed something like a log viewer component.

18:01 is it worth trying if I've only got a couple days, basically? :-)

18:01 devn: tpope: holy shit dude. nicely done.

18:01 gfredericks: technomancy: system-slash-exit works pretty well I think

18:01 gtrak: tpope: wanted to ask you, does vim's bencode support handle nested data?

18:01 gfredericks: technomancy: oh whoops that was in reply to a really old thing

18:02 gtrak: tpope: I might want to transmit the arglists as data instead of strings, for example.

18:02 I'm going to be reworking some of that shortly.

18:03 tpope: gtrak: it should handle all valid bencode data

18:03 gfredericks: implementing a clojure is the new implementing a lisp

18:03 tpope: the parser is recursive, if that's what you're asking

18:03 Rosnec: is there a complete list of options for clojure.java.io/IOFactory?

18:03 gtrak: tpope: turns out the elisp impl was broken for some non-trivial cases :-). just asking if that scenario's too much trouble for vim, if I should try to keep the data flat more than I am.

18:04 ambrosebs: tpope: incredible, implement meta for HashMap and HashSet and I'm pretty sure you're done https://gist.github.com/frenchy64/9923722

18:04 devn: ambrosebs: now hurry up and get to work on typed.timl ;)

18:05 ambrosebs: devn: :)

18:05 rasmusto: this is the best apr1 ever

18:06 tpope: yeah meta for those was super annoying just cuz it has to survive passing through the reader

18:08 devn: i wonder if something like core.async would be possible on top of timl

18:08 tpope: any thought on that?

18:08 bbloom: devn: https://github.com/tpope/vim-dispatch

18:09 devn: bahaha

18:09 bbloom: devn: asynchronous fun times :-/

18:09 tpope: I haven't dug into core.async enough to know

18:09 presumably since it works with single threaded javascript, we could do it too

18:09 devn: that's what i was thinking

18:11 core.async uses a fit bit of deftype/defprotocol on the cljs side

18:12 tpope: a fitbit?

18:13 devn: s/fit/fair

18:13 but presumably that could be done with your version of defmethod?

18:14 either way, tpope: well done man. I knew you were toying around with a lisp in VimL post-clojure/conj and gherkin, but i didn't expect to see a full macro system, persistent colls, lazy seqs, etc.

18:14 so cool

18:14 tpope: yeah I'm of the opinion that defprotocol may be a great optimization for the jvm but it buys you verrrry little over duck typing, if namespaced properly

18:15 imagine every protocol was one method. if you've ready clojurescript's source that's not much of a stretch

18:16 jeremyheiler: tpope: i've actually been thinking about that myself, protocols are jsut single methods.

18:16 bbloom: tpope: yeah, defprotocol is a bit of a perf hack, but it helps cljs too

18:16 there are use cases for having a single thing that represents a collection of generic methods, but defprotocol doesn't capitalize on them

18:16 eg delegation

18:17 jeremyheiler: yeah

18:17 tpope: yeah I guess I could see that

18:17 bbloom: http://docs.factorcode.org/content/article-delegate.html

18:17 jeremyheiler: im not sure how much taht matters in clojure, though. protocls by definition can depend on other protocols, etc.

18:17 tpope: the only other argument for grouping methods together like that is requiring you to implement all of them. but clojure doesn't require you to implement all of them

18:18 bbloom: another thing is "tagging" of types

18:18 ie marker protocols

18:18 for use with satisfies?, even if you have no methods

18:19 tpope: I found that tagging with a single method satisfied that a loooot more than I expected

18:19 kovasb: gtrak: hopefully not too hard

18:19 gtrak: are you familiar with om?

18:19 tpope: looking for a set? check for disj. looking for a map? check for dissoc

18:20 gtrak: kovasb: I've been trying to learn om, but haven't gotten off the ground yet, I think I finally understand cursors though.

18:20 kovasb: gtrak: definitely recommend working through the tutorial

18:21 gtrak: kovasb: session looks great though, I want to try to extend/embed it in general.

18:21 kovasb: gtrak: its also possible to skip defining your own component, and just use the builtins to do the layout

18:21 gtrak: awesome. feel free to post on the mailing list if u have detailed questions

18:21 gtrak: sweet, thanks!

18:22 Rosnec: is there a way to open a file for writing in append mode, but delete whatever was originally in the file?

18:22 gtrak: Rosnec: delete the file first? then re-open it?

18:23 Rosnec: gtrak: that's what I figured

18:23 that assumes nothing else creates and writes to the file in the meantime

18:23 although I'm not really worried about that

18:24 gtrak: does the OS even prevent that? I thought it was just windows.

18:24 Rosnec: isn't there a lock on the file when you're writing to it?

18:25 technomancy: isn't deleting the current contents basically the same as writing in not-append mode?

18:26 amalloy: yeah, exactly, what technomancy said

18:27 ivan: append mode changes seek behavior as well

18:28 writes automatically seek to the end first

18:29 doky: hello is it possible to handle multiple login sessions on one computer ?

18:30 ivan: doky: is that a Clojure question?

18:31 doky: sure, im using compojure and ring.middleware

18:31 amalloy: i like the idea that it's impossible, that facebook and google have one server per user

18:32 doky: ivan: sure, im using compojure and ring.middleware, and when i login with one user and then with the other .. there is only one session

18:33 amalloy: i only want to know how it works and why in session i have only one user if on one pc i login with 2 accounts

18:33 gtrak: doky: try two browsers?

18:33 doky: no only one

18:33 justin_smith: doky: the session should be bound per request to that user's session

18:34 gtrak: a cookie would be shared across each tab in a single browser.

18:34 justin_smith: so each request should only see that user's session

18:34 bodie_: let's say I want something to be somewhat precisely timed (down to say 16ms precision) -- is there any way to achieve this? perhaps via threading jobs out and killing ones that aren't finished within the time window?

18:34 gtrak: bodie_: yup

18:34 https://github.com/gtrak/quilltest/blob/master/src/quilltest/core.clj#L11

18:34 bodie_: scheduleAtFixedRate will give you a reliable tick

18:34 justin_smith: bodie_: also consider traversing flat collections of unboxed data if latencies must be precise

18:35 doky: yes i have there there set timeintervals

18:35 bodie_: awesome

18:35 justin_smith: (less garbage created, better cache performance, etc.)

18:35 bodie_: yeah

18:35 gtrak: bodie_: got it from this: http://stackoverflow.com/questions/5274619/investigation-of-optimal-sleep-time-calculation-in-game-loop

18:35 bodie_: :D

18:35 you guys rule!

18:35 cbp: doesnt youtube basically have to do that because of python anyway? One server per request :-P

18:36 justin_smith: cbp: you can use a front like nginx and a group of python processes in a pool

18:36 bodie_: ( justin_smith, as opposed to normal collections which are linked lists, right?)

18:37 justin_smith: bodie_: not neccissarily - like a vector is not a linked list, but it is not cache friendly because each item is just a pointer to the jvm heap

18:37 that's what I mean by flat / unboxed

18:37 this is important for things like audio where small timing errors turn into erroneous signals, for things like video your timings will be more forgiving and you may not need to optimize the architecture that much

18:39 guns: ambrosebs: I see you are trying TimL; does the K lookup command work for you?

18:39 bodie_: yeah, i took this train of thought because i've been playing around with emacs live a tiny bit

18:39 i.e. overtone and quil

18:40 ambrosebs: guns: I don't think there are docstrings

18:40 justin_smith: yeah, overtone solves it by farming it all out to another program entirely

18:40 bodie_: heh

18:40 justin_smith: (scsynth is standalone)

18:40 guns: ambrosebs: But do you get an error or just nothing?

18:40 justin_smith: java doesn't even touch audio data anywhere in overtone

18:40 guns: ambrosebs: cp{motion} works for instance

18:40 bodie_: right, it's more like an interface wrapper

18:40 justin_smith: and of course in scsynth all the audio signals are flat unboxed arrays

18:40 ambrosebs: I get invalid express, blah cursor_keyword()

18:41 bodie_: hm

18:41 guns: ambrosebs: thanks

18:41 justin_smith: bodie_: even better, it is a network protocol client

18:41 scsynth is controlled over UDP using the OSC protocol

18:41 ambrosebs: the rest of the fireplace bindings seem to work better than in fireplace

18:41 bodie_: :)

18:41 guns: I updated vim-sexp for timl (a tweak) and it works great

18:41 ambrosebs: well, they're good

18:41 justin_smith: you could do the same thing overtone does with bash+curl

18:42 bodie_: just realized I just followed you on twitter :P

18:42 that's neat

18:42 justin_smith: probably a different justin smith

18:42 there are thousands of us, literally

18:43 bodie_: only a few bodies, haha. I'm probably getting the names mixed up anyhow

18:43 anyway, thanks much for the pointers

18:43 justin_smith: np

18:43 seangrove: In fact, justin_smith isn't Just Smith, it's just one of the most anonymous names he could pick

18:43 ambrosebs: guns: I like how functions get highlighted in green as soon as you eval them

18:43 bodie_: one thing I think is way cool about this community is that most of you actually seem to know what you're doing

18:43 guns: ambrosebs: that actually breaks rainbow_parentheses

18:44 ambrosebs: And vim-clojure-highlight will do the same at least if you reload the file

18:44 ambrosebs: hmm rainbow_parentheses seems fine, what breaks?

18:45 guns: Doesn't the eval re-define the paren syntax statements?

18:47 ambrosebs: guns: I don't think so

18:47 guns: I use cp% to eval

18:48 guns: ambrosebs: Must be local to me

18:50 doky: so i will try do describe my problem more detailed: i run rest api, now i gettig info about user - if is logged by asking /current-user when i am logged in one tab it works, but when i login with other user in other tab, the /current-user returns last logged user ... haw can i handle this ?

18:51 justin_smith: doky: I think the cookies are not per tab but per site/browser

18:51 doky: if nobody is logged it returns {}

18:51 justin_smith: try using a second browser or second browser profile

18:52 doky: justin_smith: and is there any other way ?

18:52 justin_smith: not that I know of, browsers are expected to share cookies across tabs

18:52 doky: ok, thank you :)

18:52 justin_smith: unless you wanna pull some janky magic like google does to allow multiple simultaneous gmail logins

18:53 hiredman: doing a disservice to magicians everywhere

18:53 bodie_: but not janky magicians

18:53 doky: that is what i was asking for first ...

18:53 amalloy: hiredman: i dunno, isn't he implicitly suggesting that most magic isn't janky?

18:54 doky: justin_smith: thanks

18:54 justin_smith: np

18:54 hiredman: amalloy: he is still associating magic with google's ridiculous multi account stuff

18:55 amalloy: i dunno, i like the multi-account stuff

18:55 or maybe i like something else but believe it to be the multi-account stuff

18:55 justin_smith: I was only intending to suggest it was failure prone (in my experience) and definitely not simple to implement

18:56 lemonodor: google’s approach is ugly but i’m not sure if there’s really a better way at the moment. i’m up to like /u/4 now.

18:57 (well, the other way is to have a browser per account)

18:57 justin_smith: profiles are underutilized (and definitely not as easy as they should be)

19:00 bjeanes: tpope: holy cripe man ... (re: timl)

19:11 Frozenlock: "Please take a moment to tell us what you think about this guide on Twitter." There's probably something wrong with email that I've yet to understand.

19:12 (considering I don't have Facebook/Twitter/whatever account, I find this annoying.)

19:12 michaniskin1: social media: it's a thing

19:12 coventry: The problem is that your friends don't get to see your communication with the marketers if you use email.

19:14 cbp: It could be interpreted as "this 140 character guide"

19:20 rasmusto: tpope: :TLscratch is amazing

19:25 tpope: forgot about that. I had been entertaining it as a potential addition to fireplace

19:26 rasmusto: tpope: I wasn't able to get my own foo.tim file to eval and connect to a repl, so I found this

19:27 tpope: it has something to do with my namespace name and directory hierarchy as far as I can tell

19:27 tpope: you should be able to :source % in it regardless

19:28 but you need the right directory hierarchy to (require) it

19:28 rasmusto: im getting an error, let me paste it, sec

19:30 ambrosebs: tpope: +1 for fireplace

19:31 technomancy: addition to fireplace?

19:31 you mean you're not just porting fireplace to it?

19:31 =D

19:31 tpope: that was my plan!

19:32 but I don't know, I'm increasingly skeptical of timl

19:32 bbloom: tpope: you mean you haven't already started porting ALL of your existing plugins?

19:32 tpope: which is why I salvaged it into a big old april fools' joke

19:32 technomancy: tpope: sounds vaguely remniscient of mirah

19:32 tpope: I remember mirah

19:33 technomancy: started out as "this is a cool runtime; I wish there were better languages I could use in it to work on my primary projects"

19:33 but I don't think that actually panned out

19:33 kencausey: I'm trying to use https://github.com/boechat107/cloxls but it has lots of reflection warnings. To what extent is this a problem beyond the noise level and what is the right way to fix it?

19:33 rasmusto: tpope: https://gist.github.com/rasmusto/9925149 error when trying to :TLsource a simple file

19:33 tpope: there's a lot of interop friction in the dumbest places I didn't even think about

19:34 hiredman: kencausey: depends, do you care if it is using reflection?

19:34 kencausey: hiredman: uhm, I don't know enough to know whether or not I should care.

19:34 tpope: e.g. I made 0 true (because duh) but 0 is the canonical false value in viml

19:34 hiredman: kencausey: then you don't :)

19:35 kencausey: I'm confused that boechat has explicitly enabled warn-on-reflection and yet has not addressed the warnings.

19:35 tpope: rasmusto: ew, not sure what that is but it doesn't look like a path issue

19:35 technomancy: tpope: do you have true/false as symbols or something?

19:35 hiredman: kencausey: that seems odd

19:35 kencausey: I just wouldn't use the library

19:35 rasmusto: tpope: maybe cwd should be at the project root?

19:35 kencausey: Maybe the project is delayed in an in between state

19:35 tpope: viml doesn't. I made true/false singletons for timl

19:36 kencausey: There seems to be no other choice other than to use poi directly myself

19:36 I expected I was going to have to expand cloxls anyway as it is far from complete

19:36 tpope: rasmusto: nah I tried with /tmp/test.tim and it worked fine for me

19:36 hiredman: kencausey: it seems unlikely to add much value plus it does add the uncertainty

19:36 so skip it

19:36 kencausey: So I guess what I'm really wondering, should I just disable warn-on-reflection?

19:37 hiredman: kencausey: it isn't even the top hit if you google clojure excel

19:37 kencausey: I guess I have a little hesitancy when it comes to java interop.

19:37 tpope: rasmusto: I suspect some sort of weird load issue. chunked-seq? is looking for chunk-first and can't find it

19:38 kencausey: OK, then I guess my mistake then is relying on the data in clojars

19:38 hiredman: kencausey: have you looked at clj-excel?

19:38 kencausey: Not until now

19:39 hiredman: I dunno, I never use the clojars website for anything, but others must, I guess

19:39 kencausey: I guess I stopped with I found a result for xls

19:39 s/with/when/

19:39 Thanks

19:39 I was surprised to get a result and pretty much assumed that it was all I was going to find, with no good reason.

19:39 rasmusto: tpope: hm, works if I vim the file from ~ as dir/ras/test.tim, but not if I'm in ~/dir and load ras/test.tim

19:40 hiredman: the idea that clojars search is going to be better than googles is kind of laughable :) on the other hand just because google finds a library that doesn't mean it is going to be in a maven repo, but it generally is

19:41 rasmusto: tpope: ah, same thing happens if I `cd tmp` and `vim test.tim`

19:41 xeqi: clojars search is just lucene search on {name,description,etc} + some weighting based on downloads

19:41 tpope: rasmusto: check :echo has_key(g:timl#core, 'chunk_first') in both contexts

19:41 holo: hi

19:41 kencausey: hiredman: This is is the sort of thing that trips up noobs like myself

19:41 rasmusto: tpope: 0 for the failing case, 1 otherwise

19:42 tpope: my guess is whatever you're doing immediately after starting vim is triggering some botched load

19:42 rasmusto: tpope: k, let me clean up some vimrc stuff

19:42 holo: where can I find some nthrest equivalent for clojurescript?

19:42 amalloy: &(doc drop)

19:42 lazybot: ⇒ "([n coll]); Returns a lazy sequence of all but the first n items in coll."

19:43 tpope: I had tons of different circular dependency issues when developing timl

19:43 I think they're ironed out, but I'm guessing you found another

19:45 holo: amalloy, okay, I guess I can use that one instead :)

19:45 (inc amalloy)

19:45 lazybot: ⇒ 93

19:45 amalloy: i've never used nthrest in my life. nthnext is occasionally useful, but most of the time drop is fine

19:47 cbp: I had no idea those 2 functions existe

19:48 tpope: other than argument order is there a substantial difference between nthnext and drop?

19:50 holo: tpope, drop is lazy, nthrest isn't. also it appears the latter is not available in cljs, whereas drop is

19:51 tpope: oh duh thanks

19:51 amalloy: tpope: drop returns a lazy seq, nthnext is eager and returns nil instead of (). i dunno about nthrest, but i assume it's a version of nthrest that for some crazy reason returns ()

19:51 er, of nthnext

19:51 tpope: ya exactly, that adds up with your dismissal of nthrest

19:51 amalloy: &(doc nthrest)

19:51 lazybot: ⇒ "([coll n]); Returns the nth rest of coll, coll when n is 0."

19:52 tpope: oh I looked at the source, the lazy-seq just didn't register

19:54 holo: amalloy, did you mean: *i dunno about drop, but..

19:55 amalloy: holo: no, i know all about drop. i don't know about nthrest because i've never used it

19:56 then i said what i assume it must do (i was right), and said i can't imagine why you'd want it

19:57 in clojure.core, nthrest is used in partition and partition-all, and nowhere else

19:57 holo: ,(drop 0 nil)

19:57 clojurebot: ()

19:57 holo: ,(nthrest nil 0)

19:57 clojurebot: nil

19:57 bbloom: ,(drop 0 [])

19:57 clojurebot: ()

19:57 rasmusto: tpope: disabling my other bundles fixed this, I'll pinpoint which one breaks things at some point

19:57 rootex: ,(rest [])

19:57 clojurebot: ()

19:57 rootex: ,(next [])

19:57 clojurebot: nil

19:58 tpope: rasmusto: cool let me know. timl could still be to blame

19:58 it jacks into autoloading

19:59 holo: amalloy, this old code where I use nthrest is an argument for some->>, so I guess I wanted to short circuit on nil

20:04 no, that wasn't the reason. anyway, not a good idea for portable code

20:08 amalloy, oh i get it:

20:08 ,(nthrest "bla" 0)

20:08 clojurebot: "bla"

20:09 rasmusto: tpope: I think it's pathogen. I have .vim/bundle/... and .vim/timl/... (identical), and "execute pathogen#infect()" and "execute pathogen#infect('bundle/{}')" fail, while "execute pathogen#infect('timl/{}') succeeds

20:09 holo: ,(drop 0 "bla")

20:09 clojurebot: (\b \l \a)

20:09 holo: this was the reason

20:09 amalloy: holo: that only matters for specifically 0. after that, you're seqing

20:09 tpope: rasmusto: oh timl/{} will add all *subdirectories* of timl, not what you want

20:10 rasmusto: try pathogen#incubate('timl') for a more accurate comparison

20:10 rasmusto: tpope: sorry, that was a bad choice of directory name, should have been timl-bundle-test-directory

20:10 gozala: cemerick: ping

20:10 rasmusto: timl/timl was a thing.

20:10 holo: amalloy, true :) thanks

20:10 gozala: cemerick: I’m having trouble with async tests was wondering if you could help

20:11 tpope: rasmusto: so is there other stuff in there? sounds to me like you disabled all your other bundles and it works

20:11 btw as author and #1 user of pathogen it seems like an unlikely culprit by itself

20:12 rasmusto: tpope: both vim/bundle and vim/timl are identical. I reenabled everything and when I infected using timl/{} it all works.

20:12 tpope: rasmusto: oh maybe something is fucked in your cache

20:13 export TIML_EXPIRE_CACHE=1 while testing all this

20:14 rasmusto: tpope: that did it. Maybe I should have kept the old cache around to pinpoint the bug...

20:15 tpope: uh yeah haha

20:15 oh well

20:15 rasmusto: where's the cache end up?

20:15 tpope: also maybe absolute/relative path was being cached separately somehow? it shouldn't be...

20:16 ~/.cache/vim/timl

20:16 clojurebot: Cool story bro.

20:16 tpope: yeah I see relative paths in there, fuck me

20:16 shut up clojurebot

20:18 oh those are verrrrry old files, dating back to when I first implemented caching

20:18 keep an eye out for that but nothing conclusive

20:18 rasmusto: tpope: ok, will do

20:19 oo, these are compiled .tim files

20:19 tpope: yup

20:19 gozala: cemerick: anyway if you’ll have a chance to to look at it, this is an issue I’m having https://github.com/cemerick/clojurescript.test/issues/56

20:20 rasmusto: next up: VimL minifier

20:20 tpope: anyways, thanks for the help. This is a damn cool project

20:49 jeregrine: so whats everyone using for html templating?

20:50 milinda: hi all, is it possible to reify abstract class

20:52 amalloy: no

20:52 mpblair: no

20:52 milinda: amalloy: is proxy the solution for my problem?

20:53 amalloy: i couldn't possibly say. so far all i know of your problem is that you thought reifying an abstract class might be a solution

20:56 milinda: looks like proxy may be the only solution for the current mechanism I used. I need to rethink my solution in the next iteration.

20:58 seangrove: xeqi: The weighting based on downloads is pretty cool

21:00 arrdem: seangrove: what are you reading?

21:01 seangrove: arrdem: <xeqi> clojars search is just lucene search on {name,description,etc} + some weighting based on downloads

21:01 arrdem: at 18:34. ah.

21:23 Frozenlock: michaniskin: Playing around with validateur. Any reason why the validation functions all take a message-fn, by not the `validate-with-predicate'?

21:26 *but

21:31 rasmusto: (do (prn "foo") (execute "normal cpp")) ; don't know why this cracked me up so much

22:07 bodie_: anyone familiar enough with quil to help me understand what's wrong with this sample code? https://github.com/gtrak/quilltest/blob/master/src/quilltest/core.clj#L11

22:07 I think quil.dynamic was removed.

22:10 so, everything up to line 32 works. I guess that would be replaced with "setup" now.

Logging service provided by n01se.net