#clojure logs

2013-12-23

00:00cemerickxeqi: ouch; conveyance fail?
00:07alewIs there anything you can do if one of your dependencies dependencies depends on an earlier version of a library that you depend on?
00:07alewexclusions seem to only work for direct dependencies
00:07justin_smith:exclusions
00:08justin_smithhmm - you sure of that?
00:08cjfriszethanis: just noticed that #typed-clojure was less helpful than I'd hoped. Having any luck with your errors?
00:08TEttingermy approach is not recommended, but fork, update, post parallel version to clojars
00:08justin_smithalew: did you verify with lein deps :tree that it wasn't coming in from another dep path?
00:08alewlein deps :tree shows a library called clucy
00:08alewwhich depends on lucene libs
00:08TEttingeruhhhhh
00:09alewonly from looking at it
00:09TEttingerI really hope you didn't use my clucy
00:09alewno
00:09TEttingergood, because I regret putting my version of clucy on clojars
00:09TEttingerit has slightly different behavior, which I needed for efficient queries in an IRC bot
00:10alewdo people use it?
00:10TEttingerI use it
00:10alewregardles, clucy depends on these libs, but they don't show up in the dependency tree
00:10alewI'm guessing because they aren't on clojars?
00:10TEttinger???
00:10lazybotTEttinger: How could that be wrong?
00:11TEttingerthey might be on maven central
00:11TEttingerpaste your deps :tree ?
00:11justin_smithalew: if there is aot compilation somewhere in there, that can fuck things up
00:12alewhttps://www.refheap.com/22136
00:13TEttingerthanks
00:13justin_smithand which is the problem, clucy 0.3.1?
00:14alewyes
00:14alewas you can see
00:14alewit doesn't show it's dependencies on lucene
00:14alewits*
00:14justin_smithright
00:14justin_smithnotice the exclusion above
00:14justin_smithas asked for
00:15alewyup
00:15justin_smithso what's the problem?
00:15alewelastisch requires a newer version of lucene
00:16alewit isn't getting included
00:16alewoh I see
00:16alewthe thing is even if I do remove the exclusions
00:16alewit doesn't show the deps
00:16justin_smithodd
00:17alewhttps://www.refheap.com/22137
00:18justin_smithlooks like the lucene stuff is coming in under elastisch instead
00:19alewOh I see
00:19alewso the error is in clucy
00:19alewwhat to do then. They both require the same library with incompatible versions
00:20TEttingerthis looks like a question for #leiningen !
00:21justin_smithhmm, two apps :) ??
00:21lazybotjustin_smith: Uh, no. Why would you even ask?
00:25justin_smithalew: you can use caribou without it's clucy dep if you don't need lucene indexing of the CMS content
00:25justin_smiththat may be the easiest route
00:25alewI would have to modify the clojar
00:26alewand remove the index file
00:35rhg135hey, any obvious reason the accept println fires twice but the grabbed doesn't ever https://www.refheap.com/22138
00:35rhg135trying to make a smallish abstraction over serversockets
00:36rhg135something in my gut says that it's a fundumental problem in my approach
00:36rhg135but i don't see it
00:42rhg135ah i'm such an idiot lol
00:42rhg135thanks for the ruber-duck debugging
00:51pcnDoes anyone know if there's a way to have a somewhat large float not print using scientific notation when I pass it to the clojure.data.json/write-str function?
00:52pcn,(/ (float (System/currentTimeMillis)) 1000)
00:52clojurebot1.38777788416E9
00:52pcn,(str (/ (float (System/currentTimeMillis)) 1000))
00:52clojurebot"1.38777788416E9"
00:52pcnI'd really like to be able to change the scale at which values are displayed using scientific notation
00:56pcnThough I guess in this case I'm not losing an precision.
01:03xeqicemerick: finally tracked it down, turns out not to be a binding conveyance problem
01:03KeithPMGood day, when would you recommend the use of -> and ->> for someone who is learning clojure? I am attracted to it since it seems to help with the issue of deeply nested functions and data structures. What is the general experience with their use? Thnaks.
01:07xeqicemerick: if interested... anything calling println (like interruptible_eval's :caught through repl-caught) binds *print-readably* to nil, and writes to *out*. *out* was a session-out which calls the transport on flush. the transport called (pr-str ..) and got unexpected results
01:22ddellacostaKeithPM: if you see a whole mess of parens at the end of the function, it's possible that there's an opportunity to use -> or ->> to make your code more clear.
01:23ddellacostaKeithPM: And generally speaking, I find -> to be useful when I'm processing one value going through a chain of transformations, versus ->> seems to usually be used when I'm processing a collection going through a set of collections. You'll notice that many clojure functions which process collections require the collection as the final argument--map, filter, reduce, etc.
01:25ddellacostasorry, I misspoke: with "set of collections" I mean to say something along the lines of, "set of transformations"
01:25ddellacostaor chain of transformations, as in the previous sentence
01:28KeithPMI like that answer ddellacosta!! That was my intuition but I wanted to know whether it was idiomatic or just academic. I just wrote a pair? function and ended up with 6 closing brackets and thought, maybe this is the time to start learning to use thread first :)
01:29pcnIs Raynes around?
01:29ddellacostaKeithPM: great, glad it was helpful. Yeah, I think that it's good just to try it out and get an intuition yourself for when it works and when it's trying to fit a "square peg in a round hole" so to speak. But it can definitely help clarify your code when you start seeing the kind of pattern you describe.
01:30pcnOr is there anyone else familiar with his filesystem module, or with java 7 and its file manipulation routines?
01:31ddellacostapcn: I've used it a little, but ask your question first and we'll see if anyone can help.
01:31pcnIt looks like https://github.com/Raynes/fs/blob/master/src/me/raynes/fs.clj#L174 breaks because the taret doesn't exist
01:32KeithPMThank you ddellacosta.
01:32ddellacostapcn: do you have some more context? How are you calling it? Etc.
01:32ddellacostaKeithPM: any time!
01:32pcnSo for example: https://gist.github.com/pcn/8092544
01:34ddellacostapcn: seems like maybe you just want to call the args in the opposite order? http://docs.oracle.com/javase/7/docs/api/java/nio/file/Files.html#createLink(java.nio.file.Path,%20java.nio.file.Path)
01:34pcnI tried both
01:34pcnI'll add that
01:34ddellacostapcn: hmm...well, it seems like that's obviously the error in this case--but do you get the same error if you switch the args?
01:35pcn(yeah, I noticed that java decided to put things in the opposite order from the system call. *sigh*)
01:35ddellacostapcn: sorry if you already looked it up--I always start with the dumb questions. ;-)
01:36pcnYes, I updated the gist
01:36pcnI looked it up before, and checked the code. It seems like the most likely reason is that as-path checks to see if its argument exists in me.raynes.fs
01:37pcnHaven't checked to see how as-file works yet.
01:37KeithPMOops the names of the symbols are 'thread second' and 'thread last' sorry
01:37pcnsorry, that should be as-file
01:37ddellacostapcn: huh...I don't know, but my strategy would be to try calling the Java calls themselves to establish that there was nothing weird there, then you would know clearly where the issue is, I suspect
01:37ddellacostapcn: sorry I don't have a better answer!
01:39pcnNP, I'll head down that road. Weird that as-file isn't causing the problem by itself. Down the rabbit hole
01:42pcnddellacosta: So it's not clojure.java.io/as-file, it's this: https://github.com/Raynes/fs/blob/master/src/me/raynes/fs.clj#L155
01:42pcnI have no idea what that means
01:43ddellacostapcn: where is as-file getting called?
01:45pcnOh....
01:45pcnDarn, I'm getting turned around. in the definition of link, it is as-path
01:47ddellacostapcn: what do you get when you call file on the path you pass in (the one you are linking to that is)
01:47ddellacosta?
01:53pcn(fs/file target) is fine so far
01:57pcnOK, I see my problem.
01:57pcnI've got an extra "/" in the name
01:57pcnAnd I'm putting the arguments in the reverse order from what I'd expect.
01:58pcnWhy oh why oh why is createLink in the opposite order as the system call?
02:07OtherRavenI've got a noobish question: How do I go about extending a java class to implement a java interface? I'm trying to make a renderer for a listbox that's not the default label.
02:11pcnddellacosta: https://github.com/Raynes/fs/pull/65
02:14ddellacostapcn: so, did that fix it?
02:15ddellacostapcn: oh sorry, just saw your messages
02:15ddellacostacool
02:15ddellacostaOtherRaven: there are different ways to do it--if you just want to add a method then you can use extend-type
02:16OtherRavenddellacosta: what about proxy?
02:16ddellacostaOtherRaven: I found these two posts to be super helpful regarding that subject: https://kotka.de/blog/2010/02/gen-class_how_it_works_and_how_to_use_it.html and https://kotka.de/blog/2010/03/proxy_gen-class_little_brother.html
02:17OtherRavenddellacosta: Oooh, I'll check those out.
02:17ddellacostaOtherRaven: yeah, proxy may be more what you want
02:18OtherRavenddellacosta: thanks XD
02:18ddellacostaOtherRaven: sure thing!
02:20ddellacostaOtherRaven: sorry, re-reading your question I realize you want to create an interface--I'm not sure how to do that in Clojure
02:22ddellacostaOtherRaven: definterface creates a new interface...
02:23OtherRavenddellacosta: newp, don't need to create an interface, just implement it
02:23OtherRavenddellacosta: I'm extending JPanel to implement ListCellRenderer... and cursing at swing
02:23ddellacostaOtherRaven: ah, in that case, I know gen-class can do that.
02:24OtherRavenddellacosta: sweet
02:24ddellacostaOtherRaven: oh, have you checked out https://github.com/daveray/seesaw ? May have some good examples for what you want to do, at the least.
02:25OtherRavenddellacosta: yeah, I'm using seesaw... it's great for the simple stuff, but doing anything more complex seems to require java interop
02:26ddellacostaOtherRaven: ah okay, sorry--nevermind!
02:27ddellacostaOtherRaven: I also recommend the Joy of Clojure section on Java interop, if you have a copy...in any case, I've just about exhausted my pretty limited knowledge of Java interop, so you're on your own from here--but good luck!
02:28OtherRavenddellacosta: that book is sooo hard... I'm reading through Clojure Programming instead, but doing is usually more fun than reading XD
02:28ddellacostaOtherRaven: I hear ya...haha. :-)
02:29ddellacostaOtherRaven: well, it is a useful book when you find you really need to understand a particular topic in Clojure. I can tell you struggling through it can be very useful!
02:31OtherRavenddellacosta: Yeah, I'm planning to give it another try when I've got the basics down a bit better. It seems to go by those relatively quickly.
02:32ddellacostaOtherRaven: yep, I think your intuition is right--in my opinion, Clojure Programming is definitely a better first Clojure book, I think. Joy of Clojure is good when you want to deepen your understanding further. They are good companions to each other, I think.
02:33OtherRavenddellacosta: makes sense
02:40pcnI just ran an experiment where I sent about 1000 short messages via a small program. Each message is read from an open socket (all are coming in one per line over a single socket). The message is "some text" <a number> <another number>\n
02:41pcnAfter processing 10000 of them (not 1000, sorry) and writing them out to disk, my laptop's fan went crazy and didn't stop until I killed the java process.
02:42pcnAll messages were already written out, the socket was closed from the client. Any ideas as to how to investigate what was causing the activity?
02:44TEttingerit could have run out of memory, so it wasn't able to continue to process messages or something
02:44TEttingerI've gotten similar stuff with very large data sets
02:44TEttinger(as in, infinite)
02:45pcnI'd be really surprised if that was the case here. As I said, 10,000 lines of input, and all were written out. The repl was still responsive
02:45TEttingeralso, you closed the sockets, right? I admit I haven't worked (at all) with networking code, but they are file-like in that they need to be closed?
02:46pcnThey are, but there is only 1, and it was closed on the client side
02:46pcnWhile there could be a leak, there were none opened afterwards
02:46TEttingerpaste your code?
02:46pcnLet me push it up to github
02:50l1xis there a way to print out the exact execution for a recursive function? https://gist.github.com/l1x/8093128
02:51pcnTEttinger: https://github.com/pcn/carbon-relaj
02:54TEttingerpcn, thanks. unfortunately I have no idea how to use the async stuff. I bet someone here will know how, when they become active
02:54pcnCool.
02:55pcnThanks for looking at it
02:55TEttingerheh, sorry I couldn't be more help
02:58OtherRavendellacosta: well, I figured it out... looks like proxy is the way to go, and it's disgustingly simple XD
02:59pcnI'll try again when I get up. It's way past my bedtime. Have a good night, all.
03:08ddellacostapcn: g'night!
03:08ddellacostaOtherRaven: nice, glad to hear it. ;-)
03:19KeithPMHi is anyone out there using light table 0.5.20?
04:25magnarsWhat is the reason to use jetty over just creating an upstart service that runs java -jar ?
04:34sm0kehas it happened to someone that putting a new dependency in project.clj caused existing namespaces to throw errors on evaluation?
04:43sm0kevery vauge question i see
04:43seriously_randomhaving brain malfunction with reduce: http://pastebin.com/CDVS5pfn
04:46magnarsseriously_random: you are looking for clojure.core/interpose
04:46seriously_randommagnars, if it were so easy. I am supposed implement my own interpose.
04:49sm0keOk guys if i put https://github.com/elasticsearch/elasticsearch-hadoop dependency, nippy seems to be found nowhere in the classpath inspite of being in the project.clj as dependency
04:49sm0kewtf
04:50magnarsmaybe lein deps :tree has some answers?
04:51sm0kemagnars: nothing except that its listed there
04:51sm0keno one else is pulling nippy
04:52sm0kemay be lein is limited in no. of jars in the classpath
04:57sm0kelein classpath shows nippy
04:58sm0keCompilerException java.lang.IllegalArgumentException: No matching method: compress, compiling:(taoensso/nippy/compression.clj:18:22)
05:22seriously_randomthis done in less amount of code: (reverse (conj (conj '() x) 4))?
05:31seriously_randommagnars, think I almost got it: http://pastebin.com/5Jg4MYJ5
05:36ior3kseriously_random: I think you want (interleave '(1 2 3) (repeat 4))
05:37seriously_randomior3k, sorry, I have to use reduce to re-implement interpose
05:37ior3koops, sorry about that then
05:44seriously_randomior3k, any idea where the mistake might be: http://pastebin.com/vJLvabyg ?
05:44Cr8seriously_random: I have a working something-magical
05:45Cr8but i'm a bit lost as to -why- you want to do this =P
05:45seriously_randommooc, internet points
05:46seriously_randomit is possible to pass anonymous fn to reduce, right?
05:46Cr8yes
05:46ior3kseriously_random: fn should take 2 arguments
05:46Cr8I cheated with metadata =P
05:47ior3kseriously_random: btw, it's possible to do that with less code, even using reduce
05:48seriously_randomior3k, ok.
05:49hyPiRionThat's like
05:50hyPiRion,(let [z 4 a-seq [1 2 3]] (reduce #(conj %1 %2 z) [] a-seq)) ; ?
05:50clojurebot[1 4 2 4 3 ...]
06:07seriously_randomwhy does this happen: http://pastebin.com/1exF9xHM
06:11ior3kseriously_random: you're lost in a web of conjs. Try approaching the problem methodically. You already have the magic fn. Did you test it?
06:11ior3kjust the magic fn, not the entire thing
06:12seriously_randomior3k, (magic 1 :c) ;=> (1 :c)
06:13ior3kseriously_random: are you sure that fulfills the contract required by reduce?
06:14seriously_randomior3k, not then it reaches the last element
06:18seriously_randomior3k, uhh. discard the last message
06:18ior3kseriously_random: I think there are more problems than that one.
06:21seriously_randomior3k, what is 'a-what' in "(fn [a-what x] (conj (magic x z) a-what))". Is it previous sequence?
06:24ior3kseriously_random: it's the accumulator. It can be a) whatever fn returns, or b) the initial value passed to reduce, or c) the first argument of the collection passed to reduce
06:28Cr8(reduce f init [a b c d]) gives the same result as (f (f (f (f (f init) a) b) c) d)
06:29Cr8f is called with two args: the thing it returned the last time it was called, and the next element in the collection, until the collection is exhausted, and then reduce just returns the current value of the accumulator
06:31Cr8,(reduce (fn [acc el] (if (odd? el) (inc acc) acc)) 0 [1 2 1 2 3 3 4])
06:32clojurebot4
06:32Cr8^- counted the number of odd numbers in that coll
06:35seriously_randomanon functions and reduce is a confusing mix
06:36seriously_randomnested one level too deep: http://pastebin.com/DZCzgrCq
06:38Cr8tip: conj'ing onto a vector puts stuff on the end
06:39Cr8,(conj '(1 2) 3)
06:39clojurebot(3 1 2)
06:39Cr8,(conj [1 2] 3)
06:39clojurebot[1 2 3]
06:40seriously_randomCr8, I know. I will put another reduce inside the reduce! :)
06:43Cr8tip: What should I get if I interpose something into a sequence that only has one element?
06:44rurumateI'm having trouble doing a "prepared insert" in cassaforte. Unprepared version works fine, but when I wrap with client/prepared and values, I get 'InvalidQueryException: Unknown identifier values'
06:44seriously_randomCr8, preferably the one element itself
06:44Cr8seriously_random: yep
06:44Cr8,(interpose :a [1])
06:44clojurebot(1)
06:44Cr8,(interpose :a [1 2])
06:44clojurebot(1 :a 2)
06:46seriously_randomCr8, the problem is - isn't the a-seq outside the scope of anonymous fn? How to tell it if we are at the last element?
06:46Cr8you can't, meaning so you can't add element, separator for each element
06:46Cr8you can add separator, element though
06:47Cr8and start with the accumulator not being the empty list, but the first element of the input coll (and then feed reduce, not the input coll but (rest coll))
06:47Cr8that is, the first element in a list, not bare, of course
06:47rurumateI made a paste out of it, see https://www.refheap.com/22141
06:49seriously_randomCr8, that make sense.
06:50Cr8(reduce f init []) will always return init, f never gets called if the input collection is empty
06:51Cr8,(reduce (fn [a x] (throw "explode")) 0 [])
06:51clojurebot0
06:51Cr8,(reduce (fn [a x] (throw "explode")) 0 [1])
06:51clojurebot#<ClassCastException java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Throwable>
06:51Cr8turns out you can't just throw a string, but it had the desired effect
06:54Cr8rurumate: sorry, looks like noone that uses it or works on it is around atm, but they have a mailing list https://groups.google.com/forum/?fromgroups#!forum/clojure-cassandra
06:54Cr8might try there
06:55rurumateCr8: alright, thanks
07:08seriously_randomCr8, http://pastebin.com/ajpLnDf5
07:09Cr8this looks over complicated
07:10Cr8but
07:10Cr8it does work :)
07:11seriously_randomCr8, I get it. start with first element, and (rest seq). conj 'x' + elem.
07:12Cr8yep
07:14Cr8https://www.refheap.com/22142 is mine if you want to take a look (if you don't, don't click!)
07:15seriously_randomtwo don'ts, must click
07:15Cr8ha
07:17ior3kCr8: just an FYI, conj can take more than one argument
07:17Cr8ah, convenient
07:18dsrx,(conj '() 1 2 3 4)
07:18clojurebot(4 3 2 1)
07:18dsrx,(apply conj ['() 1 2 3 4])
07:18clojurebot(4 3 2 1)
07:19Cr8edited
07:19dsrx,(#(apply (partial conj '())) [1 2 3 4])
07:19clojurebot#<ArityException clojure.lang.ArityException: Wrong number of args (1) passed to: sandbox/eval73/fn--74>
07:19dsrx,(#(apply (partial conj '()) %) [1 2 3 4])
07:19clojurebot(4 3 2 1)
07:20Cr8there's into if you want to conj the contents of a collection into something
07:20Cr8,(into #{1 4 3 8} [4 5 6])
07:20clojurebot#{1 3 4 5 6 ...}
07:21Cr8which will, if it can, use transients inside
07:21Cr8but otherwise is just (reduce conj thing coll)
07:23ior3kCr8: here's my very slightly different take https://www.refheap.com/22143. I enjoy seeing the different perspectives people bring to the table
07:24Cr8that's similar to the standard (lazy) interpose
07:24Cr8which drops the first element of (interleave)'ing it with an infinite sequence of the separator
07:25ior3kah, nice
07:25Cr8(defn interpose [sep coll] (drop 1 (interleave (repeat sep) coll)))
07:25Cr8is the stdlib interpose
07:27ior3knice, I didn't know about drop. Still finding my way around clojure
07:27Cr8(drop 3 coll) is just (rest (rest (rest coll)))
07:28Cr8drop is defined in terms of rest
07:28dsrximplementing interpose is simple once you know about interleave :)
07:28Cr8ior3k: if you're at a repl (and have made sure to (use 'clojure.repl), you can (source some-fn) to print its source
07:29Cr8depending on your editor, there may also be a hotkey to jump to the definition of the fn named under your cursor, which should work fine on the core library
07:30ior3kI'm still setting up clojure on emacs, but I was using tryclojure to test this
07:30ior3klots of new stuff. Head spinning
07:31cYmenIs there some sort of system behind what is a [:hr] and what is a (submit-button) in hiccup? I just accidenttally wrote [:form-to ...] worked but gave some strange results.
07:32Cr8cYmen: [:foo] should always spit out a <foo> tag, which means you probably got a <form-to> instead of a from, which is probably not what you wanted
07:32Cr8*a form
07:33Cr8(submit-button "foo") is just a helper that spits out [:input {:type "submit" :value "foo"}] for you (which would emit <input type="submit" value="foo"/>)
07:34Cr8https://github.com/weavejester/hiccup/blob/9d55fddf53ab32cc7761a32068dcb0364c99c714/src/hiccup/form.clj#L113-L116
07:34cYmenCr8: Thanks for the explanation!
07:35Cr8the general rule is [:foo] becomes <foo/>, [:foo {:bar "baz"}], become <foo bar="baz"/>, and [:foo [:bar]] becomes <foo><bar/></foo>
07:35Cr8the attribute map is optional
07:35Cr8but if given always has to be the second element
07:35Cr8otherwise any elements inside a thing just become subtags
07:37broquaintIs it possible to load deps in nrepl that were added since it has been launched? e.g nrepl-jack-in, add random.lib project.clj, lein deps, (use 'random.lib)
07:38broquaintI guess that would involve extending the classpath somehow but I'm not sure where to begin on that.
07:38Cr8broquaint: https://github.com/pallet/alembic does that sort of thing
07:38Cr8and packages it up all nicely
07:38broquaintMagic, thanks, Cr8!
07:39Cr8if you take the suggestion in the README and stick it in your lein profiles.clj it'll be in all your REPLs
07:39Cr8which is super hadny
07:39Cr8*hadny
07:39Cr8can't type
07:39clojurebotExcuse me?
07:41cYmenHm...when I hit the submit button on this thing I just get a blank "Not found" page. What does that mean?
07:42broquaintCr8: I shall take that suggestion :)
08:06cYmenHm..how do I find out what the latest version of org.xerial/sqlite-jdbc is? mvnrepository.com?
08:31augustlis there a function to safely (as in, don't execute code) read Clojure data from an InputStream?
08:35ddellacostaaugustl: what is "Clojure data?" EDN?
08:36augustlddellacosta: for now, a file with a clojure map in it
08:37ddellacostaaugustl: ah, so you just want to read it in? Try slurp
08:37ddellacostaaugustl: also checkout the clojure.java.io namespace
08:37augustlslurp just gives me a string
08:38ddellacostaaugustl: from there you can call read-string on it
08:39RaynesWell, don't do that.
08:39RaynesUse clojure.edn
08:39ddellacostaaugustl: listen to Raynes
08:39ddellacostaread-string is not safe, sorry, my bad...
08:39Raynesread-string would accomplish the same thing, but indeed, is not quite as safe/
08:39RaynesWhich probably doesn't matter for augustl's use-case, but is good to keep in mind!
08:40augustlread string fires missiles? :)
08:40augustlread-string*
08:40seriously_random(cond (one) (action1) (two) (action2) :else (do nothing) <-- else can't be written so that nothing will be done?
08:40Raynesaugustl: http://www.learningclojure.com/2013/02/clojures-reader-is-unsafe.html
08:41ddellacostaaugustl: http://clojuredocs.org/clojure_core/clojure.core/read
08:41Raynesseriously_random: Don't write :else
08:41Raynes:)
08:41RaynesNothing will be done if it does not exist.
08:41seriously_randomright, thanks
08:41ddellacostaRaynes: sick?
08:41RaynesSignificantly.
08:42Raynes:p
08:42ddellacostaRaynes: sorry to hear it. :-(
08:42ddellacostaRaynes: feel better!
08:42RaynesI'm the whiniest person you'll ever meet when I have a cold.
08:43ddellacostaRaynes: man, I know...I turn into a whiny baby and could possibly rival you
08:43Raynes:p
08:43ddellacostain any case, being sick is no fun. Hope you get well soon!
08:43RaynesTganks!
08:43RaynesThanks*
08:48seriously_randomWhy the function is accumulating nil suddenly: http://pastebin.com/0AAsqV6i
08:52hyPiRionseriously_random: what does this expression return? (cond (> 2 3) (assoc [2 7] 0 3) (< 7 3) (assoc [2 7] 1 3))
08:52seriously_randomhyPiRion, forgot :else acc. Never mind
08:52hyPiRion:)
09:32seriously_random"sequencify" int, e.g. 6 => (6)
09:33hyPiRion(doc list)
09:33clojurebot"([& items]); Creates a new list containing the items."
09:41dotemacsHi, I've been trying to do the following: take a string and turn it into a method that I call on an object instance. So spoke to some people and they pointed me at 'reflection'. Looked at it and I can see how to get all the method names of an instance, but I'm unsure on how to invoke a method, dynamically, using reflection. Sort of (doseq [n ["Title"
09:41dotemacs"Author"]] ((str ".get" n) someInstance)). Any tips ? Thanks
09:45BobSchackdotemacs you're trying to call a java object correct?
09:45dotemacsBobSchack: yes, thats correct
09:49BobSchackwells there's the clojure library for reflection (http://clojure.github.io/clojure/clojure.reflect-api.html) or you can use Java relection api.
09:51BobSchackYou could use reify to bring the java object into clojure
09:53dotemacsBobSchack: what I'm after is an example of how to do this: take a string and turn it into a method call. If you have an example of it or can share an example of it, I would be very grateful, thanks
09:57BobSchackdotemacs I haven't used the reflection utilities I just know of them, sorry. You can try the mailing list.
09:57dotemacsBobSchack: np, thanks :)
09:58BobSchackwhat are you trying to do that you need to turn a string into a java method?
09:58dotemacsBobSchack: theres an instance that has many 'getX' methods
09:59dotemacsBobSchack: so instead of calling each one of the individually, I'd like to have a way to pass in a vector with all the desired method names and call them on an instance
10:00dotemacsBobSchack: instead of doing: .getTitle, .getAuthor, .get...
10:00BobSchackso you're trying to use the lookup interface on the object instead of doing .getX
10:00dotemacsi'd like to pass in ["author", "title"...] to a function that will construct methods and call them based on the vector contents
10:01ddellacostadotemacs: I assume you already have a class in existence?
10:01esanchowould java.beans.Introspector help?
10:01dotemacsddellacosta: yes
10:02dotemacsesancho: let me have a look
10:02ddellacostadotemacs: sorry, you're trying to declare methods or figure out what methods already exist so you can call them?
10:03dotemacsddellacosta: i just want to call them, i know which methods already exist
10:03hyPiRionddellacosta: he's trying to convert "foo" to e.g. #(.getFoo %)
10:03BobSchackwould the bean function work for this? (http://clojure.org/java_interop#Java Interop-The Dot special form-(bean obj))
10:03ddellacostadotemacs: you could do it pretty trivially with a macro I expect
10:04ddellacostadotemacs: `(~(str ".get" method-name) ...) kinda thing, obviously that's pretty rough...
10:05ddellacostaassuming you can use macros with Java interop, which I don't actually know for sure...
10:05dotemacsddellacosta: true and i have something like that going, but i've already asked about this and was advised that using reflection would be better way to approach it. So what i'm asking is: what is that way of using reflection ?
10:05hyPiRion,(import 'clojure.lang.Reflector)
10:05clojurebotclojure.lang.Reflector
10:05ddellacostadotemacs: ah, gotcha, sorry--
10:05hyPiRion(Reflector/invokeInstanceMethod "hello" "substring" (into-array [0 2]))
10:05hyPiRiongah
10:05hyPiRion,(Reflector/invokeInstanceMethod "hello" "substring" (into-array [0 2]))
10:05clojurebot"he"
10:06dotemacscool, thank you all :)
10:06ddellacostahyPiRion: very cool...didn't know about that!
10:15RayneshyPiRion: `(~(str ".get" method-name) ...) <-- you'd need to symbolize the string.
10:18hyPiRionRaynes: were you talking to ddellacosta maybe?
10:19RayneshyPiRion: Aye, your nicks are both colored the same.
10:19ddellacostaRaynes: yeah, I realized that afterwards, it was pretty loose...
10:20ddellacostaresolve too I guess...
10:20ddellacostaand eval too I gues
10:30dotemacsRaynes: you would need to smybolise the string if it was a symbol, but this is method which is to be invoked on a instance...
10:31Raynes&`(~(str ".get" "FooBar") ...)
10:31lazybot⇒ (".getFooBar" ...)
10:31Raynesdotemacs: ^ You can't call strings
10:32hyPiRion,(-> '(.isEmpty """) first class)
10:32clojurebot#<RuntimeException java.lang.RuntimeException: EOF while reading string>
10:32hyPiRion,(-> '(.isEmpty "") first class)
10:32clojurebotclojure.lang.Symbol
11:51shep-homeIf I do a `send` inside an agent, Clojure will wait until after the agent is changed to act on that send. Is there anything similar for channels with core.async?
11:52shep-homeAsking in a different form, if I put something into a channel, is that tend to be more "pure" or more "side effect"?
11:58pcnHi everyone!
12:02pcnI've got a test service that will read lines from a socket, and write them to channels.
12:02pcnIf I pass a small but significant number of messages, somewhere between 1 and 10000, it seems like the jvm goes crazy doing work.
12:03pcnThe socket is handled by a slightly changed version of server-socket
12:04pcnI suspect that the listening function is spending a lot of time looping and nooping, but I don't understand why.
12:04pcnAt https://github.com/pcn/carbon-relaj/blob/master/src/carbon_relaj/core.clj#L160 I had to put the check for nil? or else that loop would feed massive quantities of garbage to the channel.
12:04pcnBy garbage I mean nil
12:12winkanyone from the US here? Is Dec 24th in any way special regarding postal shipping, opening hours? From my restricted knowledge you only remotely call that christmas, right? :)
12:14dubsgwink: Yeah typically stores are open for shopping limited hours on the 24th (closing a bit early often)
12:15dubsg... and yes, USPS mail is delivered on the 24th ;)
12:15winkdubsg: ok, thanks. because here in Germany (as you may or may not know) the actual celebrations are on the eve od 24th, so most stuff shuts down at noon, or doesn't even open (not shops. but anything public)
12:30devnHello all
12:32BobSchackhey devn
12:48stompyjis (:require [blah] :refer :all) generally preferred over (:use blah) these days?
12:48Bronsayes
12:48hyPiRionyes, although it is (:require [blah :refer :all])
12:49stompyjBronsa: hyPiRion : thanks!
12:51whilois it possible to have a different version of the closure library in a cljs project? i am using ol3, which seems to use closure trunk (non-released :-/)
12:52whilofor reference https://github.com/openlayers/ol3
13:14TimMctechnomancy: OK, I think I might be coming around to your point of view on if/when.
13:15hyPiRion(inc TimMc)
13:15lazybot⇒ 54
13:15hyPiRionwe got cookies for you
13:15TimMctechnomancy: However, my answer is still to never use one-armed if, and use an explicit nil branch.
13:16zerokarmaleftTimMc: curious, is there a conversation in the logs about that?
13:16TimMcOh my god yeah.
13:16TimMcSearch for kibit and one-armed if.
13:17hyPiRionIt's one of the more frequently discussed bikesheds here
13:17hyPiRionregardless of kibit, even
13:18zerokarmalefthyPiRion: I'm a bit of a channel troll, so I miss a bunch >.>
13:18hyPiRionTimMc: is (and pred expr) the same as (if pref expr) =
13:18hyPiRion*?
13:18clojurebot* is just for when you are lazy and sloppy
13:19TimMcI'm just going to do it on this one project and see how it feels.
13:47pcnTimMc it'll feel dirty, and you'll stop doing it and hope no-one you know sees you doing it.
14:05gfredericks,(let [>.> :-D] >.>)
14:05clojurebot#<CompilerException java.lang.ClassFormatError: Illegal field name "_GT_._GT_" in class sandbox$eval25, compiling:(NO_SOURCE_PATH:0:0)>
14:05gfredericks,(let [o_O :-D] o_O)
14:05clojurebot:-D
14:14mockerTrying to follow this http://j.mp/1gSqXzZ guide and think I'm running into a problem with it not being compatible with newer clojure. Mainly getting errors about clojure.contrib.java-utils and as-properties
14:17mockerAnyone know if there is something to replace as-properties?
14:19rurumateemacs here, why is [C Right] not working over ssh?
14:21gfredericksmocker: what does it do?
14:23mockergfredericks: Complains about missing java_utils, and if I comment that out complains about not being able to resolve symbol as-properties
14:25gfredericksmocker: oh I see
14:25akhudekmocker: there is http://dev.clojure.org/display/community/Where+Did+Clojure.Contrib+Go, but it doesn't list the properties library sadly
14:26gfredericksmocker: so I don't know that there's a replacement for the java-utils contrib namespace; you can either try to get it working with an old contrib, or try to reproduce the functionality yourself
14:26mockerOk, so I'll probably have to figure out how to rework what he was doing there.
14:26gfredericksmight well be that pasting the code from java-utils would just work
14:26gfredericksmocker: undoubtedly he was depending on the clojure-contrib jar which you probably don't have yet
14:26mockerBut at least I'm on the right track, that stuff isn't around anymore. :)
14:27akhudekoh wow, today I learned that 'concat' can generate stack overflows
14:27gfredericksakhudek: totes
14:27gfredericksthat's one of the top three subtle dangers of lazy seqs
14:28hiredman /win 15
14:28gfredericksclojurebot: win is 15
14:28clojurebotAlles klar
14:29gfredericksakhudek: I think 95% of the time that concat is overflowing your stack it can be drop-in-replaced by into
14:29akhudekgfredericks: yep, I just did exactly that
14:30gfrederickswhich can potentially result in ordering differences related to seqs vs vectors
14:39hyPiRion(defn concatv [& colls] (reduce into [] colls))
14:40gfredericks(def concatv (comp (partial reduce into []) list))
14:41gfredericksTimMc: I just realized that I think ->/->> could have been rewritten to be recursive from the other end and that would've solved the problems
14:45gfredericksexcept the one problem of macroexpand-1 not being instructive
14:47hyPiRionIs it possible to force an inner macro expansion before an outer one acts? E.g. expand ->> before -> in `(-> 10 (->> a b c))`
14:47gfredericksforce who to do it?
14:47gfredericksand from where?
14:47clojurebotI don't understand.
14:48gfredericksclojurebot: that's okay
14:48clojurebotTitim gan éirí ort.
14:48hyPiRionthe reader, I guess. From a repl or when loading code
14:48gfrederickswhat? maybe a use case would help
14:48rurumate,((fn [x] (mod x (nth (iterate #(* 2 %) 1) 16))) 18761459871)
14:48clojurebot10399
14:49BronsahyPiRion: why not simply calling macroexpand-1 on & body from the macro?
14:50hyPiRiongfredericks: I want `(->> (+ a b) (-> [a b] fn*))` to turn into `(fn* [a b] (+ a b))`
14:50octeif you have a group of functions operating on for example a connection, is the with-connection from contrib.sql idiomatic clojure?
14:51whomphow do i iterate over a rectangle in a 2D vector?
14:51gfrederickshyPiRion: that makes you a weirdo, right?
14:51whompor rather, how can i write a function that returns this rectangle?
14:52hyPiRionBronsa: I don't want to redefine -> and ->> :p
14:53gfrederickswhomp: you want some subsection of it? and is this a nested clojure vector in particular?
14:54BronsahyPiRion: definitely not possibile to do in the reader btw
14:54whompgfredericks: yeah, i'm writing a program that verifies that a sudoku solution is valid. so it takes a 9x9 2D vector, and i want to process 3x3 grids in it
14:55hyPiRiongfredericks: that makes me able to get closures in Swearjure
14:55gfrederickswhomp: you could use subvec twice
14:55BronsahyPiRion: assuming we are talking hypothetically, tools.analyzer's macroexpand-1 is a dynamic var -- just rebind it to a macroexpander that expands the macro args before the macro && emit-form to get the macroexpanded form :P
14:55gfrederickshyPiRion: oh I see this is serious then
14:56hyPiRionBronsa: Well, that sounds like something which won't break existing code :p I guess if I do it after all other code is loaded
14:58gfrederickshyPiRion: did you see the description of the swearjure talk?
14:58gfredericksI'm curious who wrote it
14:58gfredericks"Gary Fredericks shows some tricks for getting the most out of Clojure obfuscated code."
15:00hyPiRiongfredericks: not sure who wrote it, but yeah, I noticed
15:00hyPiRionIt should've said "shows that elegant programs doesn't need alphanums"
15:00gfredericksit's not as ridiculous as I thought it was
15:01whompgfredericks: something like this? (flatten (map #(subvec % (* x 3) (+ (* x 3) 3)) (subvec square (* y 3) (+ (* y 3) 3)) )
15:02gfrederickswhomp: yep
15:02gfredericksflatten could be (apply concat ...)
15:02rhg135hello ppl, so close but no dice, https://www.refheap.com/22138 seems to close the client socket after the first reply now
15:02rhg135but i can't see why
15:03whompas someone new to the language, that makes me sad when i can write arr[(y*3)...(y*3+3)].map{|row| row[(x*3)...(x*3+3)]}
15:03whompin ruby
15:03rhg135unless spit is closing the stream or similar
15:03rhg135but that's not in the docs afaict
15:04hyPiRionrhg135: that's in the docs, I think
15:04hyPiRion(doc spit)
15:04clojurebot"([f content & options]); Opposite of slurp. Opens f with writer, writes content, then closes f. Options passed to clojure.java.io/writer."
15:04rhg135ah
15:04rhg135but i don't open my writer in spit
15:05rhg135but it still closes it?
15:05hyPiRionyeah, with-open makes that happen
15:05TEttingerhyPiRion, were you here for my elegant "returns true" in swearjure? ##(#(% '☃) #(= % '☃))
15:05lazybot⇒ true
15:05rhg135so is there a way to prevent that?
15:06gfrederickswhomp: those two versions seem to have a pretty similar complexity level to me...is there some part in particular that bothers you?
15:07TEttinger,(#(% :☃) #(= % :☃)) ; symbols work too, neat
15:07clojurebottrue
15:07hyPiRionrhg135: Well, I would guess you could try to replace spit with .write, no?
15:07whompwell the operators are annoying, but you're right i suppose
15:07whompthanks for the help
15:07rhg135idk i think writer works on ints
15:07rhg135.write*
15:08rhg135or chars not sure
15:08hyPiRionwell, wrap it in a string.
15:08rhg135but i thought spit might work
15:08hyPiRion,(.write *out* (str 42))
15:08clojurebot42
15:08rhg135hmm
15:09hyPiRion,(.write *out* 42)
15:09clojurebot*
15:09hyPiRion,(.write *out* \*)
15:09clojurebot#<IllegalArgumentException java.lang.IllegalArgumentException: No matching method found: write for class java.io.StringWriter>
15:09rhg135didn't know write worked on strings
15:10pyrtsa,(.write *out* (int \*))
15:10clojurebot*
15:10rhg135ic
15:10hyPiRionrhg135: well, yeah, be a bit careful. That probably only works on writers, not streams.
15:10rhg135i'm going to try that
15:10rhg135it's a writer
15:10TEttinger,(.write *out* (int \☃))
15:10clojurebot?
15:10hyPiRionah, then I guess you're very good
15:11TEttinger##(.write *out* (int \☃))
15:11lazybot⇒ ☃nil
15:11rhg135clojure.java.io/writer returns a writere no?
15:11justin_smitha stringwriter is not a string though - it is a subclass of java.io.Writer
15:11TEttingerwow it handles unicode even
15:11hyPiRionrhg135: yeah, that returns a writer
15:11rhg135ok
15:11rhg135TEttinger, java is utf16
15:11rhg135i think
15:12TEttingeryeah, but I didn't know if file IO was
15:12justin_smithI think you can set the encoding of a file or even a string
15:12TEttingeror if it was coercing the (int \*) to a byte
15:12rhg135ya
15:12justin_smithbut utf16 is the internal representation
15:12rhg135:encoding is an option to writer
15:12hyPiRionTEttinger: writers and readers have encodings attached
15:25rhg135slightly better
15:25rhg135now i get an infinite loop after the first replies :\
15:26rhg135by that i mean it keeps sending the same reply
15:26justin_smithrhg135: sounds like a tracing lib would help you
15:26rhg135hmm
15:26rhg135i'll go set it up
15:27justin_smithhttps://github.com/clojure/tools.trace if you get a good log of what a function is receiving as args and what it is returning, that makes debugging much easier
15:27justin_smithie. you can make a unit test by passing an arg that is representative of the real calls, and verify it outputs something reasonable (which if it is looping it clearly is not)
15:28rhg135sounds simple
15:28justin_smithwell, it can be if you make the core of your logic purely functional
15:28justin_smithor as close to it as you can get away with
15:29justin_smithit is my defacto standard for debuggable designs
15:29rhg135mine too
15:29rhg135my core is semi-functional
15:29rhg135just that darn login!
15:30SegFaultAXIO at the edges is the ideal.
15:30rhg135i do most io in -main
15:30justin_smithrhg135: another option is to make an atom of a vector, and conj the args / return value on in each run
15:30justin_smiththen use the repl to play with the data in the atom
15:30rhg135hmm
15:31rhg135i think tools.trace sounds better
15:31justin_smithyeah, it depends, sometimes being able to experiment in a repl is a real bonux
15:31justin_smithbut trace is more clean
15:31justin_smithI have tools.trace in my dev profile so I can always trace things in the repl
15:32justin_smiththat and criterium for optimizing stuff interactively
15:32SegFaultAXjustin_smith: You know what would be kinda neat?
15:32justin_smithSegFaultAX: what's that?
15:33SegFaultAXjustin_smith: Conjing maps into that vector, where each map has 3 keys :args, :result, and :replay where replay is a nullary closure that will re-run that invocation.
15:33justin_smithoh, that sounds nice
15:33justin_smithnot hard to do at all
15:33SegFaultAXNope
15:33justin_smithalso include a key for the function itself while you are at it :)
15:33justin_smithand for the string / name
15:34justin_smithto make filtering easy if you are tracing a shitload of stuff :)
15:34justin_smithand then maybe some functions to prune / trim the atom when it starts getting huge
15:34rhg135sounds like a good idea
15:34justin_smithyeah
15:34justin_smithit does
15:34SegFaultAXcore.cache can help you there.
15:34justin_smithand with functional programming all that stuff is pretty straightforward
15:34justin_smithSegFaultAX: yeah, exactly what I was thinking!
15:35justin_smiththe gotchas would be things like input streams / output streams
15:35justin_smiththat are inherently stateful (they are empty / unwritable when the other end closes)
15:36justin_smithI dealt with this in my groundhog ring debugging lib by cloning the input stream (which works when input stream is a finite thing, not an indefinite interactive connection)
15:39rhg135how do you use trace?
15:40rhg135trace itself doesn't trace m ydispatch function
15:40justin_smithhttps://github.com/clojure/tools.trace has a few examples
15:40justin_smithyou can trace the whole ns
15:40rhg135o yeah
15:41justin_smithjust calling trace/trace traces one invocation
15:42rhg135now this is a dafuq moment
15:43rhg135trace-ns show all calls but those after the client connects
15:43justin_smithweird!
15:43justin_smithmaybe because of threading the output is going somewhere different
15:43justin_smithare you doing this within emacs?
15:44rhg135no
15:44rhg135within vim
15:44rhg135but im at the repl
15:45justin_smithOK, I meant is the repl inside your editor, because if so some output from threads doesn't go into the repl window
15:45justin_smithbecause *out* is a dynamic var
15:45rhg135also it suddenly stopped sending any response
15:45justin_smithoh weird
15:45rhg135i hate threading
15:45justin_smithsounds like the "putting things in an atom" method may help you
15:46justin_smithatoms are meant to help with data across threads after all
15:46rhg135yes, but it's a java socket
15:46rhg135already mutable
15:47rhg135tbh i'm not too sure about java multi-threaded
15:48justin_smithtry this: (def debug (atom [])) ... (defn some-fn [a b c] (let [... result (...)] ... (swap! debug conj {:time (java.util.Date.) :args [a b c] :result result} result)))
15:48hiredmanI am in the market for some kind of server management / deployment thing, specifically I want to write a program that will spin on ec2 nodes, run some benchmarks, collect results, and shut it all down, I really like pallets model, but hate the dependency hell of pallet, and the fact that the crates are hit or miss about working with a current version of pallet
15:48hiredmansomeone sell me on something else please
15:49justin_smithrhg135: the idea being that some-fn already exists, and we are adding in that swap! statement, of course
15:49rhg135ya
15:49justin_smiththen from the repl you can inspect debug
15:49rhg135ok
15:50rhg135i have a feeling this is a threading issue
15:50justin_smithof course
15:50justin_smithbut this way you can see where the issue is
15:50justin_smithwhat is making it happen
15:50rhg135ok
15:50rhg135imma add it in
15:50justin_smithand clojure has very nice facilities for using threading sanely
15:51rhg135ya...
15:51rhg135wish clojure socket's existed
15:53rhg135erm
15:54rhg135my dispatch function, which i think is the problem, takes a lazy sequence
15:54justin_smithwell, then don't log the whole lazy seq, just the part it uses?
15:54justin_smiths/log/store as appropriate
15:55rhg135the seq is a sequence of the maps the client sends so
15:55rhg135i doubt it's that long
15:56justin_smithOK
15:58rhg135DAFUQ?!?
15:58rhg135debug is empty while it's looping
15:59rhg135so i guess that function never returns
16:00pcnrhg135: doall to the rescue?
16:02rhg135idk
16:02rhg135it should be evaluated by the doseq
16:04pcnCould be. Try doall and see if the behaviour changes. Whatever you're doing could be lazier than you realize.
16:07justin_smithrhg135: so we've learned something - there is a stall before the function exits
16:07justin_smithrhg135: now you can try tracing at function entry, and then use a binary search to see which line hangs
16:15rhg135ah
16:15rhg135k
16:16justin_smiththat is, assuming the function is entered!
16:16justin_smithbut tracing and/or debug atom conjing should help with that too
16:18dotemacsHello, a question regarding testing. Would you test functions that are private, as in defined as 'defn-' ? Sort of like the way you wouldn't test private methods in object oriented langs? Thanks
16:18justin_smithoften I think privacy itself is an OO thing
16:19justin_smithbut this is a style argument of course
16:19justin_smithI test things if I want to be sure that a change in my code will not break them
16:19justin_smithor if I want to narrow down how they are breaking by asserting what they should be asserting
16:20justin_smithbut I am pretty pragmatic about testing and do not use it in a rigorous way
16:20justin_smithymmv
16:20dotemacsjustin_smith: right, thanks for that
16:21magnarsI want a pluggable backend, so I'm passing in a map of partially applied functions. But this creates some odd-looking code: ((:get-account storage) account-id) ... the double starting parens triggers my spider sense. Any thoughts?
16:22justin_smithmagnars: this is what protocols and multimethods are for
16:22justin_smithbut double parens are perfectly cromulent, they just mean you are calling a function to get another one back
16:22justin_smithwhich means functional programming in action, right?
16:23justin_smithmagnars: protocols in particular are exactly designed for the situation where a backend is pluggable but should define some functions you can look up
16:24magnarsI'll look into those. Never had a reason to before, so sounds like a good excuse to learn a little. Thanks :)
16:25justin_smithone tricky thing is that defmethod / defprotocol do annoying things in long lived repls
16:25magnarsyeah, I've got bitten by that one a few times with multimethods :P
16:25justin_smithuntil you get their design perfected, you will find yourself having to restart in order to get sane behavior
16:25justin_smithbut imho protocols are worth it
16:25justin_smithI dunno about multimethods though
16:27anagriusIs ritz-nrepl my best bet for debugging? It doesn't seem to work with Cider, would I have to downgrade to a compatible cider/nrepl.el version?
16:27magnarsjustin_smith: Sounds like a good excuse to grab a book of dead trees and step away from the computer to read up. Thanks.
16:27justin_smithanagrius: the design of ritz baffled me when I tried to look at the code, and I never found a good workflow for using it. some people have found it useful though.
16:28justin_smithmagnars: np
16:28anagriusWe just have a huge legacy program that is hard to reason about. A stepping debugger could really help us out.
16:29scottjanagrius: yes, yes, and even then it might not work for you.
16:29anagriusscottj: how so?
16:29justin_smithanagrius: from what I could figure out, ritz got weird and complicated because jvm debugging is best done via a second jvm that connects to the dt-socket and takes control, and ritz tries to act like common lisp where you stop and debug in the same image, which is weird and broken in clojure because threads
16:30justin_smithstepping debugging gets a little weird when you have concurrency
16:30justin_smithdo you step parallel threads? How do you account for them? etc.
16:30scottjanagrius: even with a compatible nrepl.el there have been reports of it not working
16:31anagriusscottj: shame..
16:32justin_smithCDT can set breakpoints and allows you to investigate things at a breakpoint then resume
16:32anagriusI have found watches in LightTable really useful, but unfortunately nothing like it in emacs.
16:32justin_smithyou can construct stepping or something like it out of this
16:32justin_smithCDT is much simpler than ritz
16:32anagriusjustin_smith: I would have to check that out, thanks
16:33justin_smithalso there is schmetterling which I helped design, which sues cdt and gives a webapp based UI
16:33justin_smithfor looking at stacktraces / locals when your app stops
16:34justin_smiththe usage is that you set your jvm opts for the debugging socket to be open, then you can run schmetterling as a seperate app, tell it to connect to your socket, and then schmetterling pops up a stack in your browser when an exception is thrown in the target vm
16:34justin_smithit kind of works
16:34justin_smithbut is not a normal debugger at all
16:35justin_smiththere is also tools.trace for figuring out how / when your code is called without stepping
16:35justin_smithI often miss stepping myself, but I don't think anyone has a simple workflow for that in jcm clojure yet
16:37justin_smith*jvm clojure
16:38rhg135???????????????????????
16:39rhg135it's saying the lazy-seq has one map, but doseq is running infinitely
16:39anagriusjustin_smith: I have tried schmetterling, but it kept getting ClassNotFound errors. So I ended up giving up
16:40rhg135and it's not able to print debug in the repl
16:40rhg135idk what it's blocking on tho
16:40justin_smithanagrius: yeah, that has to do with the classes for using the jdi, I have seen it too :(
16:41justin_smithrhg135: have you tried looking at the caller and seeing if it is stalling on something before even entering the function you are looking at?
16:41justin_smithrhg135: by any chance are you using a for or map on a lazy seq?
16:42rhg135well the inside of the function is conj'ing so i think it's called
16:42rhg135the loop too
16:42rhg135no, doseq
16:42justin_smithOK
16:42rhg135i learned that long ago lol
16:43justin_smithwell then the print issue probably has to do with *out* being a dynamic binding
16:43justin_smithso who knows where the print output is going
16:43justin_smithyou could use a proper logging lib
16:43rhg135i mean it's doseq'ing over a lazy-seq which is one item long
16:43rhg135but it runs indefinetely
16:44justin_smithhave you tried establishing the smallest / simplest subset of your code that demonstrates the behavior?
16:44rhg135no
16:45rhg135but i have narrowed it down to the looop inside main
16:45rhg135which is 90% of the code :\
16:46rhg135mainly the dispatch form and it's args
16:49justin_smithwell you could break it into smaller functional pieces, and verify each behaves as you expect
16:50rhg135i don't see how to split it more though
16:50rhg135it seems fairly small
16:51anagriusjustin_smith: So.. would you use cdt through swank-clojure or?
16:53justin_smithno, cdt does not need swank
16:53justin_smithyou run it through a second repl
16:53justin_smithand it connects to the dt-thread
16:53anagriusmkay
16:53justin_smithbut you will likely see the same error, because it needs the same jdi socket
16:53justin_smiths/a second repl/a second jvm
16:58rhg135i'm basically trying to write an abstraction over the JIM protocol similar to ring
16:58rhg135as in handlers are functions taking a map returning a map
17:00TimMchyPiRion: I think `and` and one-armed `if` have different false return values (false and nil).
17:01hyPiRion,[(and false (+ :two)) (if false (+ :three))]
17:02clojurebot[false nil]
17:02hyPiRionTimMc: you are correct, sir
17:03gfredericksis haskell's if mandatorily-two-armed?
17:04technomancyocaml's is not
17:04gfredericksdoes ocaml have a null?
17:04gfrederickswhat does an OAI return when false?
17:05technomancyI think one-armed if probably requires both branches to return unit
17:05technomancyif is really rare in languages with p.roper pattern matching
17:07hyPiRionI'm not sure what proper pattern matching even is these days
17:07gfredericksP. Roper was a computer scientist who spent her entire career studying esoteric forms of pattern matching
17:07bitemyappyou don't really need "if" in Haskell.
17:08gfrederickscase foo of True -> ...
17:08RaynesBecause guards and pattern matching.
17:08bitemyapppattern matching and guards are generally sufficient, and even then, you can work at a higher level than that.
17:08Raynesbitemyapp: h5
17:08Rayneshi5*
17:08technomancythere's only one if in grenchman that isn't used for side-effects, heh
17:08bitemyappbut 4rlz. unnecessary.
17:09gfredericksbitemyapp: does it require two arms?
17:09bitemyappone nice thing about the non-strictness of Haskell is that you can implement your own short-circuiting boolean functions without macros or compiler support.
17:09technomancygfredericks: anyway you don't need when/if to tell you when you have a side-effect in ML. you have unit for that.
17:09technomancythe compiler will yell at you
17:10dnolenbitemyapp: you can do that in Smalltalk too, in both cases catastrophically slow so it doesn't matter much
17:10dnolenexcept for cool points
17:10technomancyand only five ifs total
17:10bitemyappdnolen: the point isn't that you'd write your own "if", it's that the language is capable of expressing a wider scope of things than strict languages without resorting to macros.
17:10Raynestechnomancy: How dare you break lein new.
17:10technomancythe fact that the count is so high is probably indicative of my n00bness
17:11RaynesDon't know who you think you are, partner...
17:11technomancyRaynes: oh, I dare.
17:11technomancyI dare so hard.
17:11bitemyappgfredericks: it's strictly if-then-else.
17:11gfredericksphew
17:11bitemyappgfredericks: what would a one-arm boolean expression even mean in Haskell?
17:11bitemyappserious question.
17:12dnolenbitemyapp: yes laziness delivers some kinds of flexibility w/ respect to control, but it's also doesn't give you enough control sometimes, see Oleg's Strange Loop Talk
17:12dnolenas usual "tradeoffs"
17:12hyPiRionOne thing I don't like with the OCaml pattern matching is that you cannot match on locals
17:12bitemyappyou can't return two different types from a function in Haskell, it'll tell you to get fucked if you try.
17:12gfredericksbitemyapp: well it could mean Maybe Foo
17:12bitemyappunless you wrap it in either or an algebraic data type.
17:12gfredericksI wouldn't have expected that though
17:12technomancyhyPiRion: eh?
17:12bitemyappgfredericks: that's not even two types.
17:12bitemyappgfredericks: two types would be Either or ADT. Maybe is "maybe" 1 type or nothing.
17:12hyPiRiontechnomancy: `match a with (b, c) ...` where b and c are variables/locals
17:12technomancyfunction?
17:12clojurebotfunction is <Chouser> there is one class per fn, one instance of it per closure
17:13bitemyappNothing ain't a thing.
17:13gfredericksbitemyapp: ...why do you need two types?
17:13technomancyoh, in the pattern itself, not the match expression
17:13technomancyfunny; I never tried that
17:13bitemyappgfredericks: I was making the point what if you want a function that returns two different types you have to express that properly as Left and Right of an Either or something.
17:13hyPiRionNot had a need for it yet, but you can do that in Erlang and core.match afaik
17:14gfredericksbitemyapp: okay so this is unrelated to the one-armed-if?
17:14bitemyappone-armed implies some unit type getting returned or something. Nutty.
17:14bitemyappgfredericks: no. ^^
17:14gfredericksbitemyapp: why not return Nothing when false?
17:14bitemyappand you can return unit in Haskell, but that's not Nothing.
17:14bitemyappand if you return Unit, you can only return unit.
17:14technomancybitemyapp: I could see it inferring None when the other branch returns Some of something
17:15technomancybut it's not ac ommon enough idiom to be magic about
17:15bitemyappyou can return Nothing or Just myThing but that's Maybe MyType not unit.
17:15gfredericksbitemyapp: I never said anything about unit
17:15bitemyappgfredericks: I was talking about what a one-armed boolean would mean in Haskell.
17:15bitemyappgfredericks: and why it doesn't make a ton of sense.
17:15gfredericksbitemyapp: I give up trying to explain myself
17:15zerokarmalefthow does lein resolve transitive version dependency conflicts?
17:15rhg135sounds like one of this 'fuck you' type things about the type checker
17:16bitemyappgfredericks: how did one-arm / two-arm boolean expressions come up anyway?
17:16bitemyapprhg135: no, you can express anything you'd want, you just have to explicit about the non-determinism of the values.
17:16rhg135ik, b
17:16rhg135erm bytem
17:16rhg135damn
17:16rhg135nvm
17:16bitemyapprhg135: namely, if you need to handle a return value that might be a string or an int, you make an ADT or wrap in Either.
17:17xeqizerokarmaleft: assuming soft version ranges, by choosing the version that is first in a breadth first search
17:17gfredericksbitemyapp: TimMc I think was considering a conversion to the technomancy camp of the if/when divide in clojure
17:17rhg135i used to use haskell, i know
17:17rhg135ya...
17:17rhg135life isn't deterministic
17:17bitemyappgfredericks: I'm pretty sure I'm in his camp.
17:17gfredericksCamp Technomancy
17:18gfrederickswhat other things does he believe in? repeatability? the scilardi scenario?
17:18gfrederickswe're bullish on scilardi
17:18technomancygfredericks: aka the Hagelberg Catechism
17:19gfrederickstechnomancy: I need somebody to invent a Hagelberg Bagel
17:19xeqiI hear he likes coffee
17:19rhg135i do miss haskell's type system at times
17:19hyPiRionWe are the Hagelborg
17:19technomancygfredericks: that one's over my head I'm afraid
17:19rhg135makes debugging a lot easier
17:19xeqiaeropress for everyone
17:20bitemyapprhg135: I was working on some Haskell last night, had one problem the type system didn't catch. That was it.
17:20bitemyappwith somebody else*
17:20rhg135unlucky
17:20gfredericksokay at each meeting for communion we will have hipster coffee and hagelberg bagels
17:20bitemyappI haven't had a bagel since new york.
17:20bitemyappthis sounds awesome.
17:20technomancybitemyapp: that's not really a claim with any meaningful interpretation
17:20rhg135bitemyapp, i had none in 4 months
17:20bitemyappdnolen: do you eat bagels?
17:20technomancy*possible meaningful interpretation
17:20gfrederickstechnomancy: oh you didn't hear about new york?
17:21technomancygfredericks: I guess not?
17:21bitemyapptechnomancy: it was particularly cute because the one error was the mythical "logic error" that people that reject type systems speak of.
17:21gfrederickstechnomancy: well, three months ago when nobody was expecting anything unusual, new york.
17:21bitemyappa variable was being processed in the wrong part of the recursion.
17:21technomancymy son's name is Noah, and there is a place called Noah's Bagels in New York
17:21Raynesgfredericks: Well, it wouldn't be type safe.
17:21technomancythat's all I got
17:21hyPiRionxeqi, technomancy: Fun fact, I bought an aeropress for my dad for Christmas. Not sure if I'm being Hagelberg assimilated or if that happened randomly
17:22technomancygfredericks: good heavens
17:22gfredericksI bought a skerton grinder recently and I think it is defective
17:22Raynesgfredericks: Actually, sorry, re-read your messages.
17:22TEttingerhyperboreean woo
17:22technomancyno one told me
17:22bitemyappaeropress is a secret gov't program to make everybody have a stronger upper body
17:22RaynesThat actually does make a bit of sense.
17:22bitemyappthey're preparing us for the zombie apocalypse with caffeine and strength training.
17:23TEttingerhaha it does not require much strength unless you are using way more grounds than needed
17:23rhg135bitemyapp, makes a lot of sense
17:23gfredericksbitemyapp: I don't know that I've ever heard anybody suggest a secret govt program that was not sinister
17:23bitemyappTEttinger: I make *strong* coffee.
17:23TEttingerand if you want strong coffee just run coffee through more grounds
17:23TEttingerinstead of water
17:23bitemyappgfredericks: how is it sinister? They're helping us.
17:23gfredericksbitemyapp: it's not, that's my point
17:23bitemyapptechnomancy: when you were in the Yay, where did you get coffee?
17:23bitemyappgfredericks: I mean, look at flouride. Totally non-sinister.
17:24TEttingeryou can run aeropress coffee through like 4 times or more, I've heard, before it gets really hard to do because you are pressing mud through the filter
17:24sprocket_new clojure user here and wondering if someone might give me a hand :)
17:24technomancybitemyapp: do people call it that? the keys aren't even next to each other
17:24bitemyapptechnomancy: :3
17:24TEttingersprocket_, shoot
17:24sprocket_i'm trying to write a function to load a config file, and if it's already been loaded to return the existing config
17:24technomancybitemyapp: but I was mostly sticking to Sightglass and four barrel
17:24sprocket_(defn load-config []
17:24sprocket_ (if (resolve 'config)
17:24sprocket_ config
17:24zerokarmaleftxeqi: concretely, I have ring-core depending explicitly on clj-time 0.4.4, and blackwater explicitly depending on clj-time 0.6. deps :tree shows lein pulling in clj-time 0.4.4
17:24sprocket_ (def config {:x "foo" :y "bar" :z "qux"})))
17:24bitemyapptechnomancy: I'm planning my pre-gym coffee-up.
17:24technomancyif I was hungry enough to brave the lines for a waffle, blue bottle
17:24sprocket_but it's giving my unbound errors when it runs
17:25sprocket_ie) #<Unbound Unbound: #'clojure.core/config>
17:25rhg135sprocket_, refheap
17:25bitemyappsprocket_: don't paste code in the channel homie.
17:25sprocket_sorry
17:25technomancybut last time I was there the line was around the corner even at like 800
17:25gfrederickssprocket_: using def conditionally like that is not idiomatic; an alternative could use delay
17:26TEttinger,(resolve 'wheeee)
17:26gfrederickse.g., (let [c (delay (load the config))] (defn config [] @c))
17:26clojurebotnil
17:26TEttinger,(resolve 'map)
17:26clojurebot#'clojure.core/map
17:26bitemyappwhy is the new Google maps so slow on my computer? :(
17:26technomancybitemyapp: Ritual has good beans from what I've made for myself in the office, but I haven't been ther myself
17:26bitemyapptechnomancy: I tink that's the beans we have at my office.
17:26hyPiRiongfredericks, sprocket_: could also use a promise and deliver it
17:26bitemyappmaybe I should just go into my office to make coffee.
17:27xeqizerokarmaleft: is ring-core listed in your deps before blackwater? the resolution uses the first version it finds
17:27technomancybitemyapp: as long as you have a quality grinder and water within 3 degrees of 95C
17:27gfrederickshyPiRion: seems like a bit more logic? is there some benifit?
17:27technomancysometimes it's good to have somewhere to walk to though
17:27sprocket_gfredericks, hyPiRion: i think i have some reading to do :)
17:27technomancyjust to stretch the legs and change perspective
17:28hyPiRiongfredericks: depends on how the configuration is set up, I guess? I mean, might be better for testing, etc.
17:28zerokarmaleftxeqi: oh derp, I see the overrides info now
17:29gfrederickshyPiRion: oh like being able to deliver it in alternative manners?
17:30hyPiRiongfredericks: right. Although I guess with-redefs works as well.
17:31hyPiRionfor testing purposes, I mean
17:32gfrederickshyPiRion: yeah I was typing that out and then deleted it and stopped, mostly out of wishywashyness
17:34zerokarmaleftbitemyapp: is it possible to get korma to log queries with parameters?
17:34bitemyappzerokarmaleft: you mean blackwater?
17:35bitemyappzerokarmaleft: https://github.com/bitemyapp/blackwater/
17:35zerokarmaleftyea, that's what I'm using
17:35zerokarmaleftbut e.g. where clauses are logged with the id passed instead of '?'
17:36rhg135any ideas on how one would write an abstraction over tcp reqquests?
17:36rhg135couldn't read the ring source
17:36bitemyappzerokarmaleft: blackwater prints the parameters passed to the right.
17:36bitemyappyou want the arguments to be interpolated?
17:37bitemyappthe arguments are | separated.
17:37zerokarmaleftbitemyapp: I'm only seeing time elapsed in addition to the sql
17:38bitemyappzerokarmaleft: did you look at the example on blackwater's github page? it should look like that.
17:38bitemyappif it doesn't, there's a bug or you didn't pass any params.
17:39zerokarmaleftbitemyapp: hmm, ok...I'll dive in closer to the metal, I've been testing with mock requests
17:40zerokarmaleftthanks
17:40sverihi, how can i inject a variable into a string in clojure? something like: (let [a "bar"] (str "foo????bar???"))
17:40rhg135format, sveri
17:40TEttingerbitemyapp: http://www.reddit.com/r/Coffee/comments/1abp48/
17:40sverirhg135: thx, thats what i was looking for
17:41rhg135np
17:42bitemyappTEttinger: what am I supposed to do with the blood stains?
17:42TEttingerbitemyapp, that isn't specific to aeropress, and I've only ran coffee through an aeropress once (I was having a hard time drinking coffee, so I decided to maximize the caffeine per half-cup I could drink). I was up all night, needless to say.
17:43TEttingerbitemyapp, saliva dissolves blood stains. bury bodies vertically under a dead dog.
17:43dubsgI'm interested in using clojure for a simple backend API that will interface with a mongo cluster. Mostly as a proof of concept and to weigh the pros/cons of writing an API I've written in Scala. Any library suggestions wrt the HTTP framework or MongoDB side? compojure with monger seem about right from some naive googling?
17:43technomancyTEttinger: seems like it'd probably end up too cool afterwards too
17:44TEttingerI don't drink very warm coffee, but this was not cold
17:44rhg135dubsg, sounds right
17:44rhg135but compojure doesn't actually serve
17:44rhg135you can use ring-jetty there
17:45technomancyI guess if you brewed it into a pre-warmed cup you might not loose too much heat
17:45TEttingeraeropress is a fast method, is the main reason why it wasn't cold I think
17:45dubsgI see, so perhaps just ring is needed to respond with JSON to GET's
17:45rhg135well
17:45justin_smithrhg135: well compojure only works with ring, so it kind of implies ring (or a ring compatible backend at the very least)
17:46technomancywell not necessarily for drinking, but you need 92+ for the extraction not to be sour
17:46justin_smithcompojure is for defining routes though
17:46rhg135ring actually makes sense of the http protocol
17:46rhg135compojure makes sure it's routed according to "rules"
17:46TEttingerI've since moved on from coffee to no-doz. something about the large cups of hot liquid doesn't work with my stomach. and no-doz is more predictable in terms of caffeine content
17:47dubsgI'm looking for something very simple, 'GET /some/path/:id' ==> 200 OK {bunch: of, json: yeah!}
17:47justin_smithand, ironically, thanks to its usage of macro magic, compojure is barely if at all composible
17:47rhg135yup xD
17:47TEttingerhaha justin_smith, that's awful and great at the same time
17:47justin_smithit is the truth, which is often both awful and great
17:47rhg135COMPojure
17:48sveridoes format work in clojurescript?
17:48rhg135sveri, it should
17:49rhg135it's core
17:49bitemyappjustin_smith: not ironic at all. Functions and data uber alles.
17:50sverirhg135: i get an error: TypeError: arp.charts.format is undefined
17:50rhg135bitemyapp, i think he was referring to the name
17:50bitemyappoh right.
17:50rhg135sveri, strange since it's core code
17:51sverirhg135: do i have to require some lib?
17:51rhg135sveri, no that's what core is
17:51rhg135included with the language
17:52sverirhg135: yea, i just wanted to make sure
17:52rhg135is it in string?
17:52rhg135i've never actually used it
17:53sverino, in core
17:53rhg135bbl tho
18:03zerokarmaleftbitemyapp: something's definitely missing in the korma hook, I'll try and come with a patch or at least a PR
18:04zerokarmalefts/a PR/an issue/
18:33TimMcgfredericks: I'd liek to hear more about your reverse-directional solution to ->/->>, but probably won't be able to read it until I'm off this train's blasted wireless.
18:33TimMcLeavea message at the *beep*.
18:37KeithPMHello
18:38justin_smithgreetings
18:42KeithPMHi Justin...
18:44KeithPMIs there a good tutorial on the Thread-second and thread-last macros? -> and ->>
18:52justin_smithhmm
18:53justin_smithhttp://clojuredocs.org/clojure_core/clojure.core/-%3E
18:53justin_smithKeithPM: the main thing to remember is that -> and ->>, since they are macros, are things that rewrite the code before it is evaluated
18:54justin_smithanother helpful thing is as-> for when you want to switch where the argument comes in
18:54brainproxyis there a straightforward way w/in project.clj to setup a library to depend on an older version of itself?
18:55justin_smith,(-> 1 (* 2) (+ 8) (as-> x (- 1 x)))
18:55clojurebot-9
18:56justin_smithbrainproxy: why not make it be a second library that extends the original?
18:57brainproxyjustin_smith: i could, but wondered if there is another way
18:58justin_smithbrainproxy: the problem is that classpath doesn't know about versions once it is constructed
18:58justin_smithso you would have two definitions of the same classes, just in different parts of the classpath
18:59justin_smithso how do you make the functions in version 2 see the defs in version 1, but everyone esle see version 2?
18:59justin_smiththat seems weird
18:59justin_smithnot to say it isn't possible, for all I know it is
18:59justin_smithjust seems weird to me
19:00brainproxywell i didn't know if there was a way to prefix or in some way auto-adjust the older version so that they don't conflict
19:24KeithPMHad to reboot. Any takers on Thread second and thread last (-> and ->>)?
19:25gdevwhat are we taking?
19:25arrdemgdev: KeithPM asked for examples of -> vs ->>
19:25arrdemKeithPM: did you see justin_smith's examples?
19:26gdev,(-> 'foo (str 'bar))
19:26clojurebot"foobar"
19:26gdev,(->> 'foo (str 'bar))
19:26clojurebot"barfoo"
19:27justin_smith,(->> 'foo (str 'bar) symbol)
19:27clojurebotbarfoo
19:27justin_smithanother nuance
19:27arrdemyeah the legality of bare symbols is nice
19:28arrdem,(-> {:foo :bar} :foo)
19:28clojurebot:bar
19:31gdev,(let [me {:rollodex {:contacts {:mom "Anna" :dad :dead}}}] (-> me :rollodex :contacts :mom))
19:31clojurebot"Anna"
19:31gdevalso good for getting at nested collections
19:32justin_smithalmost as handy as get-in
19:35arrdemIMHO more readable than get-in...
19:36justin_smithbut get-in allows non-IFn indexes
19:44gdevyeah (let [v [[1 2 3] [4 5 6] [7 8 9]]] (-> v 0 0)) gives you an exception but (get-in v [0 0]) gives you 1
19:50gdevKeithPM, hope that answers your questions, also no discussion on rocket science would be complete without me linking this vidya http://www.infoq.com/presentations/Macros-Monads
19:59KeithPMSorry I missed Justin's examples. I was rebooting
20:05KeithPMGood. Now does -> work with something like (count (filter #(== 3 %) (map second (frequencies (map rank hand)))))) ?
20:05rads,(clojure.walk/macroexpand-all '(-> 1 (+ 2) (+ 3) (+ 4)))
20:05clojurebot#<ClassNotFoundException java.lang.ClassNotFoundException: clojure.walk>
20:05radsbummer
20:06KeithPMThe problem I am seeing is that when I use map, it is hard to thread-second into the forms when I have fuctions like map and filter...
20:07TEttinger,(doc ->>)
20:07clojurebot"([x & forms]); Threads the expr through the forms. Inserts x as the last item in the first form, making a list of it if it is not a list already. If there are more forms, inserts the first form as the last item in second form, etc."
20:07radsKeithPM: that's what ->> is for
20:07rads(->> (map rank) (frequencies) (map second) (filter #(== 3 %)) (count))
20:07radswoops
20:08rads (->> hand (map rank) (frequencies) (map second) (filter #(== 3%)) (count))
20:08KeithPMOK!!!!! Yeah, I ike it!!! Lemme try that
20:09KeithPMthanks rads :)
20:09radsnp. -> threads the value in the first argument slot, ->> puts it in the last. that's the only difference
20:10KeithPMWow... It rocks!!!
20:11KeithPMSo one has to study the desired form to determine whether to use -> or ->>? I mean this fell out very naturally but most of the examples I see seem to lean towards the ->
20:13KeithPMI think this is probably how clojure has to be written, we seem to find ourselves in an inverted nested situation so easily, these operators turn things right side up fast...
20:14KeithPMgdev... I will do my monads tonight :) Thanks
20:14radsKeithPM: yeah, it's quite handy. it can also be helpful to use a (let) form to break up a computation into named steps, or to split up a long function into smaller ones to make it easier to read
20:15KeithPMThanks for all who chipped in to clarify this!!!
20:17KeithPMYes let is pretty handy, especially for destructuring and as you point out breaking up into named steps. I think I like the threading macros though, you could capture a long chain of thinking very clearly.
20:18KeithPMWhat was interesting in your solution is the use of what appears to be partial functions, e.g (map rank) is a function expecting a collection...
20:22KeithPMgdev, I did look at that one, time for a repeat :)
20:27gdevKeithPM, yeah it's a good video because it shows how much you have to repeat yourself and how the code flow can get out of natural order when you don't use threading
20:28KeithPMYes, I think this is a good time for me to review it since I am actually writing a lot of class code for this cool clojure class from Finland
20:31andyf_KeithPM: (map rank) in that example is not actually a partial function call, but a form that is manipulated by ->> at the expression level before any functions are called.
20:31andyf_KeithPM: Clojure also has partial functions, but unlike Haskell and perhaps some other languages they are explicit, e.g. using the function partial
20:32KeithPMAh ha... thanks... SO I should think of this as a pure macro play... It is reassembling human readable code into machine readable structures right?
20:32andyf_right
20:32andyf_Although humans can read the output of the ->> macro without too much trouble
20:32KeithPMGreat, thanks...
20:34SegFaultAXBy partial functions I assume you mean partial application.
20:34KeithPMLOL... This human prefers the linear view... Sure we can do it but is it something I want to be doing all day? I think I would much rather the -> and ->> forms, I could 'nest' as deeply as I want this way...
20:35KeithPMYes that's what I meant SegFaultAX. I am actually more familiar with currying/partial functions in Haskell
20:36bitemyappcurrying is one of my favorite things about Haskell
20:36bitemyappit's so simple, but so nice.
20:36SegFaultAXKeithPM: You keep on using this word. I do not think it means what you think it means.
20:36bitemyappnoprompt made a rather nice elaboration on a base-case with a curried function. It was nice.
20:36SegFaultAXbitemyapp: It's a cute but useful trick.
20:36bitemyappcute doesn't do it enough justice.
20:36KeithPMWhich word SegFaultAX
20:36bitemyappfromList = foldr insert empty
20:37bitemyapp^^ PRETTY
20:37SegFaultAXKeithPM: Partial function.
20:37nopromptpoint free FTW
20:37bitemyappKeithPM: when you say partial function, you mean partially applied function.
20:38bitemyappKeithPM: a partial function is a specific thing related to the concept of totality. Namely, partial functions have inputs for which there is no output. Total functions have at least one result for every input, even if it's the same thing.
20:38bitemyappI'm still pissed defcurried isn't in core.
20:38bitemyappgrumble grumble.
20:38KeithPMYes I agreed to that earlier :) I was just thinking about a function that was expecting additional variables... Partial application is actually the technically correct term from lambda calc
20:39andyf_bitemyapp: Pissed enough to file a ticket and write a patch? :-)
20:39SegFaultAXKeithPM: It has nothing to do with partial functions.
20:39KeithPMadditional values actually :)
20:39bitemyappandyf_: I've not signed the CA and I'm grumpy about other things too.
20:39KeithPMTrue
20:39andyf_bitemyapp: Of course putting it into a library is much easier.
20:39SegFaultAXdefcurried is a thing already, it just isn't public.
20:39KeithPMPartial functions are actually from calculus :)
20:39bitemyappSegFaultAX: #' is the savior of us all.
20:40bitemyappgoddamn, this is the smoothest pu ehr I've ever had.
20:40KeithPMThanks for pointing out SegFaultAX. I prefer accuracy in expression, that's our business :)
20:41SegFaultAXbitemyapp: Have you had ancient trees?
20:41SegFaultAXKeithPM: And also not saying things that are wrong or unrelated. ;)
20:41KeithPM:)
20:41bitemyappSegFaultAX: dunnae tink so.
20:41KeithPMI'll get it right
20:42SegFaultAXbitemyapp: It's so full bodied and delicious. It tastes like a cross between mushroom and tree bark. Quite strange, but very good.
20:42nopromptbitemyapp: my face isn't on the file anymore ;_;
20:43noprompt:P
20:43bitemyappnoprompt: hum?
20:43bitemyappSegFaultAX: so, have your pitchfork and torch ready?
20:43SegFaultAXAlways.
20:43bitemyappSegFaultAX: the FPers are getting together for an old fashioned holiday "run the heretic out of town" in honor of Gilad Bracha's uninformed talk.
20:43bitemyappso uh, partay at the Bracha haus.
20:44SegFaultAXWas that the one on Alan Kay?
20:44SegFaultAXNo. Which one was that?
20:44SegFaultAXOh
20:44nopromptdoes defcurried simply use partial behind the scenes?
20:44SegFaultAXThat one
20:45nopromptor does it do some macro magic?
20:45SegFaultAXDeconstructing FP. Yea that was a weird talk.
20:45bitemyappnoprompt: neither, I think it just returns a closure for each argument.
20:45nopromptSegFaultAX: was that the one on infoq about how functional programming is mostly bogus?
20:45bitemyappblargh. let me just look it up
20:45bitemyappnoprompt: mostly bogus is accurate.
20:46nopromptSegFaultAX: at least that's the impression i got before i fell asleep.
20:46SegFaultAXnoprompt: https://github.com/clojure/clojure/blob/master/src/clj/clojure/core/reducers.clj#L139
20:47SegFaultAXnoprompt: Bogus is a strong word, but overblown.
20:48noprompti'm basically going to skip talks like that.
20:48nopromptgoing forward.
20:48nopromptand blog posts too.
20:48nopromptgenerally speaking, i've found them to be an utter waste of time.
20:49bitemyapp(inc noprompt)
20:49lazybot⇒ 3
20:49SegFaultAXnoprompt: I like to keep an open mind about that sort of stuff.
20:49bitemyappshow code or gtfo I always say.
20:49bitemyappzerokarmaleft: I enjoy watching the aftermath of your drained sanity when you try to fuck with the monkeypatching of Korma.
20:49SegFaultAXHard to do with theoretical stuff.
20:50bitemyappBah.
20:50nopromptSegFaultAX: they're generally the same song in a different key.
20:50nopromptpop music for programming.
20:51bitemyappI think I like Haskell partly because it helps to put distance between me and the pop culture of programming.
20:51bitemyappI could tell I needed to reach for higher ground after 50% of the tweets about Clojure on my twitter were actually about Overtone.
20:52SegFaultAXImplying that Clojure is pop culture. Heh, I wish.
20:52bitemyapphits my threshold for it. Lots of people talking, little/no code, mostly about accessible nonsense like overtone or inclusion fetishism.
20:53bitemyappwork on something interesting or difficult enough, you don't have to talk about being inclusive because you're just grateful somebody, anybody...read your fucking paper.
20:54nopromptfair enough, but i'm w/ SegFaultAX here; i hardly think clojure represents the status quo.
20:55SegFaultAXNot by a long shot.
20:55bitemyappyou're mistaking pop culture for status quo
20:55bitemyappit has nothing to do with that.
20:55nopromptbitemyapp: yeah, wrong phrase.
20:56bitemyappIt's about the substance density and the faux participation of people not doing any work and just consuming/observing a few actually doing something.
20:56SegFaultAXI don't use or not use languages based on how trendy I or others perceive them to be. I wouldn't specifically pick Haskell over something else because it makes me feel like I'm in some elite minority group.
20:56bitemyappI consider it a perk, rather than a raison d'etre.
20:56noprompt(inc SegFaultAX)
20:56lazybot⇒ 3
20:57SegFaultAXbitemyapp: That's /always/ the way it is. There will always be more lurkers than producers.
20:57bitemyappThe primary reasons are things like having lost my patience with type errors.
20:57SegFaultAXThat's orthogonal to trendiness.
20:57bitemyappnoprompt: props for producing a lone error of the mythical category of "logic error" last night btw.
20:57bitemyappSegFaultAX: that would be my point.
20:58bitemyappmy reasons are many.
20:58bitemyappnoprompt: <3 the code.
20:58bitemyappnoprompt: if you wanted to genericize it you could make a Foldable instance for it.
20:58bitemyappAlmost want to do a post mortem of that error.
20:59radsdnolen: hey david, I've been trying out a fairly complex UI with om and I have some tricky questions for you: https://github.com/swannodette/om/issues/20 :)
20:59nopromptbitemyapp: yeah, i'm glad we're doing these sessions. i began looking into the rendering code earlier today.
21:00bitemyappnoprompt: awesome. I really enjoyed it last night despite being desperately exhausted.
21:02nopromptrads: have you expiremented w/ a single location for application state?
21:02nopromptbitemyapp: me too.
21:03dsrxbitemyapp: saying you're going to "reach for higher ground" because too much of your twitter feed smacks of accessibility sure as hell makes it seem like the raison d'etre
21:04bitemyappdsrx: nap.
21:05SegFaultAXI feel a tweet coming on... "LMAO if you use Twitter to judge the quality of a programming language community"
21:06bitemyappI already described it as a perk. o_O
21:06akhudekthink my favourite thing about the clojure community is the number of people who look at past work while trying to solve hard problems
21:06bitemyappSegFaultAX: if we really want to get into the quality of the community, I could talk your ear off about the libraries.
21:06SegFaultAXbitemyapp: Meh, it's a young language.
21:07SegFaultAXAnd generally things are improving all the time. There has been tremendous growth in the Clojure community over the last 2ish years.
21:08SegFaultAXCLJS in particular has brought in some big crowds in the last 12 months.
21:08gfredericksTimMc: I just looked back at the old versions and now I'm totally confused because I think they are what I was imagining
21:11nopromptthe best way to tolerate the programming community on twitter is to also follow an equal number of weirdos who are weird for weird's sake.
21:11dsrxfollow that NodeOS guy
21:11bitemyappnoprompt: which regex libraries did you poke at?
21:12nopromptdsrx: it's all about @coolpond.
21:12nopromptdsrx: sorry @cool_pond
21:14dnolenrads: trying to answer those questions myself, it's going to take some time to shakeout
21:14nopromptbitemyapp: not many. i've been thinking of wrapping a regex lib that provides extended regexp to ClojureScript.
21:15dnolenrads: in Om master I've made om.core/set-state! and om.core/get-state official
21:15nopromptbitemyapp: by "not many" i mean one.
21:16dnolenrads: I don't think you should put transient state into the app-state unless you might find that useful for undo operations
21:16dnolenrads: there's also support for absolute paths, so you can access the player info from anywhere
21:19dnolenrads: it's also worth considering whether information like that is best shared via channels and saved locally via om.core/set-state!
21:20nopromptdnolen: i've been having good luck with an abstraction that uses pub/sub to wrap application state.
21:21nopromptdnolen: my ui layer almost never talk to my data layer directly.
21:22noprompteveryone talks/listens to the application message broker.
21:22dnolennoprompt: that's another approach, I certainly haven't played w/ any of this enough to know what works and what doesn't
21:23nopromptdnolen: so far it's working fairly well. the difficulties lie mostly in structuring the application state.
21:24SegFaultAXManaging application state is a problem in general, so don't feel bad.
21:24nopromptdnolen: but it's allowed me to avoid making api calls and direct state manipulation in places where it really shouldn't belong.
21:26SegFaultAXdnolen: What's the long-term strategy for Om? Is it something you see yourself maintaining, or is it more an exercise in what can be done using new types of front-end architectures?
21:26dnolenSegFaultAX: the point of Om was mostly to show what's possible and illustrate what I think are dead ends
21:26dnolendead ends == copying what JS devs do
21:27dnolenbeyond that that I think it's up to everyone to figure out what actually works when leave those approaches behind
21:27SegFaultAXdnolen: What are the biggest pain points in building and maintaining complex javascript frontends?
21:28dnolenSegFaultAX: I think the entire model is busted
21:28dnolenthus Om
21:28SegFaultAXWhich model?
21:28dnolentreating the DOM as a "place"
21:28dnolenwhich sits at the foundation of modern JS practice
21:28SegFaultAXAh, yeah.
21:35ddellacostait's true, we recently stopped treating our DOM as a place but rather as a sort of "render target" and it has saved us a lot of pain. We still maintain a client-local data store, but this is wholly segregated from the DOM, and could exist anywhere really. The React.js/OM approach now seems obviously better to me.
21:37bitemyappddellacosta: I've done similarly in how I've changed how I approach frontend.
21:37ddellacostathe place I still struggle is complicated user interactivity flows. Even while core.async helps a bit here, it doesn't alleviate all the pain. Still feel like I'm doing something wrong.
21:37ddellacostabitemyapp: yeah, it really seems to be the direction folks are moving in.
21:38dnolenddellacosta: UI programming is hard, but it doesn't need to be insane, which is how it usually feels.
21:38radsdnolen: I will have to take a look at pedestal again and see if there are any lessons for om. IIRC pedestal-app deals with the same issue of app state vs ui state
21:38ddellacostadnolen: yeah, that's fair, and I think that sums it up pretty well.
21:39dnolenrads: I think my ticket about including get/set-state APIs more or less sums up my ideas
21:39dnolenrads: transient state doesn't go into app-state unless for some reason you want/need to record it
21:40dnolenapp-state is really just the pure "model"
21:40dnoleneverything transient should go in component state
21:41rovarcan someone explain to me what the ^{:export foo} mechanism is?
21:41rovarhttps://gist.github.com/jolby/1119294
21:41radssounds good, I'll take look at the new code
21:41dnolenrads: there are some complications because parent component need to communicate things to children component like - are you in the edit state? modifying the subview list etc. that's stuff I'm pondering next
21:42ddellacostarovar: export in CLJS allows you to call a function from JS code.
21:43nopromptdnolen: this is the type of stuff i put in my application "state" which is connected to the root of the ui.
21:44dnolennoprompt: yeah, I'm not quite convinced about doing that - I think there's room for a new kind of component
21:44nopromptdnolen: not all of it but most of it. click an edit button update the application state to be in edit mode.
21:44dnolenom/children or something like that
21:44radsdnolen: so in react there is no concept of app state, what is the use case for it here instead of only having state inside components and communicating through props/channels?
21:44nopromptdnolen: like i said, i use pub/sub as the intermediate device.
21:44dnolenthat provides a higher level abstraction than what's current available
21:44dnolensome like this would give you filter/sort/insert/remove w/o needing to interfere
21:44dnolenit all feels to manual at the moment
21:44dnolens/to/too
21:45nopromptdnolen: well i'm sure if anyone will find a solution, it will be you. :)
21:45dnolenrads: React has props, that's what app-state is props
21:46dnolenrads: it's experiment, but I think the value of app-state is that you can always see your app as data
21:46dnolenrads: Om is just a fancy interface for human beings to Clojure(Script) data
21:46dnolento paraphrase Kovas B., Om is a trick to make it tangible w/o having to actually write code
21:47dnolenyou can manipulate some data a UI and still get the plain data out w/o futzing around too much
21:47dnolen"some data with a UI"
21:48rovarddellacosta: ahh. so it's like an ffi interface for callbacks. Do people still use this model often? I don't see it often in clojurescript examples.
21:49ddellacostarovar: I have used it often when I've needed interop with JS or CoffeeScript code. I use it less now that our codebase is getting closer to 100% CLJS.
21:54logic_progwhat is the standard way to sahre code between cljs and clojure?
21:54rovarddellacosta: I am interested in targetting ios, android and web with approximately 1 codebase.
21:54rovarI'm hoping that can be clojure
21:54logic_progi hate code duplication and I have some data structures that I need to mirror on both sides
21:55dnolenlogic_prog: there are various ways to do cljx is somewhat popular
21:55logic_progdnolen: yeah, https://github.com/lynaghk/cljx was the first result on google
21:55ddellacostalogic_prog: I think it depends, cljx works well in some cases, but if there is relatively little interop, crossovers should work fine
21:55ddellacostainterop = Java/JS interop I mean
21:56ddellacostarovar: I can't speak to that, I'm sorry--I haven't done anything other than web dev with CLJS.
21:56logic_progddellacosta: "relatively little interop" == "relatively little platform (jvm / js) dependent code" ?
21:56ddellacostalogic_prog: that's my feeling about it--I think cljx is kinda moot if you don't have much that is platform dependent. That said, maybe there are other arguments for using it over crossovers that I'm missing.
21:57dnolenrovar: I think iOS story could be good now that there's a decent bridge from JS to native - maybe Android will get it's act together at some point, PhoneGap until then I guess.
21:57rovaryou should be able to make a clear delineation between your core business logic and the "presentation" layers.
21:58dnolenrovar: still, CLJS and Clojure don't really try to get to crazy papering over platform differences, that's left for applications to solve.
21:58logic_progddellacosta: https://github.com/emezeske/lein-cljsbuild/blob/master/doc/CROSSOVERS.md does look really simple
21:58rovardnolen: I was thinking about using appcelerator titanium, which can hit ios and android with javascript, and that link I posted above demonstrates that it can be targeted with clojurescript.
21:58rovarthe other thing was maybe use cljx, and target android natively with java, and use cljs for the ios platform..
21:58dnolenrovar: that could work too, I don't know much about Titanium
21:59ddellacostalogic_prog: can't tell if you're being sarcastic or not...haha
21:59ddellacostalogic_prog: but I've used both, and I haven't found either of them too complicated really. crossovers don't require a separate library, is all.
22:00logic_progddellacosta: not sarcastic, cross overs is basically almost a straight up "cp" right?
22:00logic_progddellacosta: i.e. it monitors when things change, then copies things over
22:01logic_progddellacosta: one thing I don't understand: suppose I have a piece of code, which depends on clojure.core.rrb-vector in clojure land, and cljs.core.rrb-vector in cljs land, is there a way to make this work with crossovers?
22:01ddellacostalogic_prog: ah, yeah--mostly just configuring your project.clj to set up where it should be picking up crossover code, in my experience.
22:01ddellacostalogic_prog: don't know the answer to that--my intuition is that if the library is both Clojure and CLJS compatible, it should just work--but don't know without trying it.
22:02ddellacostalogic_prog: if there are separate interfaces for the two, then you may need to use cljx to get compatibility, however.
22:03ddellacostalogic_prog: by separate interfaces I mean, one interface for using clojure.core.rrb-vector with CLJS vs. Clojure, for example (no idea if that's the case)
22:03logic_progthey use the same protocol
22:03logic_progI think I can make it work :-)
22:03ddellacostalogic_prog: let us know how it goes! :-)
22:21rovarhas anyone tried making leiningen listen to git?
22:21rovare.g. post commit hook http posts or somesuch?
22:21rovaror even polling
22:21rovarI'd rather use leiningen instead of jenkins
22:22arrdemrovar: hooks to achieve what... building?
22:22rovararrdem: yes, build automation / deployment
22:22rovarCI
22:22arrdemrovar: you should be ableo to hack up a post-recieve to build in not time.
22:22rovararrdem: that's what I figure, so easy in fact, that I figure someone else has done it :)
22:23arrdemrovar: I wrote and published a paper not to long ago on what ammounted to that :P
22:23rovarwell that's a good start :)
22:23arrdemrovar: turns out that because it's so easy everyone just rolls their own.
22:23rovaryea.. good to know I'm not crazy at least..
22:23arrdemrovar: but yes we (as a community) could build really good hooks support for a lot of development process stuff.
22:23rovarjenkins just seems like overkill when about a dozen lines of clojure should do what I need.
22:23arrdemrovar: that we don't is characteristic of our general lack of process and software engineering
22:24arrdemor four lines of bash :P
22:24arrdemthat's the sad thing... a little well considered bash scripting can get you rediculously far
22:24rovarthat is a good point
22:25rovarI guess I could make a post commit hook to call leiningen
22:25arrdemright. that's all you need. echo "lein build; git push deploy;">> hooks/post-recieve
22:26arrdemI mean my typical setup is I have one bare git repo that's the "master", and it has a post-recieve that cd's into deployment and `git pull --rebase`es
22:26arrdemtotally works to deploy node and clj code.
22:26rovarI'd need to make my git server my build server, or make it auto-push
22:27arrdemyeah but achieving that sort of auto-push is really pretty easy...
22:27arrdemand totally worth doing IMHO
22:28arrdemI suppose there should be a git template for this kind of setup...
22:28arrdem~ideas
22:28clojurebotHuh?
22:28arrdem~todo
22:28clojurebottodo is http://clojure.org/todo
22:28arrdemhum... I thought I had an "ideas" var. oh well.
22:29justin_smithrovar: leiningen instead of jenkins? I have never heard of such a thing. But it is easy to make jenkins use leiningen
22:29rovarblarg
22:29justin_smithI mean I guess it varies depending on how much of the jenkins feature set you are using
22:29rovarjenkins has acquired mass of its own
22:30rovarit requires significant exit velocity
22:30justin_smithsure, I use it because my workplace has a jenkins server set up for all of our projects
22:30arrdemjar jar
22:30arrdem*har har
22:30bitemyapparrdem: soup
22:31justin_smithwhat jenkins does for auto-deploy is poll every X minutes, and if it pulls anything new from origin/master it runs the build/deploy script
22:31justin_smithyou could do that with cron
22:31justin_smithor if you really wanted to you could make a clojure program that did that I guess
22:32rovarat work, where we have many dedicated git servers, we use jenkins for kicking off jobs from git
22:32arrdembitemyapp: gaming box is capable of 351khash/s for dogecoin mining :D
22:32justin_smithcreate a future that sleeps and then runs the check / conditionally builds and deploys / launches itself again
22:32rovarwhile not at work, I could manage something more akin to a post commit hook :)
22:32justin_smithif you want to build on the same machine you are hosting git on, yeah that works
22:32bitemyapparrdem: mumble?
22:33arrdemI really want to build a post-commit hook that approximates Jenkins while staying really stupidly light weight and free...
22:33rovarI'm afraid I don't get the dogecoin joke, if it is one..
22:33arrdembitemyapp: not tonight. both mining and family. I'll be lurking here tho.
22:33justin_smithsomeone should totally make the miniature jenkins
22:33bitemyapparrdem: isn't mining automatic though?
22:33justin_smithrovar: dogecoin may be a joke, but it also exists
22:33arrdembitemyapp: but I'm doing it from Linux and it's pegging the geepus
22:34justin_smithrovar: http://motherboard.vice.com/blog/dogecoins-founders-believe-in-the-power-of-meme-currencies
22:34arrdembitemyapp: so if you want to play some FTL we're good, but otherwise no
22:34rovarI see that it is very fashion
22:34bitemyapparrdem: er, FTL is multiplayer?!
22:34arrdembitemyapp: no. I'm joking.
22:34bitemyappI'd be up for just chatting anyway.
22:34justin_smithrovar: so meme, much flog dead horse
22:34arrdembitemyapp: if it was, it would surely be harder.
22:34arrdem(inc justin_smith)
22:34lazybot⇒ 21
22:35arrdemjustin_smith: hey, I have 4533 dead horse points from under 24hrs of mining stfu
22:35justin_smith:)
22:35rovarhow money
22:35arrdembitemyapp: so how does typeclass based dispatch get implemented?
22:35bitemyapparrdem: I figured out how to be reasonably successful in DayZ, as I'd mentioned, but people are pretty ruthless bandits right now.
22:36arrdembitemyapp: I totally believe that
22:36bitemyapparrdem: you infer the type, then rewrite things like "show" to "show_mytype_tc"
22:36bitemyappI mention the banditry because it's worse than usual. You have zero chance of making friends and banding together for mutual benefit. Kinda disappointing.
22:37arrdembitemyapp: ah so it's compile time static because more type information is apparent than just the typeclass.
22:37arrdembitemyapp: the entire implementation is known statically.
22:37bitemyappRight.
22:37arrdemhum. ok.
22:38logic_proghmm
22:38logic_proglein clean wipes out "cljs" when I use crossovers
22:40arrdembitemyapp: so is long term survival possible in dayz? it seems like most of the resources in the game are nonrenuable.
22:51bitemyapparrdem: long term survival is possible.
22:51bitemyapparrdem: requires developing routine that includes stopping for water.
22:52bitemyapparrdem: getting proper weapons with ammo requires a hell of a journey.
22:56arrdembitemyapp: right. making it to the airfield.
22:57rovarat one point I liked games like that
22:57rovarthen I got a job
22:57arrdem(dec jobs)
22:57lazybot⇒ -1
22:57rovarand decided I didn't want two jobs
22:57rovarI was big into Shadowbane and DAoC
22:57arrdemrovar: yeah that's why I'm not really engaged in dayz. it's cool... but I don't feel like spending my "free" time trying not to die.
22:57bitemyapprovar: this isn't an MMO.
22:58rovaro rly?
22:58arrdembitemyapp: ... persistant state? it basically is...
22:58bitemyappnot in the sense that it has grinding, no.
22:58bitemyappthere's only 40 people to a server
22:58rovarinteresting
22:58bitemyappand it only takes 2-3 hours to max out your gear.
22:58bitemyappyes, it saves your personal state
22:58rovaris that a beta restriction?
22:58bitemyappI've no idea what their long term plans are
22:58bitemyappbut it's always been the case that the servers are interchangeable.
22:59bitemyappand again, there's no grinding.
22:59bitemyappyou're just surviving and making your way around - avoiding bandits (human players) and zombies.
22:59bitemyappI had to have a couple of failed runs (less than one hour apiece) before I understood how to survive and navigate.
23:04bitemyapprovar: but yeah there are no levels. The only thing that "levels up" is your knowledge
23:04rovarinteresting
23:05bitemyappknowledge of where loot tends to be, that sort of thing.
23:22rovarwowow.. the android emulator on my linux box is intractably slow
23:22rovari'm not sure how people get any work done..
23:25ddellacostarovar: whenever I've done android dev in the past, I've only ever used a real handset. The emulator is just pointless
23:25rovar:(
23:40arrdembitemyapp: you still there?
23:41arrdembitemyapp: remaining family is watching the idiot box. you've got yourself a partner.
23:42bitemyapparrdem: hum.
23:42bitemyapparrdem: I am in mumbur.