#clojure logs

2014-07-27

00:36lpvbI'm sorry I asked this question before but had to afk,
00:36lpvbdo swap! reset! compare-and-set! block?
00:37jeremyheilerlpvb: do you mean block as in sync/async, or block as in locking?
00:38lpvbum, I think locking, if that's the one where the function doesnt return until it's completed
00:39jeremyheilerok, so atoms don't block in the sense that they don't lock up a thread. but they do return synchronously. i believe you mean the latter.
00:39jeremyheilerthat is, they complete their action before returning
00:40lpvboh
00:40lpvbyea that's what I meant
00:40lpvbwhats the difference between locking
00:42Fareis there a builtin equivalent of CL's ignore-errors, or do I have to define it with a try / catch all
00:43Farehow do I catch all?
00:43jeremyheilerlpvb: locking specifically has to do with thread coordination. so, if it were a locking mechinism, another thread that tries to change that atom concurrently will block until the original unlocks it. however, it doesn't do it that way.
00:44lpvbjeremyheiler: oh I knew that one, I was just confused from the wording
00:44jeremyheileryeah, i suppose the word "blocking" is overloaded :-/
00:45jeremyheiler... or at least can imply different things at a high level
00:46Fareis there a standard way to strip a string's prefix?
00:46jeremyheilerFare: you catch Exception (or Throwable if you want to catch even fatal jvm errors)
00:46jeremyheilerFare: clojure.core/subs ?
00:59john2xwhy is subs in clojure.core, and not in clojure.string?
01:00TEttingerit's probably used in clojure.core internally?
01:00TEttingermacro whatnot?
01:02jeremyheilerhmm... it is used internally, but so is .substring
01:03jeremyheilerlooks like subs was introduced in 1.0, but clojure.string was in 1.2
01:07Farejeremyheiler, yes, that's what I do. Just wanted to know if there were builtins for the same.
01:09jeremyheilerFare: nope :-/
01:10FareI'm slowly but surely developing a collection of random small utilities.
01:53kristofFare: Wrong channel but are you familiar with subject-oriented programming?
01:54kristofFare: Your discussion on multiple "views" of the same essential object using composition of interfaces reminded me of it, and I believe you wrote that you were looking for good examples of such uses
01:55kristofFare: I was going to suggest that the papers on SOP would surely yield such examples and I was even thinking of rewriting many of them myself using LIL just as an exercise
01:58Farekristof, not super-familiar
01:59Faredo you mean something similar to urbit or nominine?
01:59kristofNot in the slightest, I have no idea how urbit could relate
01:59kristofIsn't urbit dead in the water while Curtis figures out his jets or whatever?
02:50tufto
02:51tufthmm, momentarily tmux confused there
02:56Farekristof, didn't slate implement subject-oriented programming?
02:57Fareand/or AspectL ?
02:58Fareyou can of course reimplement it using Interface-Passing Style.
02:59Farewhere your interfaces can be seen as the subject
03:17ProTipAnyone familair with using om?
05:23daGrevishi! how could i say something like if “x“ is in ["x" "y" "z"] ?
05:25daGrevislooks like im looking for contains?
05:29TEttinger,(#{"x" "y" "z"} "x")
05:29clojurebot"x"
05:29TEttinger,(#{"x" "y" "z"} "a")
05:29clojurebotnil
05:29TEttingersets are functions, daGrevis
05:30daGrevisi didn't have set though
05:30TEttinger,(doc contains?)
05:30clojurebot"([coll key]); Returns true if key is present in the given collection, otherwise returns false. Note that for numerically indexed collections like vectors and Java arrays, this tests if the numeric key is within the range of indexes. 'contains?' operates constant or logarithmic time; it will not perform a linear search for a value. See also 'some'."
05:30TEttingerthere's that too
05:30daGrevisyep, did that with contains?
05:30TEttingerhaha I thought you were asking a question at first
05:30TEttingerthe ? at the end threw me off
05:30H4nsdaGrevis: only that it does not work, as contains? checks for the index range, not the values
05:31H4nsdaGrevis: ((set ["x" "y" "z"]) "x")
05:31daGrevisTEttinger, ha :)
05:32TEttingeryou're right, H4ns -- "key is present" not "value is present"
05:32daGrevisH4ns, right. good catch
05:33TEttinger(inc H4ns)
05:33lazybot⇒ 1
05:34daGrevisany idea how could i check that something is a English word or isn't?
05:34daGreviswant to filter out stuff like “anc2iwv9wh“
05:35daGrevisi have idea myself. get entropy of that
05:58hyPiRiondaGrevis: sliding window + dictionary?
05:59hyPiRionIf you just want to check if something is an English word, you only need to look it up in a map.
05:59daGrevisi want to let through words with mistakes etc.
06:01hyPiRionuh. I'd go with Levensthein-Damerau then
06:01daGrevisokay, I will read about it
06:01daGrevisis there something like take-while that includes the element that returned false?
06:03daGrevis,(take-while #(== % 2) [1 2 3 4])
06:03clojurebot()
06:03daGrevisoh well ignore that
06:04farhavendaGrevis: do you only want to know _if_ something is an english word or do you want to offer translations?
06:04farhavenfor the former, a bloom filter could be a nice idea
06:04daGrevisfarhaven, i want only to know
06:05hyPiRionfarhaven: bloom filters would be reasonable if daGrevis didn't want words which may be mistakes to pass through
06:06daGreviswell i think that i can fix problem in the root
06:06farhavenmake the filter large enough and errors become almost impossible :P
06:06daGrevisu see i get those words from twitter
06:06daGrevisand i parse them by simple regex
06:06farhavenheh, good luck finding any english in there
06:07daGrevisi get links inside them too and I don't want stuff like t.co/abc123 there
06:07daGrevisactually it's more like t.co and abc123 based on my current regex
06:07daGrevisfarhaven, :)
06:09daGrevismight as well parse some book
07:41gfixlerHow would one achive (map vector [1 2 3] [4 5 6] [7 8 9]) if the vectors were infinite?
08:24AeroNotixgfixler: take
08:25AeroNotixgfixler: https://gist.github.com/AeroNotix/a45de619ad2d4245cd53
08:25AeroNotixmap returns a lazy seq
08:25hyPiRiongfixler: do you mean an infinite number of vectors?
08:41expezI'm trying to read a file in a macro but the form (io/file some-file) barfs complaining that some-file is a symbol. How do I fix this?
08:41AeroNotixexpez: show macro
08:43expez(defmacro my-macro [my-file] (println (slurp (io/file my-file)))) would be a minimal example
08:43AeroNotixso you need to splice the my-file variable
08:43AeroNotixand also, you need to return a syntax quoted form
08:44AeroNotixsince that body will be evaluated at compile-time
08:44AeroNotixand thus, my-file is literally a symbol
08:44expezright, I want to use the content of the file to build the source, but I'm having problems reading the file at compile time
08:46expezPerhaps it's easier if I just wrap the macro in a function which reads the file?
08:46AeroNotixexpez: show how you're calling this
08:47AeroNotixbecause if you want the file to be read at compile-time, you need to pass something which has a value at compile-time
08:47AeroNotixso that would be a string in the case of io/file
08:47AeroNotixIt only operates on the raw syntactic elements, not the values they may represent at runtime
08:48AeroNotixexpez: look
08:48AeroNotixhttps://gist.github.com/AeroNotix/cba1855cc8bf18f0b612
08:48AeroNotixbecause the macro gets the symbol 'c
08:48AeroNotixnot the string it represents
08:49AeroNotixbecause at macroexpansion time, this is all it has
08:49AeroNotixUnfortunately Macros are not covered in as much depth as they should be
08:50expezMight be a blessing in disguise
08:50expezIn cl I found the need to write a macro a lot more often
08:51AeroNotixThat's probably not the case
08:51AeroNotixMacros are overused
08:51AeroNotixbut, perhaps you need one here -- what are you trying to do?
08:52expezI'm writing a small library that records the arg => result pairs for certain functions and then creates mocks using the arg => result pairs it squirreled away
08:52expezwell, I'm trying :)
08:52AeroNotixexpez: so the first part is taken care of by memoization
08:53AeroNotixexpez: http://clojuredocs.org/clojure_core/clojure.core/memoize
08:53expezI want to persist this to disk, so my tests don't hit external services
08:54AeroNotixIIRC memoize puts the mapping as part of its metadata
08:54AeroNotixyou could run your tests once, read out the memoize data
08:54AeroNotixTBH -- this seems like a lot of work just to not write mocks yourself
08:55llasramexpez: So the goal is a more general version of something like the Ruby VCR library?
08:55expezThat's what I thought, but when the external services keep changing I found myself manually capturing a lot of data for use in mocks
08:56expezllasram: yeah, that's the idea
08:57expezFigured this would be pretty easy to write, but that project has 1.7k commits Oo
08:57AeroNotixFor something basic it'd be pretty easy
08:58llasramexpez: My suggestion for approaching this would be to write a very small macro which uses `with-redefs`
08:58AeroNotixyeah^
08:58AeroNotixand having your body executed by logging the args and values to disk
08:59AeroNotixAnd your macro would also generate code for reading a specific file (this can be done at runtime)
08:59llasramWell
08:59llasramHaving trouble phrasing for some reason
08:59llasramBut I think it'd be easier if the macro did nothing but the `with-redefs`
08:59expezyeah, this is the part I got stuck on, trying to read the bindings for with-redefs from file
08:59llasramAnd the main body of the work happened in the generated function you redef too
08:59AeroNotixllasram: this^
08:59llasramInteresting
08:59AeroNotixThere's no reason it needs to read the file at compile time
09:00AeroNotixmacroexpansion time*
09:00AeroNotixjust generate the code for it
09:00expezmhmm :)
09:00expezThanks guys!
09:00llasramexpez: Why do you need to specify the bindings in a file?
09:00AeroNotixllasram: to persist across runs
09:00AeroNotixthey want to run their tests, get initial values, run tests again using the values from the previous run
09:01AeroNotixfor some functions
09:01llasramI guess I'm thinking of the VCR style, where you write your test, it captures data the first time you run it, then it regurgitates the captured data on subsequent runs
09:01llasramIn that model, you'd specify the functions to wrap in your test
09:01AeroNotixllasram: sure -- but it needs to persist this data somewhere, right?
09:02llasramSure. I'm just talking about specifically "then bindings for with-redefs"
09:02llasrams,then,the,
09:02AeroNotixnot sure what they meant by that
09:02llasramIndeed
09:02llasramAnd now we may never know...
09:03AeroNotixThis doesn
09:03AeroNotixThis doesn't seem like a difficult task for Lisp
09:03AeroNotixI'd probably make something like defn-recorded
09:05AeroNotixexpez: https://github.com/ifesdjeen/vcr-clj
09:05AeroNotixthere's this
09:06AeroNotixI have the same reservations as Alex there
09:06AeroNotixMocking stuff is notoriously difficult to do properly
09:09expezyup
11:18mi6x3m-althey guys, what would you call a function returning the page size of a webbrowser page?
11:18mi6x3m-altpage-size [browser] ?
11:20jeremyheilermi6x3m-alt: do you not like page-size?
11:22mi6x3m-altjeremyheiler: nah, just asking :)
11:22mi6x3m-altwithout or with verb
11:25jeremyheilerit seems fine, given the context you gave
11:28vdmit11Hi folks. I need to define a type whose interface and semantics almost exactly matches to list. The only difference I need is a different class name and perhaps a custom toString method. How can I do that?
11:30vdmit11In other words, I need to inherit list. I know inheritance is bad, but in this case it helps to avoid boilerplate code.
11:31bbloomvdmit11: do you really mean list? or seq?
11:32dnolen_vdmit11: if you're talking about deftype not possible, you just have to write the code
11:32dnolen_or defrecord for that matter
11:36vdmit11well, generally I need a sequence, but the list is the most suitable thing for me
11:38Glenjaminwhy cant you just use an actual list?
11:43vdmit11Well, I collect actions into lists. And there is two slightly different kinds of such list: one means "actions are done in sequence", another means "actions are done in parallel". They may be nested to each other and so on. And I would like to distinguish them, and I think it is not really a metadata, so I think perhaps I can just make two classes with the same behavior but different names.
11:45H4nsuse a hash with a type and a list key. the type indicates whether it is parallel or sequential.
11:45bbloomyes, what H4ns said
11:45bbloomor, use a vector and a set
11:46bbloom[do this and then this] vs #{do all these in any order}
11:47H4nsno need for a "type", that is the message. just combine the existing data strutures in the way that you require.
11:47TimMcvdmit11: Yes, as others have said, the correct answer is to lift the tagging from the virtual machine level (class-tagged objects) to the "userspace" level -- tag/list pairs.
11:48vdmit11set looks more suitable because the order of parallel actions doesn't matter, but it requires the elements to be unique, and I think I may have duplicate actions done in parallel
11:50vdmit11tagging in a hash-map looks a bit redundant, but if there is no cleaner way, I'll use it
12:01bbloomi'm sure there's a multiset out there somewhere :-)
12:03myguidingstarSomeone please help with this strange Clojurescript compilation error: https://gist.github.com/myguidingstar/ad29083023130817eb01
12:08gfredericksmyguidingstar: that's definitely a weird use of macros
12:08gfredericksi.e., calling macroexpand
12:09gfredericksmyguidingstar: are you sure you need a macro here?
12:09myguidingstargfredericks, I know it, but I need an abstraction over javascript
12:10gfredericksmyguidingstar: what are you trying to do exactly?
12:10myguidingstargfredericks, please consider it a playground. I don't understand why the compiler yelled that message
12:14gfredericksI don't either.
12:14gfredericksand I don't have a cljs setup so I can't try reproducing outside of vanilla clojure
12:18gfredericks(and macroexpanding that in vanilla clojure doesn't give anything suspicious)
12:19dnolen_,{{}}
12:19clojurebot#<RuntimeException java.lang.RuntimeException: Map literal must contain an even number of forms>
12:19dnolen_hrm, anyways myguidingstar my guess is that you have a malformed map based on the error
12:20dnolen_,(hash-map {})
12:20clojurebot#<IllegalArgumentException java.lang.IllegalArgumentException: No value supplied for key: {}>
12:21dnolen_but also those macros don't make sense I can't really understand them
12:28myguidingstardnolen_, I've just updated the explanation
12:28myguidingstarbtw, do you think it's a bug?
12:30dnolen_myguidingstar: I still have no idea what you are trying to do or why you trying to do it
12:30gfredericksmyguidingstar: line 26 should fail the read regardless
12:30dnolen_if I can determine the above then maybe we can talk about bugs
12:30dnolen_that said ... I doubt it
12:31myguidingstardnolen_, I'm trying to make a Compojure-like abstraction over a javascript request handler
12:32dnolen_myguidingstar: but what is the macro doing for you here?
12:32dnolen_it seems to serve no purpose
12:32myguidingstardnolen_, user can use Clojure map to define what a request return
12:33myguidingstar(instead of imperatively calling Javascript)
12:33gfredericksmyguidingstar: why can't you do that with a function?
12:33dnolen_myguidingstar: what gfredericks said
12:34myguidingstargfredericks, yes of course, but a macro should produce shorter javascript at runtime
12:35myguidingstaranw, please consider it a playground
12:36dnolen_myguidingstar: remember, you have Google Closure Compiler working for you - anything you might do by hand will be trivial compared to that.
12:36myguidingstardnolen_, thanks. I didn't think about it
12:37myguidingstaranw, I want to learn an other thing about this mess, too
12:38mi6x3m-altis there a version of doto that returns nil?
12:38myguidingstar(sorry for being so annoying)
12:38gfredericksmi6x3m-alt: no
12:38gfredericksmyguidingstar: maybe try to produce a more minimal case?
12:39gfredericksextra points if it involve just one macro
12:39mi6x3m-altgfredericks: thanks
12:39myguidingstargfredericks, I did, and that one worked
12:42gfredericksmyguidingstar: e.g., try it without the map, or with fewer keys in the map
12:42gfrederickswithout the pr-str
12:42gfredericksetc etc
12:43dnolen_,(let [{:keys [foo]} '(foo [] {})] foo)
12:43clojurebot#<IllegalArgumentException java.lang.IllegalArgumentException: No value supplied for key: {}>
12:43dnolen_myguidingstar: ^
12:43dnolen_myguidingstar: my-response is getting (end [] {}) unevaluated and you're trying to destructure that
12:43dnolen_er (end [] {})
12:44myguidingstardnolen_, you're right. But I tried with (macroexpand ...)
12:44myguidingstarand it still failed
12:44gfredericksoh geez I didn't know you could map-destructure a not-map
12:44dnolen_myguidingstar: if you need to call macroexpand in a macro ... game over
12:44dnolen_myguidingstar: so the only good that will come of this is understanding how macros work ... fine if that's your goal
12:45myguidingstargfredericks, I've just comment a more minimal code that works
12:46myguidingstardnolen_, absolutely I want to
12:46myguidingstardnolen_, any suggestion to make it work?
12:47dnolen_myguidingstar: macroexpand doesn't work for different reasons
12:47dnolen_+ isn't defined for collections
12:47dnolen_you want str not +
12:47gfredericksdnolen_: that shouldn't fail at macroexpand time though?
12:48gfredericks,(macroexpand `(+ ~{} ~[]))
12:48clojurebot(clojure.core/+ {} [])
12:48dnolen_gfredericks: it's not failing at macroexpand
12:48dnolen_failing at runtime
12:48gfredericksooh okay
12:48myguidingstardnolen_, I use [] and {} to make sure it's evaluated in javascript
12:49dnolen_myguidingstar: macroexpand and changing + to str makes it work
12:49dnolen_myguidingstar: I don't know what you are saying
12:49dnolen_if it's a http response it's just text
12:49dnolen_nothing to do w/ JavaScript
12:51myguidingstar(+ [] {}) is just to make sure the code is executed in javascript environment, not Clojure (macro expansion)
12:51dnolen_myguidingstar: yes this statement does not compute
12:51dnolen_(+ [] {}) is not legal Clojure or ClojureScript
12:52myguidingstaryes, you'll get a type warning for that
12:52myguidingstarhmm, that's a bit off track
12:52gfredericksdnolen_: I think he means he can tell where + is running based on whether he gets an exception from the jvm or the js runtime
12:54dnolen_gfredericks: well ClojureScript has inference enough for obvious problem like this one - compiler warning
12:55myguidingstardnolen_, I learnt that trick from clojurescript.test README https://github.com/cemerick/clojurescript.test
12:58dnolen_myguidingstar: anyways this works https://gist.github.com/swannodette/332c574cb4d9df41aa35
13:00dnolen_myguidingstar: but as I said before you can abstract over some JS lib w/o any of this macro stuff, it just creates more problems to do it this way.
13:01myguidingstardnolen_, that's quite strange. I think I was unsuccessful with such code
13:01myguidingstardnolen_, that's the best lesson for me today, thanks
13:01gfredericksmo macros mo problems
13:01myguidingstarrule #1 ;)
13:02SagiCZ1hey guys.. i want to assert that there is only zero or one element in a collection, if there is more, i want clojure to throw runtime exception, how do i do that?
13:02dnolen_SagiCZ1: assert
13:02dnolen_,(doc assert)
13:02clojurebot"([x] [x message]); Evaluates expr and throws an exception if it does not evaluate to logical true."
13:03SagiCZ1dnolen_: wow.. that was hard..
13:03SagiCZ1dnolen_: thanks :)
13:03dnolen_np
13:04gfredericksSagiCZ1: assert is only appropriate for guarding against programmer errors
13:07whigmaleeriednolen_: opinion of assert vs the built-in precondition meta data?
13:08dnolen_whigmaleerie: just depends
13:09bbloomi've kinda given up on :pre
13:09bbloomevery time i use it, i shortly later discover i need to do something to an input before i assert something about it
13:09bbloomand wind up rewriting it to an assert
13:11SagiCZ1bbloom: how would i get the only element of a list? is (first '(5)) the correct way?
13:11SagiCZ1,(first '(3))
13:11clojurebot3
13:12bbloomSagiCZ1: seems like a question for the room, not for me specifically...
13:12bbloombut yes, that's fine
13:13SagiCZ1sorry about that bbloom
13:13SagiCZ1and thanks
13:31gfredericksokay so I feel like transit has to have an ambiguity on the JS side
13:32gfredericksbetween ints and floats
13:32gfredericks42 encodes to JSON as "[\"~#'\",42]", and 42.0 to "[\"~#'\",42.0]"
13:32gfredericksbut javascript's JSON parser parses those two identically
13:47schmeehow do I destructure a map with a key called `time`? It errors since `time` is also a core function
13:49hyPiRionschmee: ##(let [{t :time} {:time "foo"}] t) ?
13:49lazybot⇒ "foo"
13:49hyPiRionor do you mean the symbol `time`?
13:50hyPiRion,(let [{t 'time} {'time "foo"}] t)
13:50clojurebot"foo"
13:51gfredericks,(let [{:keys [time]} {:time "foo"}] [time time])
13:51clojurebot["foo" "foo"]
13:51bbloomschmee: it absolutely should not give that error because it does not evaluate the destructuring expression
13:51gfredericks,(let [{:syms [time]} {'time "foo"}] [time time])
13:51clojurebot["foo" "foo"]
13:51bbloomyou've got a syntax error somewhere
13:52schmeeI see, thanks!
13:52gfredericks,(let [{t time} {time :foo}] t)
13:52clojurebot#<CompilerException java.lang.RuntimeException: Can't take value of a macro: #'clojure.core/time, compiling:(NO_SOURCE_PATH:0:0)>
13:52gfredericks,(let [{t +} {+ :foo}] t)
13:52clojurebot:foo
13:52gfredericksnice
13:53dnolen_gfredericks: yes Transit doesn't address the problem of roundtripping floats, but that's way bigger issue than JS anyway
13:53dnolen_gfredericks: and for the design space - not particularly important to address
13:54bbloomit's really quite amusing how bad of a trade off floats are for most use cases :-/
13:55gfredericksdnolen_: rich seemed to say that everything roundtrips perfectly, so this surprises me
13:55dnolen_gfredericks: was likely speaking about tagged values specifically (perhaps implicitly)
13:55dnolen_so if you don't have a handler so someone's custom type, doesn't matter
13:55gfredericksgotcha
13:56gfredericksright
13:56dnolen_gfredericks: if for some reason you need to roundtrip floats you can override BigDec and deal w/ it yourself.
13:56gfredericksdnolen_: what do you mean by roundtripping floats being a big issue? something about string representations of floats in general?
13:57dnolen_gfredericks: floating point reps have problems between languages
13:57gfredericksthat's not an inherent problem is it? just divergent interpretations?
13:58dnolen_gfredericks: I already said you can solve this yourself if it's important ^
13:59gfredericksdnolen_: right, I'm just trying to understand how things work; sorry for the bother
14:00gfredericksif anybody else knows what dnolen_ meant I would be interested
14:01hyPiRiongfredericks: Well, for C/C++, it is both OS and compiler-dependent.
14:02gfrederickshyPiRion: IEEE 64-bit floating points in particular?
14:05hyPiRiongfredericks: Oh, it's about 64-bit specifically?
14:05gfrederickswell in this context we're talking about JSON, so I figured so
14:06gfredericksI guess they're not very specific about that
14:06bbloomgfredericks: floats are basically 100% broken for data interchange
14:06gfredericksbbloom: what I'm trying to understand is if that's justa coordination issue, i.e. lack of an adhered-to standard, or if it's something inherent to FP
14:07bbloomgfredericks: fundamentally, there are multiple floating point values that have the same string representation, but may produce different results when computed with
14:08bbloomeven within the same language, round-tripping to text can change is not an identity operation
14:08bblooms/can change/
14:08bbloom/
14:08gfredericksbbloom: can't you solve that with more decimal places?
14:08bbloomgfredericks: no
14:08bbloomfloats aren't encoded in decimal
14:08gfredericksor are we talking about 0/infinity edge cases?
14:08bbloomno
14:08gfredericksI know they aren't
14:08bbloomhttp://docs.oracle.com/cd/E19957-01/806-3568/ncg_goldberg.html
14:09bbloomin short: floats are a friggin mess
14:10hyPiRionBest used in banking systems if you want to maximise damage.
14:11gfredericksbased on what I know about decimal and binary numbers, I have a hard time making sense of this
14:11gfredericksif there were an example of two floats that print the same way, that'd be extremely helpful
14:12gfredericksthe set of floating point numbers (excl the weird ones) should just be a subset of the ratios
14:12gfredericksand you should be able to use decimal representations to get arbitrarily close to any given rational number
14:12hyPiRiongfredericks: +0 and -0?
14:13hyPiRionoh, that's probably a weird one.
14:13gfrederickshyPiRion: bbloom said it wasn't a 0/infinity/nan issue
14:13gfredericksyeah definitely weird
14:13bbloomgfredericks: i meant to say it's not JUST a 0/inf/nan issue
14:13gfrederickssure, either way
14:13gfredericksI'm ignoring the weird numbers for the moment since you said the normal ones have this problem too
14:15bbloomgfredericks: trying to find an article, hold on
14:16gfredericksI'm scanning through the one you already pasted
14:16bbloomsheesh, there's so many problems w/ floating point i don't even know where to start :-P
14:17gfredericksyeah I'm familiar with why they're problematic, I just didn't think they had the problem you were describing :)
14:18bbloomhttp://www.drdobbs.com/cpp/even-simple-floating-point-output-is-com/240165594
14:18hyPiRiongfredericks: they are represented on the form sign * significand * 2^(exponent - c)
14:18bbloomhttp://www.drdobbs.com/cpp/floating-point-input-and-output-are-not/240165984
14:18bbloomhttp://www.drdobbs.com/cpp/accurate-floating-point-input-several-co/240166140
14:18bbloom(the drdobbs site is atrociously difficult to navigate and for some reason breaks cmd-click in many places)
14:19gfredericksbbloom: I think this quote from your first link supports my hunch
14:19gfredericks"When a binary IEEE single precision number is converted to the closest eight digit decimal number, it is not always possible to uniquely recover the binary number from the decimal one. However, if nine decimal digits are used, then converting the decimal number to the closest binary number will recover the original floating-point number."
14:19bbloomgfredericks: if you read the rest, you'll see you that the standard printing mechanism does not have that property
14:19bbloomit tries to create "nice" looking values
14:19bbloomwhich is in line with the use cases where floats are actually valid: when accuracy doesn't matter really
14:20gfredericksbbloom: yeah, I can imagine real life serialization having ambiguities, I just didn't think decimal reps inherently had that problem
14:20bbloomgfredericks: i was talking about the *printed* reps
14:20gfredericksme too
14:20bbloomas spec'ed
14:20gfredericksthere's printing in the IEEE spec?
14:20bbloomi thought so
14:20gfredericksprobably so
14:21gfredericksso it's a spec problem then; I'm just saying it's easy enough to imagine a similar printing strategy that has no ambiguity
14:21bbloomyes, conversions to and from strings are in the spec according to wikipedia
14:21gfredericksi.e., it's not an inherent base 10 vs base 2 thing
14:21bbloomyes, but that printing strategy would produce reaaallly long decimal strings
14:22gfrederickshardly longer than the longest normal ones, no?
14:22hyPiRionuse binary, be happy
14:22gfredericks:)
14:22bbloomwell the standard string conversions include rounding, truncation, handle repeated decimals, etc
14:23bbloomif you can't reinterpret cast a float to a bit string, you can't possibly round trip it correctly without intrinsic support
14:23bbloombut the whole purpose of floats is to optimize when you don't care about losing some precision here or there
14:24gfredericksyeah; when I hear people complain about FP problems I usually assume it's related to the floating point magma
14:25gfredericksor base 2 vs base 10
14:25bbloomthey basically only make any sense during the very last stage of a pipeline
14:25gfrederickswhereas it sounds like this is the fact that rounding is in the serialization spec
14:25bbloomlike colors in a rasterization buffer :-P
14:26gfredericksbbloom: hyPiRion: thanks
14:31arrdem$seen john2x
14:31lazybotjohn2x was last seen quitting 2 hours and 49 minutes ago.
14:31arrdem:/
14:33gfredericksin any case, my original question about transit wasn't about roundtripping particular floating points, it was about even roundtripping types in the first place
14:35gfrederickse.g., if I start with a long and a double in clojure, and I send it to JS and back, I'll get two numbers of the same type
14:35bbloomgfredericks: i think numerics are a problem & i've mentioned to dnolen_ that i'd like to be able to force longs
14:35bbloomat least for js interop's sake
14:35gfredericksbbloom: yeah at worst you have to avoid the ground types
14:36bbloomi think this is a case of "now you're talking about the real problems"
14:36gfredericksthat just requires cooperation across the system, you can't fix it only in the user JS code
14:36bbloomthat is, you already had these problems w/ edn, json, etc
14:36bbloombut now that you have a tool that papers over the (retroactively) obviously broken bits, you can see the underlying issues more lcearly
14:37bbloomit's like when people hear that datomic doesn't need to touch the network to get the current database, and their first thought is "isn't the data stale then?" ... yes... but so is the data you get back from a SQL query!
14:37bbloomsame idea: once you eliminate stupid problems, the real struggles become clear... even if they are just more stupid problems :-P
14:38arrdemwill cljs allow you to perform bitwise operations on the sign bit or does it hide bit 63 like the JVM does.
14:39arrdembecause one option... albeit a shitty one, is to just write a Double -> BitString -> Double pipeline.
14:39bbloomarrdem: would defeat the performance goals....
14:39arrdembbloom: fair
14:39bbloomif you *need* exact representations: don't use floats.
14:40bbloomfull stop. with or without any network transport of any kind
14:42gfredericksbbloom: datomic analogy is a good one
14:42gfredericksbbloom: it's not exactness, it's type preservation
14:43bbloomgfredericks: if you lift a type/value tuple in to the domain of dynamic values, then you've got value exactness ;-)
14:43gfredericksyep
14:44gfredericksI'm not saying it was a bad design choice, I'm just interested in what the unadvertised edge cases are
14:45bbloomwell numerics are always a good place to go splunking for edge cases!
14:45gfrederickswhen you have a lot of clojure usage at a large company, it's useful to have somebody familiar with such things
14:46bbloompack on your door: Gary Fredricks -- Purveyor Of Fine Edge Cases
14:46bblooms/pack/plaque/ # i wasn't even close
14:46gfredericksha
14:51vdmit11Hi folks. When I define a protocol, I would like to specify pre/post conditions like I can do with functions. I would like to assert that all method implementations may assume that the input will be so and so, and they all shall return a value that follows certain constraints. Is there a way to do that?
14:52schmeeDoes anyone know how to use an Thread/UncaughtExceptionHandler in clojure?
14:53mi6x3m-altvdmit11: ehm, not that I know of, also the pre and post condition thing is seldomly used
14:53schmeeI tried adding this to the top of the file but it doesn't work for me, http://www.paullegato.com/blog/uncaught-exceptions-in-clojure/
14:53gfredericksvdmit11: defprotocol doesn't support that, but I think you can wrap the generated function via alter-var-root
14:53bbloomvdmit11: just define a wrapper functions for your protocol methods
14:53gfredericksschmee: in what way does it not work?
14:54bbloom(defprotocol P (-foo [this x y z])) (defn foo [p x y z] {:pre ...} (-foo p x y z))
14:54gfredericksI like bbloom's idea better
14:54vdmit11wrappers are boilerplate and they are not abstract
14:54vdmit11I would like to specify interface, not implementation
14:55schmeegfredericks: well, I found a bug in a future I'm using, and now I've reintroduced the bug and added that handler thingy with a print
14:55arrdemwell you can't have an interface with pre/post conditions... pre/post conditions are an implementation detail handled by the fn macro
14:55gfredericksvdmit11: I don't think you're specifying the impl in any sense
14:55schmeebut it just hangs and doesn't print anything
14:55bbloomvdmit11: clojure does not have a notion of pre/post conditions are part of interface
14:55gfredericksschmee: futures catch exceptions
14:55gfredericksschmee: you'd want to deref the future
14:56schmeeoh!
14:56bbloomvdmit11: and wrapper functions really aren't all that much boilerplate... they are frequently necessary to decouple argument handling, pre/post processing, from the service interface of the objects
14:56schmeeI'm just using the future for dispatch only, so I can't actually access the value once I've sent it off
14:56bbloomvdmit11: in general, you should be defining so few protocols that the "boilerplate" should be an essential part of the work you're doing
14:57gfredericksschmee: well it's up to you where you want to handle it I guess
14:57bbloomvdmit11: if you need *the same* boilerplate many times, then you can define a macro to generate it
14:57gfredericks,(defmacro elsewhere [& body] `(.start (Thread. (fn [] ~@body))))
14:57clojurebot#'sandbox/elsewhere
14:57schmeehmm yeah, I just want to print exceptions without wrapping my entire program in try/catch statements
14:57gfredericksschmee: ^ an alternative to future that should hit your handler
14:58schmeegfredericks: sweet, I'll try it out!
14:59schmeegfredericks: worked like a charm, thanks!
15:00vdmit11bbloom: well, I'm talking about readability when I say "boilerplate", when you see some pre/post conditions in the interface specification, you can understand better what kind of data must be passed to the method and what kind of value it returns, and you may assume that these assertions are always true and rely on these assumptions and write less code
15:00vdmit11bbloom: for me it just would be nicer to read an interface that gives some idea about inputs/outputs of a method
15:01bbloomvdmit11: protocols define java-style interfaces. that's just what they do. if you want a more powerful contractual programing mechanism, you'll have to look elsewhere or define it yourself
15:01bbloomvdmit11: i'm also telling you the community accepted approach: just define a function
15:02vdmit11ok, thanks, I just wanted to know the conventional way
15:03schmeeis there any way to list the currently running threads in the repl?
15:03bbloomvdmit11: that's the very first thing i told you :-P
15:05gfredericksschmee: http://docs.oracle.com/javase/7/docs/api/java/lang/Thread.html#getAllStackTraces%28%29
15:05gfredericks,(Thread/getAllStackTraces)
15:05clojurebot#<AccessControlException java.security.AccessControlException: access denied (java.lang.RuntimePermission getStackTrace)>
15:05gfredericksI've never tried it; looks promising
15:06gfrederickssun.misc.Unsafe.park
15:06gfredericksis apparently a popular method on my jvm
15:07schmeegfredericks: it worked great. now I just gotta prettyprint it...
15:08gfredericksw00t
15:09gfredericks,(.getStackTrace (Thread/currentThread))
15:09clojurebot#<StackTraceElement[] [Ljava.lang.StackTraceElement;@f8deca>
15:09gfredericks,(str (firsrt (.getStackTrace (Thread/currentThread))))
15:09clojurebot#<CompilerException java.lang.RuntimeException: Unable to resolve symbol: firsrt in this context, compiling:(NO_SOURCE_PATH:0:0)>
15:09gfredericks,(str (first (.getStackTrace (Thread/currentThread))))
15:09clojurebot"java.lang.Thread.getStackTrace(Thread.java:1495)"
15:10gfredericks,(str (rand-nth (.getStackTrace (Thread/currentThread))))
15:10clojurebot"clojure.core$eval74$fn__75.invoke(NO_SOURCE_FILE:0)"
15:14gfredericksI can't believe I didn't know about that...that will be super useful for when things are hung in the repl.
15:25andyfbbloom: I saw your message in the :pre/:post error message clojure-dev thread, and am wondering if I am missing something when you say "it requires non-local analysis". Do you mean it requires resolving whether the symbol number? resolves to the Var #'clojure.core/number? vs. resolving to number? in some other namespace?
15:26bbloomandyf: more simply:
15:26bbloom(def x false)
15:26bbloom(defn f [] {:post [x]})
15:26bbloom,(def x false)
15:26clojurebot#'sandbox/x
15:26bbloom,(defn f [] {:post [x]})
15:26clojurebot#'sandbox/f
15:26bbloom,(f)
15:26clojurebot{:post [false]}
15:26bbloom,(defn f [] {:post [x]} nil)
15:26clojurebot#'sandbox/f
15:26bbloom,(f)
15:26clojurebot#<AssertionError java.lang.AssertionError: Assert failed: x>
15:27bbloomandyf: does that make my comment clear?
15:28andyfEastwood can look at number?, see that it should resolve to #'clojure.core/number?, and I can bake into Eastwood that such a Var is by default a function, but it is uncomputable to determine whether its current value is a boolean or not.
15:28andyfEastwood makes best guesses at times like that, based on usual practice.
15:28bbloomandyf: right, which is why that's a good analysis for a linter, but the vector vs not vector analysis is doable in the standard defn macro, hence my patch & comment
15:29andyfok, makes sense. Thanks.
15:30bbloomgetting formal: the analysis you just described is neither sound nor complete
15:30bbloombut i'm an advocate for ignoring soundness and completeness ;-)
15:37andyfin lint tools, at least :)
15:38bbloomfor sure
15:38bbloom...at least :)
16:07augustlhow do I add a http://download.eclipse.org/jetty/stable-7/apidocs/org/eclipse/jetty/server/handler/ResourceHandler.html to my ring.adapter.jetty handler?
16:11augustlseems I can just .getHandler and go from there, in a :configurator
16:21jeremyheileraugustl: i've had to do that before; seems like the "best way" given how it's all set up.
16:28fifosine1Is it faster to consistently use tail on a sequence or to reverse it first and grab the head over and over?
16:29gfredericksfifosine1: the former
16:29gfrederickser
16:29bbloomno
16:29gfredericksunless you mean
16:29bbloomfifosine1: do you need to be able to push on to the front of the list?
16:29fifosine1no
16:29bbloomuse a vector
16:29bbloom(doc peek)
16:29clojurebot"([coll]); For a list or queue, same as first, for a vector, same as, but much more efficient than, last. If the collection is empty, returns nil."
16:30fifosine1when do I want to use sequences vs. vectors? I've structured my code so that it's only using sequences. Should I probably be using vectors?
16:31gfredericksfifosine1: you're getting the last element repeatedly?
16:31fifosine1gfredericks: Yea, recurring on the last element of a list
16:31gfredericksfifosine1: why? what sort of collection is this?
16:31fifosine1a sequences
16:32fifosine1sequence
16:32gfredericksbut why do you need the last thing? what else do you do with the sequence?
16:32andyffifosine1: Many Clojure functions produce sequences as results, regardless of the kind of collection they are given, so trying to structure your code to use vectors "everywhere" is probably impossible, and using them everywhere that you return values from functions would require converting from sequences to vectors a lot.
16:33andyfI believe many people's Clojure code uses sequences where they do not present a performance problem, e.g. they only need to access it from first to last, and vectors if they have a special need for fast random access.
16:35bbloomfifosine1: use seqs whenever you're doing stuff to the left side of the collection, or when you're walking *the entire* collection linearly
16:35bbloomfifosine1: otherwise, use vectors
16:35andyfthat is fairly generic advice, though. If you have performance problems in particular parts of your code, profiling can help find those places and other data structures might help speed up those parts.
16:35bbloomthere are other cases, of course, but that's a good rule of thumb
16:45gfredericks~gfredericks: Yes. The file name
16:45clojurebotgfredericks: Yes. The file name is the interface to implement, and the content is a newline-separated list of the names of the concrete implementations
16:46gfredericks~sadness and spaghetti
16:46clojurebot<amalloy> weeping willows with cold pasta draped over their limbs, marinara sauce dripping forlornly to the ground, silent splats nobody can hear
16:47gfredericksclojurebot picks up the weirdest things by accident
16:47gfredericks~tutysara: sorry, not sure what
16:47clojurebottutysara: sorry, not sure what is up, I'm getting the same thing. May take me some time to figure out and I can't do so now--I'll put something in github issues and update it ASAP.
16:47hyPiRionby accident?
16:48hyPiRionoh right, like the random "this is to me" messages it reads
16:48gfredericksexactly
16:48gfrederickslynaghk: map unification
16:48gfredericks~lynaghk: map unification
16:48clojurebotlynaghk: map unification is quite simple - it should be easy to see how it should be changed to do what you want for this new type.
16:49gfredericks~tbaldridge: this
16:49clojurebottbaldridge: this is why I think tick maybe an OK compromise, allow work to be done in the natural order, pick a respectable granularity, yield for timeout
16:50gfredericksokay last one
16:50sveriHi, using compojure is there a way to get the request variable and some destructured post variables like this: (POST "/uri" [param1 param2] req (index param1 param2 req))?
16:50gfredericks~arrdem: There
16:50clojurebotarrdem: There is a refheap API call to edit a paste. I'd happily take a pull request to add this functionality in refheap.el.
16:51jeremyheilersveri: (POST "/uri" [param1 param2 & req] ...)
16:52jeremyheilerooops
16:52jeremyheilersveri: (POST "/uri" [p1 p2 :as req] ...)
16:52jeremyheilersveri: https://github.com/weavejester/compojure/wiki/Destructuring-Syntax
16:52tbaldridge~gfredericks: what the?
16:52clojurebotNo entiendo
16:53tbaldridge~gfredericks: this
16:53clojurebotTitim gan éirí ort.
16:55sverijeremyheiler: thank you, didn't see that one
16:55jeremyheilersveri: np!
16:55gfrederickstbaldridge: :P
16:57gfredericks~b: ,
16:57clojurebotb: , is white space
16:58SagiCZ1~SagiCZ1
16:58clojurebotExcuse me?
17:00arrdemwhat the heck..
17:03lxsameerhey guys, does any one uses emacs + cider ?
17:05caternnope
17:05augustllxsameer: don't ask to ask, just ask :)
17:05caterneveryone here uses Eclipse
17:05lxsameeraugustl: ok then
17:05arrdemcatern lies like a dog
17:05catern:D
17:06arrdemlxsameer: the last estimate I saw is that Emacs+{Cider,Slime} and Vim+Fireplace is ~75% of Clojure hackers
17:07lxsameerarrdem: really ? I'm new to clojure or any JVM lang, but as far as I see most of jvm related people use Eclipse
17:07caternlxsameer: I was joking
17:07caternI use Emacs+cider
17:07augustllxsameer: in my experience most jvm peeps use intellij
17:07arrdemlxsameer: depends on how much Java interop you're having to do... if you're using Clojure to wrap a huge Java app of course you'll do better with a strong Java IDE
17:08arrdemlxsameer: if you're just handling a boatload of Clojure code, then the other tools do it better
17:08caterni personally hate Java and wouldn't be caught dead using an IDE
17:08catern(someone reaaaaaaaaally needs to write a guide to Java for Clojure programmers)
17:08gfredericksI thought of that back in the day and then I promptly didn't do it
17:10technomancya time-honored tradition
17:12lxsameercatern: cool, I setup up cider with clojure mode but i get this error opening a clojure file http://dpaste.com/3G9CCGF do know about it ?
17:12lxsameerarrdem: thanks
17:12caternlxsameer: have you enabled the cider-nrepl lein plugin?
17:12lxsameercatern: yeah I added it to ~/.lein
17:13caternspeaking of configuring leiningen... it really should obey the XDG-hierarchy and put its config under .config/leiningen/
17:14lxsameercatern: really ? but mine is in ~/.lein, and I'm installed lein using the conventional way
17:15lxsameercatern: how can I make sure that leiningen used my conf files ?
17:15caternoh no
17:15caterni was just saying
17:15caternin general
17:16caterntotally not specific to you
17:21arrdemtbaldridge: has Bronsa done two or three years of GSoC now?
17:21arrdemI forget
17:22tbaldridge2 afaik
17:22tbaldridgelast year was clojure-in-clojure which resulted in tools.analyzer
17:23arrdemkk
19:07sdegutisWhat's a good way to name a library?
19:20caternUUIDs
19:22sdegutisWell played sir-or-madam.
19:22AeroNotixsdegutis: I usually just use http://online-generator.com/name-generator/project-name-generator.php
19:22sdegutisThanks.
19:23sdegutisI'll try doing the whole metaphor thing that the Ruby people do.
19:23sdegutisAha! "Computer Program."
19:23sdegutisOh wait.
19:23AeroNotixsdegutis: meta
19:23AeroNotixwhat does the program do?
19:23sdegutisAeroNotix: I'm sure that's taken.
19:23sdegutisAeroNotix: Oh it like, well...
19:23sdegutisI don't know.
19:23sdegutisIt's cool though.
19:24gfixlersdegutis: I named a tool like that once. I called it "MultiTool"
19:24AeroNotixunknownjure
19:24sdegutisLOL got "Metaphor Essential" from http://online-generator.com/name-generator/project-name-generator.php
19:24gfixlersdegutis: then I was going to rename it later; I never did
19:24sdegutisgfixler: Perfect!
19:24sdegutisgfixler: Ah nope, trademarked: http://www.trademarkia.com/trademarks-search.aspx?tn=multitool
19:24AeroNotixsdegutis: I just got "disappointed toothbrush"
19:24gfixlersdegutis: MultipleTool!
19:25gfixlersdegutis: SoManyTool!
19:25sdegutisAh nice call.
19:25sdegutisYes that last one works great. Thanks!
19:25sdegutisI'll rename my app to that. Thanks!
19:25gfixlerWowSuchUtil
19:25sdegutisEven better.
19:26sdegutisThis is my app btw http://hackhydra.com/
19:26sdegutisGo buy some of it.
19:26AeroNotixI don't own an iProduct
19:26gfixleriDontEither
19:26AeroNotixWho would? Chumps
19:27gfixlerI have gridding in Ubuntu
19:27gfixlerc/o Compiz
19:27gfixleralthough I'm really looking into this xmonad thing now
19:27AeroNotixgfixler: I use xmonad -- wanted to use stumpwm
19:27AeroNotixbut stumpwm shares groups across screens
19:27AeroNotixso individual screens don't have individual groups, kind of annoying
19:27AeroNotixapparently it can be hacked around
19:28gfixlerAeroNotix: you use stumpwm with xmonad?
19:28gfixleror xmonad in place of stumpwm
19:28AeroNotixgfixler: no, stumpwm and xmonad are separate window managers
19:28gfixlerright, that's why I was confused :)
19:28gfixlerI parsed wrong
19:29AeroNotixxmonad is fine, really. I just really like Lisp and the idea of being able to hack on my WM from emacs and have it evaluated straight away
19:29gfixlerI'm learning Haskell, slowly but surely, and I want power over my wm
19:29AeroNotixHaskell doesn't interest me
19:29gfixlerwhoa, that's what stumpwm does?
19:29AeroNotixYeah, it's a CL process you can connect to
19:30AeroNotixso you just use SLIME like you would any other CL process
19:30gfixlersuddenly stumpwm has become interesting
19:30AeroNotixit's great if you don't mind the way it handles groups
19:30gfixlerby 'screens' do you mean monitors?
19:30AeroNotixhighly recommend
19:30AeroNotixyeah
19:31gfixlerbtw, thanks for the answer like 10 hours ago re: (take)
19:31AeroNotixgfixler: no wakkas
19:31gfixlerthat was locking up on me, but it turns out I was passing it a vector of infinite expressions
19:31gfixlerthey needed to be separate things to map
19:31AeroNotixgotcha
19:31gfixlerobvious, now that it's not 4AM
19:31AeroNotix:)
19:31gfixlerman, now I don't know which wm I like more
19:32caterni've never tried stumpwm
19:32AeroNotixI'd definitely give stumpwm a go
19:32gfixlerHaskell is super interesting to me, but CL is really awesome, too
19:32caternbut AeroNotix has made me interested in CL
19:32AeroNotixcatern: every lisper should try CL out :)
19:32AeroNotixit's the most "mature" of the lisps I've used
19:32caterni've never actually used CL, just scheme and clojure
19:32gfixlerI made it halfway through PCL, and I like CL quite a bit
19:32gfixleralthough I prefer Lisp-1s now
19:32AeroNotixgfixler: PCL is a great book :)
19:32caternit appears enterprisey
19:33AeroNotixcatern: enterprisey lisp, good one :)
19:33gfixlerAeroNotix: I only stopped because it was turning into giant projects
19:33AeroNotixgfixler: lisp1 > lisp2
19:33gfixlerI'd like to revisit them at some point
19:33sdegutiswelp
19:33caternAeroNotix: inasmuch as that's possible
19:33gfixlerwe made sdegutis sad
19:34AeroNotixcatern: it's definitely a large lisp
19:34gfixlerAeroNotix: is it, or do you think it's possible to have a window over top of a window in stump or xmonad?
19:34AeroNotixand it suffers its "design by committee" roots
19:35AeroNotixgfixler: floating windows are possible in both
19:35gfixlercatern: CL has crazy names for everything
19:35arrdemeh.. the Lisp2 argument that "well a bunch of the good names are needed for functions, and locals vs. globals isn't obvious" does make sense to some extent
19:36AeroNotixdisagree wholeheartedly, but whatevs, it is what it is
19:36caterni actually prefer shared-workspaces-between-monitors to independent-set-of-workspaces-per-monitor
19:36caternso it sounds good
19:36arrdemyou just need an editor that can interface with the analyzer and highlight locals and globals differently :P
19:36scottjgfixler: you can have windows over top of windows in several ways in stumpwm. one is a workspace that's all floating windows. another is multiple windows in the same tiling frame, where one window is limited size like maybe a dialog or a movie window with a different ratio. another way is if you have one window fullscreen, like a video, you can have windows in tiled frames appear over the top of it.
19:36AeroNotixcatern: you caveman1
19:36AeroNotix!
19:36catern(er, assuming you can mix workspaces)
19:36AeroNotixcatern: wdym mix workspaces?
19:37caternAeroNotix: nonsense! it's powerful to be able to move my emacs and terminal workspace to my large monitor or to my small monitor
19:37caternAeroNotix: like, i can independently choose workspaces for the two monitors. the workspace doesn't span across both monitors
19:37AeroNotixcatern: exactly -- stumpwm doesn't do this
19:37AeroNotixand I want that behaviour
19:37caternwhat does it do?
19:38caternone big workspace covering both monitors?
19:38AeroNotixexactly
19:38caternaw, lame
19:38AeroNotixyeah, biggest killer for me
19:38AeroNotixI spent all weekend setting it up getting nerdily exicited (single monitor at home)
19:38AeroNotixgot to my multi monitor setup at work and then had a sad
19:38caternhack it yo
19:39AeroNotixX code (even in lisp) makes me puke
19:39gfixlerAeroNotix: yeah, that's lame
19:39caternhuh, surely it's plenty abstracted already
19:39AeroNotixapparently if stumpwm isn't in xinerama mode then it works with separate groups
19:40scottjcatern: not really (having viewed my fair share of stumpwm code)
19:40catern(if clojure wasn't hosted on the jvm we could have a clojure TWM)
19:40gfixlerAeroNotix and scottj - I meant that I'd like to have 2 fullscreen windows with the front one a bit transparent
19:40AeroNotixcatern: there's no reason why not -- I assume you mean the long startup time/
19:40scottjgfixler: I think you could do that fine
19:40gfixlere.g. I've had code fullscreened over Autodesk Maya, sending commands through from Vim, and watching things change in the 3D scene
19:41gfixlerscottj: transparency levels is a thing?
19:41caternAeroNotix: it just feels wrong to have to boot up a memory-huge JVM just for my window manager
19:41AeroNotixcatern: I agree
19:43scottjgfixler: handled by compositor like compton, not window manager.
19:43caternnot for long!
19:43catern(wayland)
19:44catern(and that separation is dead in all the DEs anyway)
19:44gfixlerscottj: understood - I am a newb in the field of window layout
19:45gfixlerDE, WM, compositor... these are just words, really
19:46gfixlerCompiz has logical monitors, which I've needed, as I use the Matrox GoofyName TripleHead2Go Digital Edition
19:46gfixleri.e. I have one DVI cable from the card to the Matrox box, and 3 from there to each of my 19" screens
19:46gfixlerthe computer sees one, 4' wide monitor
19:47gfixlerso fullscreen and maximize do their thing across all displays
19:47gfixlerI wrangle that with Compiz's "Outputs"
19:47gfixleri.e. with geo strings - 0x0+0+0
19:48gfixlerbut with something like xmonad, I think I could make all manner of splits and such
19:49gfixlerI'm curious about nesting of logical things - like could I split the 1 group into 3 parts, and then sub-split those in a useful way
19:51AeroNotixgfixler: just try it out
19:51AeroNotixit's easier to see what's possible when you use it
19:52gfixlerAh, the old "Dive Into X" approach
19:59caternhmm
20:25justin_smithgfixler: I've run into issues with some wms and not others, in my experience xmonad and i3 are better behaved than most
20:26justin_smithgfixler: what made me stick with i3 is the fact that when a monitor disappears, it doesn't reshuffle windows that were on that monitor, the "frame" of things that was on that monitor is just detached (and then attachable to any other monitor but configured as it was before in terms of window placement within the monitor)
22:06myguidingstarHi all, I'm doing TDD with cljx but cljsbuild tends to compile before cljx finishes
22:07myguidingstaras a result, the final javascript is a mix of old and new clojure(script) source
22:09myguidingstarI mean I run "cljbuild auto" and "cljx auto" at the same time
23:16allenj12_is anyone here familiar with overtone?