2016-01-01
| 00:03 | ben_vulpes | i mean it's way at the bottom. |
| 00:03 | ben_vulpes | in the doc string for let, huh? |
| 00:03 | justin_smith | ben_vulpes: I know it's weird but I go around reading docs for things even though I think I already know them |
| 00:04 | justin_smith | kind of like how some people read cereal boxes |
| 00:04 | ben_vulpes | interestingly, it's in there for clj, but not cljs |
| 00:04 | ben_vulpes | not that i'm going to blame that for my missing it. |
| 00:04 | justin_smith | oh, that's odd |
| 00:05 | ben_vulpes | i'm much more inclined to pull the docs up now that i have cider all wired together |
| 00:09 | justin_smith | ,0x1bad1dea |
| 00:09 | clojurebot | 464330218 |
| 00:09 | kenrestivo | what's a bad idea about the docs? |
| 00:09 | kenrestivo | docs are awesome |
| 00:10 | justin_smith | nothing, I just randomly wanted to see what number that was, totally unrelated |
| 00:10 | kenrestivo | (inc docs) |
| 00:10 | amalloy | ,0xcafebabe |
| 00:10 | clojurebot | 3405691582 |
| 00:10 | kenrestivo | ,inc docs |
| 00:10 | clojurebot | #object[clojure.core$inc 0x2478afba "clojure.core$inc@2478afba"] |
| 00:10 | kenrestivo | ~inc docs |
| 00:10 | clojurebot | Huh? |
| 00:10 | kenrestivo | whatever, whichevver bot keeps the karma, and however it does it, that. |
| 00:11 | justin_smith | ,(- 0xdeadbeef 0x1bad1dea) |
| 00:11 | clojurebot | 3271598341 |
| 01:16 | justin_smith | ,(.toString (BigInteger. "3824053620879447910461354") 36) |
| 01:16 | clojurebot | "happynewyear2016" |
| 02:02 | TEttinger | ,(.toString 3824053620879447910461354N 36) |
| 02:02 | clojurebot | #error {\n :cause "No matching method found: toString for class clojure.lang.BigInt"\n :via\n [{:type java.lang.IllegalArgumentException\n :message "No matching method found: toString for class clojure.lang.BigInt"\n :at [clojure.lang.Reflector invokeMatchingMethod "Reflector.java" 53]}]\n :trace\n [[clojure.lang.Reflector invokeMatchingMethod "Reflector.java" 53]\n [clojure.lang.Reflector in... |
| 02:02 | TEttinger | damn! |
| 02:02 | TEttinger | int and integer |
| 02:03 | ikfb_ | I stduy clojure on braveclojure.com. Here is a str (swap! fred increase-cuddle-hunger-level 10) but the author said swap! need two args . It passed three ! |
| 02:03 | TEttinger | swap! needs at least two args, it passes the rest to the fn |
| 02:03 | tolstoy | Is that tutorial written by Aphyr? |
| 02:03 | TEttinger | ,(def adam (atom 0)) |
| 02:03 | clojurebot | #'sandbox/adam |
| 02:03 | TEttinger | ,(swap! adam inc) |
| 02:04 | clojurebot | 1 |
| 02:04 | TEttinger | ,(swap! adam + 1) |
| 02:04 | clojurebot | 2 |
| 02:04 | TEttinger | ,(swap! adam + 3 3 3) |
| 02:04 | clojurebot | 11 |
| 02:04 | ikfb_ | I see |
| 02:05 | ikfb_ | func is first class . pass like a var . but action like fun |
| 02:09 | tolstoy | swap takes an atom a function and any args. Kinda like (reset! atom (apply f @atom args)). |
| 02:14 | ikfb_ | I have a question. swap mean exchange. the meaning show only update atom value . where is old value , it can't give to a func i think. |
| 02:16 | tolstoy | The function you have to swap takes the old value and returns a new value to be stored on the atom. |
| 02:16 | tolstoy | (swap! atom (fn [old-value] (+ old-value 10))) |
| 02:18 | tolstoy | s/have/give/ |
| 02:19 | tolstoy | If you want the old value, you just deref the atom. |
| 02:20 | tolstoy | (let [old-val @atom] (swap! atom #(+ % 10))) |
| 02:20 | tolstoy | the swap! function itself returns the new value when the function is applied. |
| 04:46 | ikfb_ | Hi I translate https://bpaste.net/show/d9540131efbf to in python https://bpaste.net/show/6662ba8eec39 about 1 minute. When I want implement by clojure. ( First I should directly translate Then I use clojure's idea method to replace it) But I meet simple problem. Which var should be use atom or rel ? |
| 06:59 | ikfb_ | /msg NickServ identify nickjiamo |
| 07:10 | ishake-u | hi |
| 07:10 | ishake-u | which country is this channel |
| 07:13 | beaky | hello |
| 07:30 | ikfb_ | Ok find a website compare python and clojure on some syntax, http://jkkramer.com/sudoku.html |
| 08:32 | engblom | ikfb_: Somehow I find that site biased towards making Python look more simple. They seem to pick a more complicated way for Clojure, like (def digits (set (range 1 10))) for clojure and digits = '123456789 for Python |
| 08:37 | ikfb_ | New to clojure. While the generally language something like equal turling. Every one have its best idiom to describe somethings. I am familiar python (more or less) I wish I can have some resource to see a complicated problem by clojure and python. (May be there have different domain) |
| 08:41 | AimHere | Rosetta Stone is a good resource for that sort of thing |
| 08:41 | AimHere | Rosetta Code |
| 08:41 | AimHere | http://rosettacode.org/wiki/Rosetta_Code |
| 08:42 | AimHere | It's a website with a series of programming tasks, and the code for it in *lots* of languages |
| 08:44 | AimHere | Whether the code for any given tasks is idiomatic clojure (or idiomatic python), I'll leave as an exercise for you to guess |
| 08:45 | ikfb_ | thanks. I find a guys in 4clojure for last or list like : (reduce #(-> %2) [1 2 3 4]) and python may be a[-1] |
| 08:45 | AimHere | Well clojure has 'last' built-in. |
| 08:46 | AimHere | Some of the 4clojure exercises are to replicate clojure builtins without using them |
| 08:46 | AimHere | ,(last [1 2 3 4 5]) |
| 08:46 | clojurebot | 5 |
| 08:46 | AimHere | So when they have those sorts of constraints, they'll clearly not be idiomatic |
| 08:51 | ikfb_ | Hi Aimhere . http://rosettacode.org/ is really what I want to see now. Wish more clojure programmer give their beautiful code on it. This may attract new people. |
| 08:51 | ikfb_ | People will see which language is their taste. |
| 09:43 | irctc | Hi |
| 13:04 | Frozenlock | clojars is down again :-( |
| 13:47 | ZimaBlue | YEAH! |
| 13:48 | ZimaBlue | clojars IS down!! Is this an ongoing problem? |
| 13:48 | ZimaBlue | I'm trying to set up a new laptop/workstation and thought I'd just done something wrong -_- |
| 13:51 | gfredericks | ZimaBlue: linode keeps getting DOS'd, which affects clojars since it's hosted there |
| 13:55 | justin_smith | sounds like it's time for redundancy |
| 13:55 | ZimaBlue | that sucks :( is there a workaround to get leiningen up and running? |
| 13:56 | justin_smith | ZimaBlue: if you need a specific package, you can check out from github and run lein install |
| 13:56 | gfredericks | if toby hasn't gotten alex to give him some control over dns at least then I'm not sure how to get that redundancy working |
| 13:56 | gfredericks | unless we wanna all switch to clojars2.org |
| 13:56 | justin_smith | but if you need to bootstrap a whole lein install... maybe you can copy your ~/.m2/ from another machine? |
| 13:58 | gfredericks | I'm Gary Fredericks And I Wish Clojars Was Up.™©☺® |
| 14:01 | amalloy | we should all just share one network-mounted .m2 |
| 14:02 | amalloy | put it someplace central |
| 14:02 | justin_smith | :) |
| 14:02 | amalloy | what would we call our central maven? |
| 14:02 | amalloy | (happy 2016) |
| 14:03 | justin_smith | gfredericks: well, instead of switching to clojars2.org, we could just ensure that clojars2, clojars3, clojars4 all exist and stay synced with clojars, and then add them all to the default repos |
| 14:04 | justin_smith | and separate orgs could sponsor mirrors, especially if there was a turnkey "run this jar to run a clojars mirror" download |
| 14:04 | justin_smith | the failover checking already exists in the maven logic |
| 14:07 | gfredericks | this reminds me that my server log says I've been getting requests for nonexistent subdomains of googlegooglegooglegooglegoogle.com |
| 14:07 | gfredericks | and I'm curious how that happens |
| 14:07 | justin_smith | gfredericks: the server log on googlegooglegooglegooglegoogle.com which you own, or the logs on some other server? |
| 14:08 | gfredericks | the former |
| 14:08 | gfredericks | in particular I've logged 2 requests to each of ww{38,41}.googlegooglegooglegooglegoogle.com, and 12 requests to ww1.googlegooglegooglegooglegoogle.com |
| 14:09 | amalloy | the least sophisticated port-scanning of all time |
| 14:10 | justin_smith | hell, I get requests for domains that aren't even subdomains http://24x7-allrequestsallowed.com/?PHPSESSID=aab45f4f00143PRWJTUGYC%40_JESX HTTP/1.1" - they are trying to see if I am running a proxy, basically |
| 14:10 | gfredericks | I've gotten 2 requests for www.baidu.com |
| 14:10 | justin_smith | I get a lot of those |
| 14:11 | justin_smith | gfredericks: if it was wwwwwwwwwwwwwww.googlegooglegooglegooglegoogle.com that they sent a request to, I would congratulate them for their wit |
| 14:11 | gfredericks | I should put something special there |
| 14:12 | justin_smith | gfredericks: you could blatantly copy the behavior of "telnet skelnet.club" |
| 14:13 | gfredericks | ha |
| 14:13 | justin_smith | gfredericks: what amazes me is that they made a recognizable ascii version of that dude at that resolution |
| 14:13 | justin_smith | I mean I know *exactly* the gif they are quoting |
| 14:13 | gfredericks | I don't know who that dude is |
| 14:14 | gfredericks | I only had two gif classes in college |
| 14:14 | gfredericks | never even made it to the end of that big textbook |
| 14:14 | justin_smith | oh wait never mind, not that one |
| 14:15 | justin_smith | false memory syndrome strikes again |
| 14:17 | justin_smith | gfredericks: I was thinking of this guy, but the costume is wrong https://nicoladallasen.files.wordpress.com/2014/09/tumblr_ncqys2nrbb1qe8i7ko7_r1_250.gif |
| 14:17 | gfredericks | oh I'm familiar with that guy actually |
| 14:18 | gfredericks | a coworker once took it upon himself to play that on his auxiliary monitor for the entire month of October or something |
| 14:19 | gfredericks | http://status.linode.com/ |
| 14:20 | gfredericks | I used to run my primary personal server in linode atlanta, which made these outages a lot more annoying |
| 14:21 | justin_smith | gfredericks: does linode allow serving one site from multiple regions? |
| 14:21 | gfredericks | "ugh, my server's down; fine I'll just develop this clojure code locally. ugh, clojars is down; fine, I'll just" |
| 14:21 | gfredericks | justin_smith: can you do that purely with DNS? |
| 14:21 | justin_smith | dunno |
| 14:22 | amalloy | i hope to someday learn that dns is turing complete |
| 14:23 | justin_smith | gfredericks: I mean there's the low tech way of having a backup server and propagating a new dns to point to that one when the other one goes down - but there are fancier things out there too (that linode might not support) |
| 14:40 | gfredericks | I meant having one domain name point to several IPs |
| 14:40 | gfredericks | e.g., `dig google.com` lists 11 or so |
| 14:42 | justin_smith | gfredericks: I only know so much about this stuff, seems like it should be doable |
| 14:43 | gfredericks | ~this |could be due| to a typo in :dependencies or network issues. |
| 14:43 | clojurebot | c'est bon! |
| 14:43 | gfredericks | ~this |
| 14:43 | clojurebot | this is not allegro |
| 14:43 | gfredericks | ~this |
| 14:43 | clojurebot | this is an outrage! |
| 14:43 | gfredericks | ~this |
| 14:43 | clojurebot | this has been another episode of gfredericks in wonderland |
| 14:44 | amalloy | truer than you know, clojurebot |
| 14:44 | gfredericks | ~that |
| 14:44 | gfredericks | ~what |
| 14:44 | amalloy | gfredericks banned from clojurebot for spamming |
| 14:44 | gfredericks | ~it |
| 14:45 | gfredericks | consarnit |
| 14:45 | gfredericks | that's never happened before |
| 14:45 | clojurebot | that is pretty cool |
| 14:54 | ZimaBlue | thanks for the .m2 advice btw it worked |
| 15:03 | rhg135 | I don't like 'em script kiddies attacking servers. By now it's not serving a purpose. |
| 15:38 | lokien | How to use "and" on a vector? I have a vector of booleans |
| 15:39 | luma | (every? true? v) |
| 15:40 | lokien | what about "or"? |
| 15:41 | luma | (some true? v) |
| 15:41 | lokien | ohh, I tried to use some?, that's why it didn't work |
| 15:41 | lokien | thanks |
| 15:41 | luma | (some? x) is (not (nil? x)) |
| 15:42 | lokien | not-empty? would be a better name, in my opinion |
| 15:42 | lokien | oh, it can be empty |
| 15:43 | lokien | never mind |
| 15:43 | lokien | ,(some? []) |
| 15:43 | clojurebot | true |
| 16:04 | danielglauser | Is clojars down for other folks? Can't pull up the web interface and I'm having trouble pulling down deps too. |
| 16:06 | featheredtoast | danielglauser: yeah, down for me currently too :( |
| 16:08 | danielglauser | I wonder if there's someone we should ping to be nice. |
| 16:09 | TEttinger | danielglauser: linode is still being DDoSed |
| 16:09 | TEttinger | at least that's what I gathered |
| 16:09 | featheredtoast | that'd do it then |
| 16:09 | danielglauser | TEttinger: Ah...that makes sense. Didn't know about that. |
| 16:10 | danielglauser | Curious, any idea why it's being DDoSed? |
| 16:10 | TEttinger | https://twitter.com/clojars |
| 16:10 | danielglauser | Sweet, didn't know about that. Thanks! |
| 16:11 | danielglauser | Luckily I'm able to build the deps I'm looking for from source. |
| 16:16 | TEttinger | https://twitter.com/jonknee/status/682974714935947266 |
| 16:21 | TEttinger | I wonder how big clojars is |
| 16:34 | benjyz1 | clojars.org is down? |
| 16:34 | benjyz1 | http://downforeveryoneorjustme.com/clojars.org |
| 16:35 | MJB47 | may i suggest updating the topic? |
| 16:37 | Trioxin | finally 1 clojure course makes it onto lynda |
| 16:44 | jonathanj | can i map with an xform? |
| 16:44 | archimedespi | lol, yeah, might want to just add "CLOJARS IS DOWN SINCE LINODE IS UNDER DDOS" to the beginning of the topic :) |
| 16:44 | jonathanj | like (let [xf (comp (map get-foo) (filter bar?)) objs (map xf things)]) |
| 16:47 | jonathanj | i guess maybe that's just (sequence xf things) |
| 17:03 | kenrestivo | yikes, linode got piled on? yuck. |
| 17:06 | mr- | It might just be back (for now..) |
| 17:10 | archimedespi | it's been going up and down, linode is playing whack-a-mole with their various regions |
| 17:20 | kenrestivo | the couple client linodes i checked seem to be up |
| 17:27 | gfredericks | justin_smith: who is the photo of? |
| 17:27 | justin_smith | gfredericks: the man who famously rejected resolution in music |
| 17:28 | justin_smith | Arnold Shoenberg |
| 17:28 | justin_smith | (father of serialism, which rejects melodic movement, harmony, melody, etc.) |
| 17:29 | gfredericks | TIL |
| 17:29 | gfredericks | so he didn't want music to have any music in it |
| 17:30 | justin_smith | *schoenberg ftfm https://www.youtube.com/watch?v=A-fyWc6Mpd8 |
| 17:31 | justin_smith | gfredericks: he claimed (right or wrong) music was possible without those things |
| 17:31 | justin_smith | above link is a good example |
| 17:33 | justin_smith | gfredericks: anyway pun on new years resolution etc. etc. |
| 17:40 | gfredericks | right right |
| 17:41 | justin_smith | gfredericks: music theory has some wild fringes - I knew a guy ages ago who developed scales based on sets of frequencies that were all relatively prime (ensuring that no audible harmonics would line up between any two notes in the scale) |
| 17:44 | justin_smith | gfredericks: I'd compare schoenberg in music to the expressionists in painting - still very traditional in many ways, derived quite logically (all to logically) from the preceding craft, but crucially rejecting the expectation that the result be beautiful (at least by preceding standards) |
| 17:45 | gfredericks | music is a series of developments that were each the dennis rodman of the previous development |
| 17:45 | justin_smith | heh |
| 17:48 | justin_smith | gfredericks is the dennis rodman of declaring things are dennis rodmans of things |
| 18:01 | gfredericks | of course the main problem in this area is to figure out what michael jordan is the dennis rodman of |
| 18:09 | randomcharhere | good reference for beginning programing in clojure? |
| 18:09 | justin_smith | randomcharhere: if you literally mean a reference sheet, check out http://conj.io |
| 18:10 | randomcharhere | probaly bad choice of words not looking for a list of clojure cammonds more on basics of programming clojure |
| 18:11 | randomcharhere | most book/website been more of a list of commands and not about how to program in clojure |
| 18:12 | daph | randomcharhere: Have you tried Clojure for the Brave and True? http://www.braveclojure.com/ |
| 18:12 | justin_smith | randomcharhere: there are a few good intros online- clojure for the brave and true and clojure from the ground up are two good examples |
| 18:14 | randomcharhere | already got repl installed and have a really basic understanding of clojure |
| 18:16 | randomcharhere | http://www.braveclojure.com/ have to check out. What I'm looking for is more programing by example starting simple and getting more complicated |
| 18:17 | randomcharhere | most of what I've found is more along he lines of a list of commands and descriptions kinda like learning a languauge reading a dictioanry ... |
| 19:53 | justin_smith | ,\ಾ |
| 19:53 | clojurebot | \ಾ |
| 19:53 | rhg135 | yay for unicode! |
| 19:53 | pontiki | what is happening? netsplit? |
| 19:54 | rhg135 | doesn't seem so |
| 19:55 | rhg135 | usually it would say in the quit message |
| 20:17 | cal | anyone here familiar with joplin? every command i run i get a message says that the migrations table already exists. |
| 20:54 | tcrawley | gfredericks: justin_smith: I've been giving some thought today on what it would take to have a turnkey clojars mirror. I'm writing up my thoughts now, and will post to the clojars-maintainers list tonight |
| 20:54 | tcrawley | if'n y'all want to contribute to the discussion |
| 20:55 | gfredericks | tcrawley: cool |
| 21:00 | zerokarmaleft | danielglauser: https://twitter.com/clojars/status/683010552608722944 |
| 21:00 | zerokarmaleft | oops |
| 21:01 | tcrawley | I think you just earned some karma back! |
| 21:27 | justin_smith | tcrawley: awesome! |
| 21:45 | gfredericks | I wonder if linode achieved two 9's of uptime in 2015 |
| 21:50 | daph | two nines gives them a yearly downtime of 3 days and 15 hours. Depending on how you define 'downtime', they could still good on two nines, since it seems like some of their DCs have remained un-attacked. |
| 22:57 | justin_smith | daph: but clojars specifically, hosted on linode, has had 10 hrs down just today |
| 22:57 | tcrawley | clojars is up at the moment. get your deps while they are hot |
| 23:07 | daph | justin_smith: true, I'm not debating that |
| 23:51 | kenrestivo | for i in `find . -type d`; do (cd $i; lein check); done |