« Back to channel list

#ruby - 06 June 2016

« Back 1 day Forward 1 day »
[00:00:22] RobertBirnie: has joined #ruby
[00:00:36] palms: has joined #ruby
[00:00:41] nankyokusei: has joined #ruby
[00:01:01] roamingdog: has joined #ruby
[00:10:37] benlieb: has joined #ruby
[00:11:29] hutch34: has joined #ruby
[00:11:58] crystal77: has joined #ruby
[00:12:08] djbkd: has joined #ruby
[00:13:01] CJKinni: has joined #ruby
[00:13:18] benlieb: Is there a way to use ruby-install to install 2.3.1?
[00:14:15] bmorrison: has joined #ruby
[00:16:27] vikaton: has joined #ruby
[00:17:41] LoneHerm_: has joined #ruby
[00:19:08] DTZUBDUB: has joined #ruby
[00:20:01] MrBusiness2: has joined #ruby
[00:21:42] devbug: has joined #ruby
[00:24:00] smathy: has joined #ruby
[00:24:22] lightt: has joined #ruby
[00:24:55] speakingcode: has joined #ruby
[00:25:42] domgetter: What is ruby-install?
[00:26:02] roamingdog: has joined #ruby
[00:26:29] sumobob: has joined #ruby
[00:27:13] N1njturt1e: has joined #ruby
[00:27:56] aupadhye: has joined #ruby
[00:28:51] al2o3-cr: https://github.com/postmodern/ruby-install
[00:29:42] LoneHermit: has joined #ruby
[00:29:48] freerobby: has joined #ruby
[00:34:06] jerematic: has joined #ruby
[00:35:37] MrSamuel: has joined #ruby
[00:35:45] MrSamuel: is `unsigned x = -1` undefined?
[00:35:53] MrSamuel: oh lol wrong channel
[00:37:31] A124: has joined #ruby
[00:37:36] deviation: has joined #ruby
[00:38:12] Kus: has joined #ruby
[00:39:54] jancel: has joined #ruby
[00:41:33] maletor3: has joined #ruby
[00:42:07] Vingador: has joined #ruby
[00:45:09] crystal77: has joined #ruby
[00:48:45] Macabre: has joined #ruby
[00:55:37] charliesome: has joined #ruby
[00:56:27] duckpuppy: has joined #ruby
[00:58:19] weaksauce: has joined #ruby
[00:59:05] Ropeney: has joined #ruby
[01:00:18] rkazak: has joined #ruby
[01:06:01] crystal77: has joined #ruby
[01:09:14] nofxx: has joined #ruby
[01:10:12] Stazer: has joined #ruby
[01:11:14] CloCkWeRX: has joined #ruby
[01:12:46] djbkd: has joined #ruby
[01:14:03] CJKinni: has joined #ruby
[01:14:08] tatsuo: has joined #ruby
[01:19:54] MrSamuel: has joined #ruby
[01:20:01] weemsledeux: has joined #ruby
[01:21:20] Eeinx: has joined #ruby
[01:21:29] Channel6: has joined #ruby
[01:22:52] araujo__: has joined #ruby
[01:23:09] Alazoral: has joined #ruby
[01:28:46] wolffles: hey there guys im trying to use a craiglist bulk poster i found on github but im having trouble making it work.
[01:28:57] wolffles: is there anyone able to walk me through this?
[01:29:56] wolffles: this is the page https://github.com/boyhavoc/craigs_gem_pub
[01:31:02] domgetter: wolffles are you having trouble getting it installed, or are you having trouble getting it to post?
[01:31:09] araujo_: has joined #ruby
[01:31:21] wolffles: getting it to post
[01:32:05] nofxx: has joined #ruby
[01:32:05] nofxx: has joined #ruby
[01:32:28] Yzguy: has joined #ruby
[01:34:40] jerematic: has joined #ruby
[01:34:40] domgetter: Could be that Craigslist changed something in the last 2 years which broke this. No idea
[01:35:19] wolffles: im assuming that aswell
[01:35:53] N1njturt1e: has joined #ruby
[01:36:17] flashpoint9: has joined #ruby
[01:36:24] araujo__: has joined #ruby
[01:38:14] wolffles: my first problem is that $ruby file.rb returns an error which i dont understand
[01:38:44] domgetter: What's the error?
[01:38:54] wolffles: so someone told me to try ‘$bundle exec ruby file.rb’ and it works fine
[01:39:07] Rodya_: has joined #ruby
[01:39:08] wolffles: but then the code itself doesnt post
[01:39:15] gtsai: has joined #ruby
[01:39:43] wolffles: Users/wolfgang/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- craigs_gem (LoadError)
[01:39:44] wolffles: from /Users/wolfgang/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
[01:39:44] wolffles: from post1.rb:1:in `<main>'
[01:40:06] domgetter: wolffles in the future, use gist.github.com to post several lines at once
[01:40:57] cemerick: has joined #ruby
[01:42:02] domgetter: Well, what I would do next is use pry to find out where the code stops doing what I expect, and follow the calls through the gem
[01:42:24] maletor3: has joined #ruby
[01:42:26] domgetter: since the gem is installed as source code, you can just keep dropping binding.pry throughout it
[01:42:38] nofxx: has joined #ruby
[01:43:42] wolffles: ill give it a try
[01:45:40] allcentury: has joined #ruby
[01:46:29] jaiks1: has joined #ruby
[01:46:43] tatsuo: has joined #ruby
[01:47:39] roamingdog: has joined #ruby
[01:48:05] ReK2: has joined #ruby
[01:48:05] ReK2: has joined #ruby
[01:51:02] eein-: has joined #ruby
[01:51:21] nofxx: has joined #ruby
[01:54:01] pilne: i've yet to find any solid info, but i want to keep hoping that I wasn't getting trolled by a python fan when they said ruby 3 will have concurrency. the way they said it just leaves me doubting and my google-fu is failing me
[01:54:42] n1x-nz: has joined #ruby
[01:57:12] duckpuppy: has joined #ruby
[01:58:05] LoneHerm_: has joined #ruby
[01:59:27] phredus: has joined #ruby
[02:01:32] nankyokusei: has joined #ruby
[02:02:46] domgetter: pilne Ruby has concurrency. Did you mean parallelism?
[02:04:18] domgetter: pilne here is the tweet you may be looking for: https://twitter.com/yukihiro_matz/status/495219763883163648
[02:05:10] N1njturt1e: has joined #ruby
[02:05:24] pilne: ty domgetter and yes, i meant parallelism, ty.
[02:05:28] prefix: has joined #ruby
[02:06:09] Rodya_: has joined #ruby
[02:06:13] pilne: that is a very good goal
[02:07:16] prefix: has joined #ruby
[02:09:22] jaguarmagenta: has joined #ruby
[02:13:20] bmorrison: has joined #ruby
[02:13:30] djbkd: has joined #ruby
[02:14:46] CJKinni: has joined #ruby
[02:18:25] lightt: has joined #ruby
[02:21:38] arlek: has joined #ruby
[02:21:51] kgrz: has joined #ruby
[02:23:19] beilabs: has joined #ruby
[02:24:13] jaguarma_: has joined #ruby
[02:24:51] haraigo: has joined #ruby
[02:30:02] statelesscode: has joined #ruby
[02:31:25] ur5us: has joined #ruby
[02:34:22] lightt: has joined #ruby
[02:34:44] duckpuppy: has joined #ruby
[02:34:59] charliesome: has joined #ruby
[02:35:57] goooodroot: has joined #ruby
[02:37:44] flashpoint9: has joined #ruby
[02:41:05] domgetter: pilne: remember: concurrency is when two people have to share a pencil. Parallelism is when there are two pencils
[02:41:12] pizzaops: has joined #ruby
[02:41:24] rkazak: has joined #ruby
[02:41:52] pilne: i usually don't forget, but i went out and did some drinking and holdem on a riverboat today with some friends... so my brain got slippery
[02:43:14] maletor3: has joined #ruby
[02:45:11] Channel6: has joined #ruby
[02:47:10] LoneHerm_: has joined #ruby
[02:47:19] xxneolithicxx: has joined #ruby
[02:47:53] allcentury: has joined #ruby
[02:47:57] xxneolithicxx: has joined #ruby
[02:48:12] roamingdog: has joined #ruby
[02:52:25] psmolen: has joined #ruby
[02:54:05] ekinmur: has joined #ruby
[02:55:37] David_H__: has joined #ruby
[02:55:57] cd83x: has joined #ruby
[02:56:57] matp: has joined #ruby
[02:58:29] roamingdog: has joined #ruby
[03:02:01] bmorrison: has joined #ruby
[03:05:10] karmatr0n: has joined #ruby
[03:06:43] tatsuo: has joined #ruby
[03:06:53] LoneHerm_: has joined #ruby
[03:07:09] nischay: has joined #ruby
[03:09:52] Yiota: has joined #ruby
[03:13:49] jancel: has joined #ruby
[03:13:58] braincrash: has joined #ruby
[03:14:16] djbkd: has joined #ruby
[03:16:35] phredus: has joined #ruby
[03:21:29] k3rn31: has joined #ruby
[03:25:26] tolland: has joined #ruby
[03:28:00] jancel: has joined #ruby
[03:35:18] Darkman738: has joined #ruby
[03:35:25] devbug: has joined #ruby
[03:35:35] N1njturt1e: has joined #ruby
[03:36:47] astrobunny: has joined #ruby
[03:37:25] beilabs: has joined #ruby
[03:37:26] charliesome: has joined #ruby
[03:37:44] sneakerhax: has joined #ruby
[03:38:02] N1njturt1e: has joined #ruby
[03:38:47] unvexp: has joined #ruby
[03:39:21] gooooodroot: has joined #ruby
[03:40:47] Darkman738: I'm working on something that I feel like is quite simple, but I keep running into an issue. I've got a simple class holding a simple hash with some exposed methods, however when I try to access the .keys method of the hash I get "undefined method `keys' for nil:NilClass"
[03:41:26] Darkman738: clearly this is stating I haven't initialized my variable, and I can't quite figure out how best to do that
[03:42:02] weemsledeux: has joined #ruby
[03:42:10] Radar: ?gist darkman738
[03:42:10] ruby[bot]: darkman738: https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
[03:42:15] Darkman738: https://gist.github.com/anonymous/91fd95029fd05f19c2cc85e77f16dfb1
[03:42:36] Darkman738: I'm certain it's simple, but I'm quite the n00b to ruby
[03:43:05] Radar: darkman738: https://gist.github.com/radar/d2f931b51a7231e5cc1d22550a117eef
[03:43:20] Radar: darkman738: You should be calling QueryRepository.new to initialize a new instance of that class.
[03:43:37] Radar: Then the methods defined there are instance methods, which will have access to the instance variable defined within the initialize method.
[03:43:55] Darkman738: how could I organize it so that isn't a requirement?
[03:43:56] maletor3: has joined #ruby
[03:44:25] Darkman738: I'd rather just get an array of labels without having to create a new instance of the class
[03:45:43] haraigo: has joined #ruby
[03:46:13] Radar: Why do you not want that to be a requirement?
[03:46:36] Darkman738: that's almost all that class will be doing
[03:46:58] Darkman738: I don't want to have to create a new instance to get or return the hash value
[03:48:18] Darkman738: Radar: I'm wrapping it into a class to centralize the queries and allow me to change from static values to a db at some point in the future
[03:48:28] Darkman738: but for now it's going to be fairly static
[03:50:59] lightt: has joined #ruby
[03:51:18] electrostat: has joined #ruby
[03:51:47] gix: has joined #ruby
[03:52:26] solocshaw1: has joined #ruby
[03:53:21] allcentury: has joined #ruby
[03:53:44] rickmasta: has joined #ruby
[03:56:23] nischay: has joined #ruby
[03:57:30] framling: has joined #ruby
[03:58:11] N1njturt1e: has joined #ruby
[03:59:53] d0lph1n98: has joined #ruby
[04:02:24] nankyokusei: has joined #ruby
[04:03:43] Yiota: has joined #ruby
[04:06:07] jancel: has joined #ruby
[04:08:38] kareeoleez: has joined #ruby
[04:09:46] Darkman738: Radar, also, I'm still getting the same error
[04:11:34] arooni: has joined #ruby
[04:11:40] rkazak: has joined #ruby
[04:11:57] Respek: has joined #ruby
[04:13:57] terlar: has joined #ruby
[04:14:30] ICantCook: has joined #ruby
[04:15:02] PaulCape_: has joined #ruby
[04:15:03] djbkd: has joined #ruby
[04:15:09] hk238: has joined #ruby
[04:19:02] hahuang65: has joined #ruby
[04:23:01] Darkman738: Radar: ignore that, I missed a call I was doing previously, but now it's barking about the method get_labels being undefined which doesn't make much sense...
[04:23:34] goodroot: has joined #ruby
[04:23:48] jackjackdripper: has joined #ruby
[04:25:05] hahuang61: has joined #ruby
[04:25:31] bmorrison: has joined #ruby
[04:26:32] tildes_: has joined #ruby
[04:28:08] cd83x: has joined #ruby
[04:28:49] tatsuo: has joined #ruby
[04:29:07] phredus: has joined #ruby
[04:31:36] ksmutthu: has joined #ruby
[04:31:59] N1njturt1e: has joined #ruby
[04:33:50] ramfjord: has joined #ruby
[04:34:24] crystal77: has joined #ruby
[04:36:59] N1njturt1e: has joined #ruby
[04:37:19] dionysus69: has joined #ruby
[04:38:20] N1njturt1e: has joined #ruby
[04:42:08] lxsameer: has joined #ruby
[04:42:19] postmodern: has joined #ruby
[04:44:43] maletor3: has joined #ruby
[04:50:04] karmatr0n: has joined #ruby
[04:53:41] MikeHunt: has joined #ruby
[04:53:58] MikeHunt: has joined #ruby
[04:54:12] allcentury: has joined #ruby
[04:57:03] noodle: has joined #ruby
[04:57:47] N1njturt1e: has joined #ruby
[05:04:21] pocketprotector: has joined #ruby
[05:05:20] sarcas: has joined #ruby
[05:06:04] tekacs: has joined #ruby
[05:06:26] BackEndCoder: has joined #ruby
[05:06:34] EvilJStoker: has joined #ruby
[05:06:34] JStoker: has joined #ruby
[05:07:07] lupine: has joined #ruby
[05:07:11] eljimmy: has joined #ruby
[05:08:24] pocketprotector: has joined #ruby
[05:08:45] tmtwd: has joined #ruby
[05:09:24] bnjf: has joined #ruby
[05:13:48] tvw: has joined #ruby
[05:15:00] jancel: has joined #ruby
[05:15:46] djbkd: has joined #ruby
[05:18:16] moei: has joined #ruby
[05:22:27] N1njturt1e: has joined #ruby
[05:24:25] Yiota: has joined #ruby
[05:26:52] noodle: has joined #ruby
[05:29:23] astrobunny: has joined #ruby
[05:30:07] kgrz: has joined #ruby
[05:32:49] pawnbox: has joined #ruby
[05:32:53] tildes_: has joined #ruby
[05:33:42] craigp: has joined #ruby
[05:37:00] t1mxg0d: has joined #ruby
[05:37:15] banister: has joined #ruby
[05:37:27] howdoi: has joined #ruby
[05:40:41] flashpoint9: has joined #ruby
[05:40:55] lightt: has joined #ruby
[05:40:57] paul0: has joined #ruby
[05:42:10] t1mxg0d: has joined #ruby
[05:45:35] maletor3: has joined #ruby
[05:46:01] dudepare: has joined #ruby
[05:46:29] pawnbox: has joined #ruby
[05:48:11] nofxx: has joined #ruby
[05:48:11] nofxx: has joined #ruby
[05:48:14] phredus: has joined #ruby
[05:48:30] rkazak: has joined #ruby
[05:48:30] anisha: has joined #ruby
[05:48:56] allcentury: has joined #ruby
[05:51:40] LoneHerm_: has joined #ruby
[05:56:50] pawnbox: has joined #ruby
[05:57:53] spyder55: has joined #ruby
[06:01:27] ur5us: has joined #ruby
[06:01:31] matp: has joined #ruby
[06:03:09] lessless: has joined #ruby
[06:03:14] nankyokusei: has joined #ruby
[06:04:07] last_staff: has joined #ruby
[06:05:27] fenre: has joined #ruby
[06:06:43] mark_66: has joined #ruby
[06:07:50] kareeoleez: has joined #ruby
[06:11:05] edwinvdgraaf: has joined #ruby
[06:11:53] agent_white: has left #ruby: ()
[06:15:59] blackgoat: has joined #ruby
[06:16:31] jancel: has joined #ruby
[06:16:34] djbkd: has joined #ruby
[06:17:51] certainty: has joined #ruby
[06:18:10] spyder55: has joined #ruby
[06:18:46] N1njturt1e: has joined #ruby
[06:19:29] lightt: has joined #ruby
[06:20:54] aganov: has joined #ruby
[06:21:54] the_drow: has joined #ruby
[06:22:50] codecop: has joined #ruby
[06:24:42] firstdayonthejob: has joined #ruby
[06:24:47] the_drow_: has joined #ruby
[06:25:18] djbkd: has joined #ruby
[06:26:11] bigkevmcd: has joined #ruby
[06:28:27] N1njturt1e: has joined #ruby
[06:29:21] tAn: has joined #ruby
[06:32:01] M570: has joined #ruby
[06:33:32] Dimik: has joined #ruby
[06:33:33] spyder55: has joined #ruby
[06:37:28] agit0: has joined #ruby
[06:37:37] Macaveli: has joined #ruby
[06:38:26] jerematic: has joined #ruby
[06:39:36] tmtwd: has joined #ruby
[06:39:59] N1njturt1e: has joined #ruby
[06:40:27] the_drow: has joined #ruby
[06:42:20] LoneHerm_: has joined #ruby
[06:46:20] maletor3: has joined #ruby
[06:49:06] gagrio: has joined #ruby
[06:49:12] fenre: has joined #ruby
[06:50:03] aries_liuxueyang: has joined #ruby
[06:52:44] Spami: has joined #ruby
[06:55:14] flughafen: has joined #ruby
[06:55:21] hahuang61: has joined #ruby
[06:58:43] andikr: has joined #ruby
[06:59:35] astrobunny: has joined #ruby
[07:01:36] aasadaz: has joined #ruby
[07:04:57] SDr: has joined #ruby
[07:05:03] SDr: hello peeps
[07:05:14] SDr: how can I run middleman server in supervisord?
[07:07:16] DTZUBDUB: has joined #ruby
[07:07:56] Couch: has joined #ruby
[07:11:08] iceden: has joined #ruby
[07:11:22] pawnbox: has joined #ruby
[07:13:55] gooodroot: has joined #ruby
[07:15:01] aganov: has joined #ruby
[07:16:08] goooodroot: has joined #ruby
[07:16:42] pawnbox: has joined #ruby
[07:22:27] blockchan: has joined #ruby
[07:23:35] LMity: has joined #ruby
[07:23:49] eein-: has joined #ruby
[07:25:33] giz|work: has joined #ruby
[07:25:50] antgel: has joined #ruby
[07:27:36] n1x-nz: has joined #ruby
[07:29:25] vikaton: has joined #ruby
[07:29:29] gooooodroot: has joined #ruby
[07:30:00] anisha_: has joined #ruby
[07:30:06] auzty: has joined #ruby
[07:34:06] Bish: >> def test x; x+=" two";puts x.object_id; end; x = "one"; test x; x.object_id
[07:34:24] Bish: >> def test x; x+=" two";puts x.object_id; end; x = "one"; test x; x.object_id
[07:34:26] ruby[bot]: Bish: # => 554388650 ...check link for more (https://eval.in/583779)
[07:34:30] phunkren_: has joined #ruby
[07:35:41] Bish: why is that string getting cloned?
[07:35:45] goodroot: has joined #ruby
[07:36:26] antgel: has joined #ruby
[07:37:44] Bish: asm>> def test x; x+=" two";puts x.object_id; end; x = "one"; test x; x.object_id
[07:37:45] ruby[bot]: Bish: I have disassembled your code, the result is at https://eval.in/583784
[07:37:53] apeiros: Bish: it isn't cloned?
[07:37:54] phunkren_: has left #ruby: ("Textual IRC Client: www.textualapp.com")
[07:38:04] apeiros: you get a new string, if that's what you mean
[07:38:13] apeiros: and the reason is because that's how String#+ is defined
[07:38:29] apeiros: string1 + string2 # => new_string3
[07:39:11] jerematic: has joined #ruby
[07:39:27] ur5us: has joined #ruby
[07:39:46] Bish: ah i c, it's too early in the morning
[07:40:03] Bish: i thought that was wrong because x="1"; x+= "2" changes x
[07:40:11] Bish: but taht is because it is holder of the "="
[07:40:55] Spami: is there a rbenv reinstall command?
[07:43:11] N1njturt1e: has joined #ruby
[07:43:26] scepticulous: has joined #ruby
[07:44:43] harfangk: has joined #ruby
[07:45:39] weemsledeux: has joined #ruby
[07:47:07] maletor3: has joined #ruby
[07:48:24] allcentury: has joined #ruby
[07:53:59] einarj: has joined #ruby
[07:56:01] lalalaaa: has joined #ruby
[07:58:02] LoneHermit: has joined #ruby
[07:58:20] gnufied: has joined #ruby
[07:59:27] haxrbyte: has joined #ruby
[08:00:24] vondruch: has joined #ruby
[08:00:33] blaxter: has joined #ruby
[08:01:26] ocbtec: has joined #ruby
[08:03:16] tAn: has joined #ruby
[08:04:04] nankyokusei: has joined #ruby
[08:04:26] jancel: has joined #ruby
[08:06:53] charliesome: has joined #ruby
[08:07:10] kareeoleez: is there any other way to write if x == "test" and y == "test" ?
[08:07:31] kareeoleez: [x,y].include? test isn't exactly what I want
[08:08:02] apeiros: none which would be more succinct than those two
[08:09:12] digitalfiz: has joined #ruby
[08:09:15] pizzaops: has joined #ruby
[08:10:27] heftig: kareeoleez: maybe write x == y and y == "test"
[08:10:51] kareeoleez: it isn't a little bit not too DRY
[08:10:56] kareeoleez: I know it's not a big deal
[08:11:00] kareeoleez: just a matter of OCD
[08:11:13] kareeoleez: what If you have 10 conditions?
[08:11:18] heftig: yeah, python has x == y == "test" which is weird coming from other languages but not that bad
[08:11:29] kareeoleez: this could be better
[08:11:35] heftig: [x,y].all? { |i| i == "test" }
[08:11:59] kareeoleez: what is all?
[08:12:18] heftig: ri "Enumerable#all?"
[08:13:00] cemerick: has joined #ruby
[08:13:19] heftig: returns true if the block never returns false (i.e. if the enumerable is empty, it's true too)
[08:13:26] wnd: has joined #ruby
[08:13:56] heftig: (or rather, returns false or nil)
[08:13:56] apeiros: btw., [x,y].include?("test") would be "or", not and :)
[08:14:14] apeiros: heftig: all? afaik always returns true/false
[08:14:14] heftig: yeah, i think that's what they meant by "isn't exactly what they want"
[08:14:21] heftig: apeiros: i meant the block
[08:18:04] jackjackdripper: has joined #ruby
[08:20:54] Bish: >> class T; def t; p yield; end;end;T.new.t { self }
[08:20:56] ruby[bot]: Bish: # => main ...check link for more (https://eval.in/583795)
[08:20:56] gregf_: probably an intersect?
[08:21:34] Bish: if i do Mail.new do { put self } it outputs the mail :o
[08:21:48] apeiros: &ri instance_eval Bish
[08:21:48] `derpy: Bish: http://ruby-doc.org/core-2.3.0/BasicObject.html#method-i-instance_eval
[08:22:08] yos7ph: has joined #ruby
[08:22:13] apeiros: also see instance_exec, class_eval, class_exec (latter too are also aliased as module_eval, _exec)
[08:22:14] Bish: i know about instance_eval, i just want to understand
[08:22:32] apeiros: if you know about instance_eval, then what exactly do you not understand?
[08:22:35] Bish: why is "self" in block usually the self of the caller
[08:22:46] Bish: and not in Mail.new do ... end
[08:22:57] apeiros: because Mail.new instance_eval's the block
[08:23:18] Bish: how could i know that
[08:23:31] apeiros: well, you knew about instance_eval, that's how?
[08:23:52] Bish: well but i havn't gotten to the idea ( is that proper english :O )
[08:24:25] Bish: dayum :( i want to call my methods in there
[08:24:26] Bish: that sucks
[08:24:43] apeiros: so maybe the proper reaction wouldn't have been "I know about", but rather "how's it connected?"
[08:24:46] apeiros: ACTION afk
[08:25:00] Bish: nah, i couldn't know it was used in there
[08:25:21] apeiros: what do you suppose why I mentioned it then? you thought I had no reason to or what? :)
[08:25:30] Bish: i didn't know it was connected, i thought u were advising me to look into instance_eval to fix it
[08:25:53] tesuji_: has joined #ruby
[08:25:54] Bish: but didn't know how it would help me
[08:26:23] joonty: has joined #ruby
[08:26:50] DaniG2k: has joined #ruby
[08:29:33] blaxter: has joined #ruby
[08:29:41] jaruga___: has joined #ruby
[08:30:02] bmorrison: has joined #ruby
[08:31:07] Ropeney: has joined #ruby
[08:33:03] araujo: has joined #ruby
[08:34:47] ksmutthu_: has joined #ruby
[08:35:59] marr: has joined #ruby
[08:36:05] gnufied: has joined #ruby
[08:36:26] ICantCook: has joined #ruby
[08:38:15] moeabdol1: has joined #ruby
[08:40:28] gtsai: has joined #ruby
[08:42:52] dionysus69: has joined #ruby
[08:44:31] araujo_: has joined #ruby
[08:45:58] benlieb: has joined #ruby
[08:46:26] moeabdol: has joined #ruby
[08:47:06] dionysus69: has joined #ruby
[08:47:14] benlieb_: has joined #ruby
[08:47:55] maletor3: has joined #ruby
[08:49:21] nobitanobi: has joined #ruby
[08:49:44] pawnbox: has joined #ruby
[08:50:41] troulouliou_div2: has joined #ruby
[08:56:56] bmorrison: has joined #ruby
[08:57:21] weckl: has joined #ruby
[08:58:22] Alazoral: has joined #ruby
[08:59:33] bmorrison: has joined #ruby
[09:00:24] qasaur: has joined #ruby
[09:02:34] ferr: has joined #ruby
[09:04:07] mdw: has joined #ruby
[09:04:07] gooodroot: has joined #ruby
[09:05:00] qasaur_: has joined #ruby
[09:05:34] blackmesa: has joined #ruby
[09:05:44] snowy: has joined #ruby
[09:07:15] bmorrison: has joined #ruby
[09:07:28] kgrz: has joined #ruby
[09:08:16] jas02: has joined #ruby
[09:09:45] hahuang61: has joined #ruby
[09:10:26] ReK2: has joined #ruby
[09:13:27] upstream: has joined #ruby
[09:13:29] bigkevmcd: has joined #ruby
[09:14:52] workmad3: has joined #ruby
[09:16:30] goooodroot: has joined #ruby
[09:17:42] lightt: has joined #ruby
[09:18:00] noobsu: has joined #ruby
[09:18:27] t1mxg0d: has joined #ruby
[09:19:33] ramfjord: has joined #ruby
[09:19:49] workmad3: has joined #ruby
[09:20:50] zeroDi: has joined #ruby
[09:25:54] allcentury: has joined #ruby
[09:26:14] shevy: so many evals and execs
[09:27:34] blackmesa: has joined #ruby
[09:29:42] raeoks: has joined #ruby
[09:31:54] bmorrison: has joined #ruby
[09:32:08] scepticulous: has joined #ruby
[09:33:33] jinie: has joined #ruby
[09:33:37] ksmutthu__: has joined #ruby
[09:33:45] scepticulous: has joined #ruby
[09:34:37] dionysus69: has joined #ruby
[09:38:47] kgrz: has joined #ruby
[09:39:03] jinie: has joined #ruby
[09:41:36] scepticulous: has joined #ruby
[09:46:08] Xentil: has joined #ruby
[09:46:33] LoneHermit: has joined #ruby
[09:47:32] dionysus69: has joined #ruby
[09:48:43] maletor3: has joined #ruby
[09:50:44] gooooodroot: has joined #ruby
[09:50:58] hahuang61: has joined #ruby
[09:51:03] norc: has joined #ruby
[09:51:33] norc: Okay.. say I have a Ruby application that traps sigint, how can I interrupt Ruby and get information about the stack trace?
[09:51:37] solocshaw: has joined #ruby
[09:51:38] norc: (Short of attaching lldb)
[09:52:44] norc: jhass: brilliant that works. Thanks.
[09:53:13] jhass: it's my favorite, nobody thinks of trapping it
[09:54:00] etehtsea: has joined #ruby
[09:54:06] ksmutthu: has joined #ruby
[09:56:57] goodroot: has joined #ruby
[09:57:51] toretore: has joined #ruby
[09:58:01] naftilos76: has joined #ruby
[09:58:12] jaruga___: has joined #ruby
[10:00:23] ruskie: has joined #ruby
[10:00:31] bruce_lee: has joined #ruby
[10:01:46] norc: jhass: Meh, that didn't work as well as I expected it to. Seems like I cannot interrupt rails with webrick ontop like that.
[10:01:54] ReK2: has joined #ruby
[10:01:54] ReK2: has joined #ruby
[10:03:15] the_drow: has joined #ruby
[10:03:34] lightt: i thout this room about jewellery.......
[10:04:54] nankyokusei: has joined #ruby
[10:05:11] gooodroot: has joined #ruby
[10:06:13] blackmesa: has joined #ruby
[10:06:49] gregf_: nothing wrong in that :)
[10:06:52] harfangk: has joined #ruby
[10:07:17] tvw: has joined #ruby
[10:08:25] goooodroot: has joined #ruby
[10:08:38] jhass: norc: well, you got 31 signals, try some more, some might have curious effects
[10:08:48] jhass: like the Ruby VM crashing with its helpful dump
[10:11:52] DaniG2k: has joined #ruby
[10:12:35] duoi: has joined #ruby
[10:12:43] norc: I assume you meant SIGSEGV :)
[10:12:55] nettoweb: has joined #ruby
[10:13:37] etehtsea: has joined #ruby
[10:17:17] haxrbyte: has joined #ruby
[10:18:51] Kedare: has joined #ruby
[10:19:06] c355E3B: has joined #ruby
[10:21:17] jhass: SIGBUS perhaps too
[10:23:12] Xzanron: has joined #ruby
[10:23:39] be3tle: has joined #ruby
[10:26:43] cemerick: has joined #ruby
[10:29:48] Xzanron: has joined #ruby
[10:32:03] charliesome: has joined #ruby
[10:33:46] gooooodroot: has joined #ruby
[10:34:59] biberu: has joined #ruby
[10:38:16] be3tle: anyone know a good way to do authentication with sinatra?
[10:40:09] goodroot: has joined #ruby
[10:40:37] m_antis: has joined #ruby
[10:41:25] jerematic: has joined #ruby
[10:43:14] roshanavand: has joined #ruby
[10:44:31] gooodroot: has joined #ruby
[10:44:57] norc: be3tle: warden I suppose
[10:45:18] roshanavand: has joined #ruby
[10:46:04] hahuang61: has joined #ruby
[10:46:16] norc: be3tle: But to answer that question a bit more details are required.
[10:46:31] Hyuk: has joined #ruby
[10:46:37] centrx: has joined #ruby
[10:47:26] qasaur: has joined #ruby
[10:47:30] einarj: has joined #ruby
[10:47:44] Macaveli_: has joined #ruby
[10:48:24] GodFather: has joined #ruby
[10:49:30] maletor3: has joined #ruby
[10:50:38] araujo: has joined #ruby
[10:50:38] araujo: has joined #ruby
[10:53:18] electrostat: has joined #ruby
[10:54:53] GodFather: has joined #ruby
[10:56:26] aswen: has joined #ruby
[10:56:53] GodFather: has joined #ruby
[10:57:42] ksmutthu_: has joined #ruby
[10:57:59] moeabdol: has joined #ruby
[10:59:43] blaxter: has joined #ruby
[11:02:05] Yiota: has joined #ruby
[11:03:32] be3tle: norc: thanks I did see warden. i'm making a small open source app intended for self hosting
[11:03:43] be3tle: scalability isn't much of a concern
[11:04:13] rodfersou: has joined #ruby
[11:07:02] JakFrist: has joined #ruby
[11:07:33] johnmilton: has joined #ruby
[11:09:25] blackmesa: has joined #ruby
[11:09:50] goooodroot: has joined #ruby
[11:10:00] CloCkWeRX: has joined #ruby
[11:10:05] zotherstupidguy: has joined #ruby
[11:10:27] giz|work: has joined #ruby
[11:12:23] be3tle: i've just come across padrino, it looks quite nice and could be a way for me to graduate from sinatra
[11:14:05] Rodya_: has joined #ruby
[11:16:24] lalalaaa: has joined #ruby
[11:16:30] ishe_ua: has joined #ruby
[11:17:34] certainty: has joined #ruby
[11:18:06] sdothum: has joined #ruby
[11:18:11] gooooodroot: has joined #ruby
[11:22:26] gregf_: hello, is there a way to set an ALRM and trap it?
[11:22:34] goodroot: has joined #ruby
[11:23:54] gregf_: like so trap("ALRM") do puts "ALARM SET OFF"; alarm(5); # set while ( i+=1 < 10); sleep 1; end; alarm(0);#reset
[11:24:13] duoi: has joined #ruby
[11:24:18] gregf_: sorry, like so trap("ALRM") do puts "ALARM SET OFF";end; alarm(5); # set while ( i+=1 < 10); sleep 1; end; alarm(0);#reset
[11:26:07] solocshaw: has joined #ruby
[11:27:56] benlieb: has joined #ruby
[11:28:49] blockchan1: has joined #ruby
[11:29:11] solocshaw: has joined #ruby
[11:30:11] certainty: has joined #ruby
[11:31:06] arlek: has joined #ruby
[11:31:46] jokke: is there a shorter syntax for [{foo: 'bar'}, {foo: 'baz'}].map {
[11:31:59] jokke: |hash| hash[:foo] }
[11:32:57] bathtub_shark: er, no - that doesn't work for that scenario
[11:33:02] jhass: not really
[11:33:09] jokke: that's too bad :/
[11:33:09] jhass: http://devdocs.io/ruby~2.3/array#method-i-dig doesn't help much either I guess
[11:33:13] centrx: has joined #ruby
[11:33:21] bathtub_shark: algthough your usecase _right now_ is not much different from an array
[11:34:01] bathtub_shark: in applications with large arrays the contents will more likely be in a variable
[11:34:04] jokke: that's too bad. :/ i mean i'd think this is fairly common
[11:34:32] no_gravity: has joined #ruby
[11:34:45] no_gravity: Hello! Last time I tried to install jekyll it hang forever trying to build some kind of documentation. Is there a switch to avoid that?
[11:35:13] jhass: no_gravity: --no-doc in recent rubygems versions, --no-ri --no-rdoc in older ones
[11:35:15] flashpoint9: has joined #ruby
[11:35:38] no_gravity: jhass: Im not sure which version i have
[11:36:04] no_gravity: jhass: Do i do it like this? "gem install ruby -v 2.5 --no-rdoc"
[11:36:29] hahuang61: has joined #ruby
[11:36:52] jhass: ah actually -N or --no-document not --no-doc is the new stuff
[11:36:57] no_gravity: I mean "gem install jekyll -v 2.5 --no-rdoc"
[11:37:27] no_gravity: Been trying to install jekyll since yesterday...
[11:37:40] millerti: has joined #ruby
[11:37:42] jhass: you can also add gem: --no-rdoc --no-ri into a file called ~/.gemrc to disable it generally
[11:38:07] no_gravity: Well, if I can avoid it, I will never ever use anything ruby related again :)
[11:38:23] al2o3-cr: gregf_: how do you mean?
[11:38:25] no_gravity: This must be the most horror installation of a software ever.
[11:38:39] jhass: never go near django then :P
[11:39:27] no_gravity: Its installing those documentation stuff again...
[11:39:42] no_gravity: Hangs at "Installing ri documentation for octokit-4.3.0..." just like yesterday.
[11:39:54] jhass: well you only disabled rdoc...
[11:40:04] jhass: it's not like I didn't mention --no-ri like three times
[11:40:11] no_gravity: Using up 100% of one CPU core...
[11:40:12] banister: has joined #ruby
[11:40:29] no_gravity: How on earth does it spend those billions and billions of CPU cycles?
[11:40:58] jhass: scanning the source code for doc comments
[11:41:01] Shashikant86: has joined #ruby
[11:41:12] no_gravity: How can that take minutes?
[11:41:28] no_gravity: Is it using sleepsort?
[11:41:57] jhass: idk, dig into the source and make it better?
[11:42:06] jerematic: has joined #ruby
[11:42:08] solocshaw: has joined #ruby
[11:42:08] jhass: a rant never has never improved a situation
[11:42:30] ElFerna: has joined #ruby
[11:42:32] no_gravity: Still hanging...
[11:42:45] allcentury: has joined #ruby
[11:43:45] quarcu: has joined #ruby
[11:45:03] gregf_: al2o3-cr: well i needed to wrap the alarm function and call it from ruby
[11:45:24] gregf_: i tried this: trap("ALRM") do puts "ALARM SET OFF";exit;end;libc = Fiddle.dlopen("/lib/x86_64-linux-gnu/libc.so.6");alarm = Fiddle::Function.new(libc["alarm"], [Fiddle::TYPE_DOUBLE], Fiddle::TYPE_DOUBLE); p alarm; alarm.call(5);i = 1; while ((i+=1) < 10); sleep 1;end; alarm.call(0); # doesn't trigger
[11:45:53] gregf_: im writing this for gaining a lock on a file :|
[11:46:45] no_gravity: Still hanging...
[11:46:51] no_gravity: Can I interrupt it?
[11:47:04] gregf_: just realized that ec2 instances have python and perl installed but no ruby :\
[11:47:06] no_gravity: It stil hogs up one CPU...
[11:47:31] no_gravity: gregf_: The instances? I think you mean some specific image?
[11:47:58] gregf_: well, yep, image
[11:48:01] al2o3-cr: gregf_: alarm = Function.new(Handle.new(nil)['alarm'], [-TYPE_INT], -TYPE_INT); trap("ALRM") { puts "ALARM SET OFF" }; alarm.call(5) # this triggers
[11:48:54] nischay: has joined #ruby
[11:48:55] mikecmpbll: has joined #ruby
[11:49:11] gregf_: al2o3-cr: where is Function from?
[11:49:19] gregf_: and Handle
[11:49:19] al2o3-cr: gregf_: fiddle
[11:49:41] al2o3-cr: `include Fiddle`
[11:50:02] gregf_: er, well require ;)
[11:50:14] maletor3: has joined #ruby
[11:50:16] gregf_: also those constants TYPE_INT
[11:50:24] al2o3-cr: require then include :P
[11:50:40] tlaxkit: has joined #ruby
[11:51:38] gregf_: yay. that works :)
[11:51:43] gregf_: al2o3-cr: cheers man
[11:51:49] gregf_: s/man// ;)
[11:53:01] jammi-: has joined #ruby
[11:53:36] gnufied: has joined #ruby
[11:53:56] tesuji_: has joined #ruby
[11:53:58] tesuji_: has joined #ruby
[11:54:11] gregf_: its ubuntu 14 and no ruby with it *sigh*
[11:54:56] D30: has joined #ruby
[11:55:12] Hanmac: has joined #ruby
[11:55:18] jammi-: has left #ruby: ()
[11:56:27] gregf_: oh well if i change TYPE_DOUBLE to TYPE_INT.. the code i chatted above works too :).*should've looked at the method sig*
[11:57:33] al2o3-cr: gregf_: should be `-TYPE_INT` unsigned int
[11:57:41] norc: My "Fiddle" highlight watcher woke me from my sleep.
[11:57:53] norc: What is today's hack about?
[11:58:56] gregf_: al2o3-cr: sure, thanks :)
[11:59:32] prestorium: has joined #ruby
[12:00:21] platzhirsch: has joined #ruby
[12:02:11] senayar: has joined #ruby
[12:02:11] senayar: has joined #ruby
[12:04:10] gagrio: has joined #ruby
[12:05:46] CloCkWeRX: has joined #ruby
[12:05:49] nankyokusei: has joined #ruby
[12:13:46] kknight: has joined #ruby
[12:14:21] kknight: hello what is the difference between short_by and order_by in ruby?
[12:15:01] kknight: anyone there?
[12:15:50] al2o3-cr: that was short and sweet
[12:16:00] kknight: has joined #ruby
[12:16:24] Hanmac: shevy: http://xkcd.com/1688/large/
[12:16:30] kknight: what is the difference between sort by and order_by in ruby?
[12:16:51] jhass: kknight: order_by is not a core ruby method
[12:16:56] norc: kknight: sort_by comes form Enumerable, the other one is not core.
[12:17:40] kknight: please check http://apidock.com/rails/ActiveRecord/QueryMethods/order
[12:17:42] domgetter: has joined #ruby
[12:17:45] hahuang61: has joined #ruby
[12:17:53] kknight: there order_by is given
[12:17:57] norc: kknight: That one is a method from ActiveRecord which is part of rails.
[12:18:13] jhass: and it's called order, not order_by
[12:18:14] norc: kknight: And it produces a query that uses "ORDER BY" from SQL.
[12:18:16] eljimmy: has joined #ruby
[12:19:22] kknight: norc: but while making app it does samr thing?
[12:19:32] norc: kknight: No they do not.
[12:19:45] pawnbox: has joined #ruby
[12:20:03] norc: kknight: One is for sorting an Enumerable collection, and the other one is a magic method from ActiveRecord.
[12:20:07] jhass: kknight: they really aren't all that similar, but to generalize, order does the sorting in the database, sort_by does the sorting in your ruby process
[12:20:15] synthroid: has joined #ruby
[12:20:25] jhass: but they don't even take comparable arguments
[12:20:42] jhass: or are available in many comparable places
[12:21:30] WonyoungJu: has joined #ruby
[12:21:41] rkoller: has joined #ruby
[12:24:01] jschoolcraft: has joined #ruby
[12:25:18] flashpoint9: has joined #ruby
[12:26:19] allcentury: has joined #ruby
[12:27:29] pawnbox_: has joined #ruby
[12:27:48] gooodroot: has joined #ruby
[12:28:22] shevy: hanmac lol
[12:29:15] Hanmac: ACTION votes for kicking users into the #rubyonrails channel if they don't go them selves ;P
[12:30:58] shevy: guess the IRC protocol did not specify that
[12:31:23] sepp2k: has joined #ruby
[12:31:54] DaniG2k: has joined #ruby
[12:31:58] mleung: has joined #ruby
[12:32:02] domgetter: But hanmac, it was an activerecord question, not a rubyonrails question! /s
[12:32:04] chouhoulis: has joined #ruby
[12:32:42] Hanmac: maybe but the chance is that its answerd in the rails channel is higher
[12:32:56] Hanmac: also most of the new users doesnt understand that ruby != rails
[12:33:12] norc: hanmac: And that is their biggest problem, because rails is just ruby...
[12:33:32] norc: hanmac: You see that when people use "Concerns" to solve mixin problems because they do not know how include works.
[12:33:34] chouhoulis: has joined #ruby
[12:33:37] Hanmac: thats the reasons why i hate apidock
[12:34:11] norc: Or when people misunderstood autoloading for "rails has magical naming conventions"
[12:34:52] vikaton: has joined #ruby
[12:35:15] domgetter: Concerns Considered Concerning
[12:36:16] karmatr0n: has joined #ruby
[12:37:00] diegoaguilar: has joined #ruby
[12:37:17] norc: domgetter: The day I learned about default assignee and singleton classes was when everything about modules and methods become so apparent. :)
[12:37:28] norc: and default definee.
[12:38:56] duoi: has joined #ruby
[12:39:38] lessless: has joined #ruby
[12:42:23] jas02: has joined #ruby
[12:42:46] DTZUBDUB: has joined #ruby
[12:42:48] babblebre: has joined #ruby
[12:42:48] DylanJ: has joined #ruby
[12:43:06] jerematic: has joined #ruby
[12:44:14] tatsuo: has joined #ruby
[12:44:15] tknz: has joined #ruby
[12:44:32] hutch34: has joined #ruby
[12:45:12] joonty: has joined #ruby
[12:45:13] domgetter: I know what an assignee is in contract law, but not in Ruby. Do you have a resource I can read up on? I just grepped for it in Metaprogramming Ruby and nothing came up.
[12:46:38] malconis: has joined #ruby
[12:47:51] qasaur: has joined #ruby
[12:48:25] norc: domgetter: when you type "def foo; end" the default assignee is the object that receives the method
[12:48:46] norc: (Since you are not specifying it explicitly by way of: def self.foo; end)
[12:48:48] deadnull_: has joined #ruby
[12:49:30] fmcgeough: has joined #ruby
[12:50:01] wolffles: has joined #ruby
[12:50:24] chouhoul_: has joined #ruby
[12:51:02] maletor3: has joined #ruby
[12:51:10] craigp: has joined #ruby
[12:52:20] d0lph1n98: has joined #ruby
[12:52:58] craigp: has joined #ruby
[12:54:38] c0mrad3: has joined #ruby
[12:54:46] craigp: has joined #ruby
[12:54:56] CJKinni`: has joined #ruby
[12:55:28] pawnbox: has joined #ruby
[12:56:30] DaniG2k: has joined #ruby
[12:59:04] ramortegui: has joined #ruby
[12:59:58] millerti: has joined #ruby
[12:59:59] dcluna: has joined #ruby
[13:00:29] norc: domgetter: https://www.youtube.com/watch?v=by5fFOBhtPQ
[13:01:01] norc: That is where I acquired the term "default definee"
[13:01:14] craigp: has joined #ruby
[13:03:01] benlieb: has joined #ruby
[13:04:44] duckpuppy: has joined #ruby
[13:05:12] cemerick: has joined #ruby
[13:05:40] shevy: sounds weird
[13:08:13] hahuang61: has joined #ruby
[13:08:24] shevy: is there any semi-official timeline for ruby 3.0 ?
[13:08:28] ChiefAlexander: has joined #ruby
[13:08:44] GodFather: has joined #ruby
[13:10:24] yqt: has joined #ruby
[13:12:06] domgetter: norc: class Fixnum; alias :oldsum :+; def +(o); if rand < 0.001; 0; else; self.oldsum(o); end; end; end #not evil at all, I promise
[13:12:07] ByronJohnson: has joined #ruby
[13:12:11] floatingpoint: has joined #ruby
[13:12:53] kgrz: has joined #ruby
[13:13:35] aegis3121: has joined #ruby
[13:13:36] skweek: has joined #ruby
[13:14:26] wilsonc91: has joined #ruby
[13:15:03] sebstrax: has joined #ruby
[13:18:45] gagrio: has joined #ruby
[13:19:36] ekinmur: has joined #ruby
[13:25:08] TheHodge: has joined #ruby
[13:27:10] goooodroot: has joined #ruby
[13:27:47] freerobby: has joined #ruby
[13:27:54] ChiefAlexander: has joined #ruby
[13:30:24] cdg: has joined #ruby
[13:31:02] platzhirsch: has joined #ruby
[13:33:13] David_H_Smith: has joined #ruby
[13:33:59] flughafen_: has joined #ruby
[13:34:07] Yiota: has joined #ruby
[13:34:52] karmatr0n: has joined #ruby
[13:36:06] karmatr0n: has joined #ruby
[13:36:19] ldnunes: has joined #ruby
[13:37:51] centrx: has joined #ruby
[13:38:11] Vingador: has joined #ruby
[13:42:10] GodFather: has joined #ruby
[13:42:29] mikecmpb_: has joined #ruby
[13:43:07] wolffles: has joined #ruby
[13:44:55] davedev24: has joined #ruby
[13:48:17] jas02: has joined #ruby
[13:48:54] SilverKey: has joined #ruby
[13:49:20] wilsonc91: has joined #ruby
[13:50:21] Es0teric: has joined #ruby
[13:50:31] freerobby: has joined #ruby
[13:50:44] palms: has joined #ruby
[13:51:19] skweek: has joined #ruby
[13:51:51] maletor3: has joined #ruby
[13:52:24] D30: has joined #ruby
[13:52:48] Mon_Ouie: has joined #ruby
[13:53:16] flughafen_: good day fellow ruby enthuiasts
[13:53:19] kies: has joined #ruby
[13:53:49] shevy: ah ah ah berlin is in the house!
[13:53:59] blockchan: has joined #ruby
[13:55:14] frem_: has joined #ruby
[14:02:38] adaedra: Is Rational#to_f guaranteed to yield a correct result or is it as bad as standard float operation?
[14:03:19] workmad3: adaedra: it'll convert to a float, which means you have the standard issues with float representation
[14:03:35] jhass: meaning not every rational can be represented as a float
[14:03:49] jhass: accurately at least
[14:03:49] workmad3: adaedra: but if it's the result of a bunch of calculations, it'll be a single possible error, not compounded by multiple errors throughout the calculation
[14:04:19] workmad3: (assuming your calculations were all in Rationals that is)
[14:04:31] norc: adaedra: Take a look at the implementation of Rational#to_f -> it becomes obvious immediately.
[14:05:15] workmad3: norc: it's also obvious because the rounding errors in floating points are intrinsic to the nature of the representation... some values just can't be represented accurately because they require an infinite expansion
[14:05:38] Rodya_: has joined #ruby
[14:05:40] adaedra: but is it ok then to do all calculations as rationals and use a .to_f at the end for storage?
[14:05:43] workmad3: the same is true with decimal representations... e.g. `1/3` can't be represented accurately in decimal
[14:05:57] eserror_: has joined #ruby
[14:05:59] norc: adaedra: Sure, but you are still limited to the imprecision of float for that single division at the end.
[14:05:59] freerobby: has joined #ruby
[14:06:14] norc: adaedra: If you can live with that, then that is fine. Else if you need precision then store the denominator and numerator.
[14:06:39] norc: to_s will do that for you I think
[14:06:40] nankyokusei: has joined #ruby
[14:07:06] jhass: meaning don't expect r.to_f.to_r == r for all cases
[14:07:30] chouhoulis: has joined #ruby
[14:07:56] lessless: has joined #ruby
[14:08:09] adaedra: to_s give the a/b representation, which is bad for display
[14:08:18] etehtsea: has joined #ruby
[14:09:14] kareeoleez: has joined #ruby
[14:09:19] etehtsea: has joined #ruby
[14:09:21] workmad3: adaedra: how accurate does your calculation result actually need to be?
[14:09:28] lightt: has joined #ruby
[14:09:50] workmad3: adaedra: most people aren't going to be bothered by a single error that alters your result by 1 part in a million or something
[14:11:18] norc: workmad3: that depends on your employer.. if it happens to be CERN... :-P
[14:11:26] norc: But I guess "most people" covers that
[14:11:50] workmad3: norc: if you're dealing with high-precision finance or scientific calculations, you don't tend to use IEEE floats :P
[14:12:34] jhass: I think HTML was just fine with IEEE floats
[14:13:10] shevy: yay! regex-precision parsing of HTML!
[14:13:29] openstruct: has joined #ruby
[14:13:45] freerobby: has joined #ruby
[14:14:54] kgrz: has joined #ruby
[14:15:01] adaedra: well, that's monetary data, so I prefer limit losses at a maximum
[14:16:49] norc: adaedra: Is the "storage" the actual visual representation? If not, you can just save it as a fraction and just create a Float whenever your application needs to display it.
[14:20:31] agent_white: has joined #ruby
[14:20:57] shevy: adaedra are you building up to some riches here
[14:20:57] hutch34: has joined #ruby
[14:21:02] workmad3: adaedra: unless you need sub-penny precision, the typical way to deal with money is to deal in integers btw
[14:21:22] shevy: value every cent!
[14:21:43] workmad3: (even if you need sub-penny, you tend to deal in integers for precision, just your integer is tenths or hundreths of a penny/smallest unit instead)
[14:21:47] shevy: penny ...
[14:21:54] SilverKey: has joined #ruby
[14:21:56] adaedra: workmad3: I didn't think about it this way
[14:22:13] workmad3: adaedra: that's what the Money gem does for you too ;)
[14:22:20] nando293921: has joined #ruby
[14:22:32] workmad3: shevy: I'm british, we think in pennies :P
[14:23:43] adaedra: That's another approach, thanks for the insight
[14:24:41] norc: workmad3: That is also the only clean way to store monetary data in a database for example, since it automatically solves all "dollar <> cent" conversion issues that might arise, since it is just a representational matter.
[14:25:36] workmad3: adaedra: you can also use BigDecimal numbers for your financial calculations, which can store all your 2dp numbers without loss of precision :)
[14:26:04] workmad3: norc: you can use :decimal in the database too, which will be fine unless you hit a really weird edge-case
[14:26:14] damireh: has joined #ruby
[14:26:23] adaedra: that's what the DB returns us yes, but I was using Rational because to_r :p
[14:26:42] workmad3: adaedra: why not just leave it as a BigDecimal then? ;)
[14:27:06] rickmasta: has joined #ruby
[14:27:14] adaedra: Because I work on other sources having them stored otherwise
[14:28:24] damireh: Ive come across this piece of code https://github.com/thoughtbot/high_voltage/blob/master/lib/high_voltage/version.rb#L2
[14:28:37] damireh: and was wondering if anyone can help me understand why theyre freezing the VERSION constant?
[14:28:46] tlaxkit: has joined #ruby
[14:28:59] workmad3: damireh: so code that inadvertantly changes the string in-place will throw errors
[14:29:53] shevy: would this be the same as adding "# frozen_string_literal: true" on top?
[14:31:38] damireh: workmad3 ahh makes sense thanks!
[14:34:50] freerobby: has joined #ruby
[14:35:37] hutch34: has joined #ruby
[14:37:44] troulouliou_div2: has joined #ruby
[14:37:53] eserror: has joined #ruby
[14:40:17] hk238: has joined #ruby
[14:41:18] spyder55: has joined #ruby
[14:42:16] damireh: has joined #ruby
[14:42:49] gtsai: has joined #ruby
[14:43:35] DTZUBDUB: has joined #ruby
[14:43:49] smathy: has joined #ruby
[14:45:31] polishdub: has joined #ruby
[14:47:05] rkazak: has joined #ruby
[14:47:34] jnoob22: has joined #ruby
[14:47:38] Spami: has joined #ruby
[14:47:40] gtsai: has joined #ruby
[14:47:52] duckpupp2: has joined #ruby
[14:48:08] eserror: has joined #ruby
[14:49:46] duckpuppy: has joined #ruby
[14:50:24] JesseH: has joined #ruby
[14:52:34] maletor3: has joined #ruby
[14:54:45] rippa: has joined #ruby
[14:55:54] TomyLobo: has joined #ruby
[14:56:09] Kus: has joined #ruby
[14:56:23] chipotle: has joined #ruby
[14:57:05] jancel: has joined #ruby
[14:57:14] SilverKey: has joined #ruby
[15:01:28] duckpupp1: has joined #ruby
[15:04:39] tjohnson: has joined #ruby
[15:04:43] duckpupp2: has joined #ruby
[15:04:43] gtsai: has joined #ruby
[15:06:54] ChiefAlexander: has joined #ruby
[15:07:06] SilverKey: has joined #ruby
[15:08:01] Rodya_: has joined #ruby
[15:08:38] GodFather: has joined #ruby
[15:09:22] Yiota: has joined #ruby
[15:09:37] gtsai_: has joined #ruby
[15:09:40] giz|work: has joined #ruby
[15:11:27] chouhoulis: has joined #ruby
[15:12:26] chouhoulis: has joined #ruby
[15:12:29] synthroid: has joined #ruby
[15:17:23] jimbeaudoin: has joined #ruby
[15:19:03] binaryplease1: has joined #ruby
[15:19:26] binaryplease1: has joined #ruby
[15:22:14] hahuang61: has joined #ruby
[15:22:15] craigp: has joined #ruby
[15:23:14] harfangk: has joined #ruby
[15:23:51] skolman_: has joined #ruby
[15:23:52] tvw: has joined #ruby
[15:25:52] GarethAdams: has joined #ruby
[15:27:56] panpainter: has joined #ruby
[15:29:17] cielf: has joined #ruby
[15:30:07] nando293921: has joined #ruby
[15:32:50] aegis3121: has joined #ruby
[15:33:43] Tranquility: has joined #ruby
[15:34:04] MrBusiness3: has joined #ruby
[15:34:27] r4z3r: has joined #ruby
[15:34:49] JJM: has joined #ruby
[15:34:58] enty: has joined #ruby
[15:35:11] Tranquility: has left #ruby: ()
[15:35:33] enty: I've been trying to install a gem with gem install but it depends on other gems which are way too new and won't work on my system
[15:36:13] aegis3121: Try installing an older version that may not have that problem?
[15:36:39] enty: I tried installing those gems from the debian package repository but gem still tries to install the new version from the gem server
[15:36:42] JJM_: has joined #ruby
[15:36:53] enty: can I persuade it somehow to use the locally installed version from the debian repos?
[15:37:03] lxsameer: has joined #ruby
[15:37:30] jhass: it most likely does that because the gem you're trying to install actually does depend on newer versions than available on your system
[15:37:46] adaedra: don't mix gems from repos and rubygems, it's just asking for trouble
[15:38:02] jhass: enty: which gem, which ruby version?
[15:38:18] enty: ruby 1.8, mogbak
[15:38:20] jhass: and just to have it spoken out, how did you install ruby?
[15:38:29] kgrz: has joined #ruby
[15:38:32] GinoManWorks: has joined #ruby
[15:38:41] jhass: yeah finding support for 1.8 in the community is increasingly impossible
[15:38:48] jhass: (which is a good thing)
[15:39:12] SilverKey: has joined #ruby
[15:39:16] adaedra: It belongs in a museum!
[15:39:29] etehtsea: has joined #ruby
[15:41:59] ProofTechnique: has joined #ruby
[15:42:18] jancel: has joined #ruby
[15:43:20] jhass: enty: so, oldoldstable?
[15:43:28] jhass: stable has 2.1, oldstable has 1.9
[15:45:08] enty: yes, we're trying to get away from it
[15:45:29] enty: oldoldstable has 1.9 as well, but mogbak was last modified in 2011 so I figured I would not need it
[15:45:55] enty: oh, hm, they say they test against 1.9
[15:46:01] enty: guess I'll install 1.9 then
[15:47:21] brendan-_: has joined #ruby
[15:47:42] raeoks: has joined #ruby
[15:48:25] Rasi: has joined #ruby
[15:49:02] jrafanie: has joined #ruby
[15:49:19] harfangk: has joined #ruby
[15:49:40] jhass: yes 1.8 is actually a decade old by now
[15:49:43] jhass: 1.9 is officially EOL
[15:49:51] jhass: 2.0 is officially EOL even
[15:50:16] ytti: in reality you must support what current stable-1 distribution is supporting
[15:50:22] ytti: otherwise users will be butthurt
[15:50:40] ytti: people were complaining to me, because i'm using slop3 on my project
[15:50:49] ytti: that i have to change it to slop4, so that they can package it to debian
[15:51:01] ytti: so we're victim of 90s package manager designs
[15:51:24] diegoviola: has joined #ruby
[15:51:24] ytti: and instead of debian peeps being sensible and package slop3 and slop4, they seem to insist other people need to move to slop4
[15:51:42] mdw: has joined #ruby
[15:51:48] enty: look, I know these are old releases, I just want gem to use the locally installed version anyway
[15:51:58] enty: is there a way, yes or no?
[15:52:26] enty: you can't talk me out of this because i have people sitting behind me poking me with pitchforks and telling me to get it over with already
[15:52:57] enty: ideally I'd use ruby 2.3 as well, or whatever shiny new version is shiny and new
[15:53:22] enty: but on top of that, there have been no commits to mogbak since 2011 so it's pretty much depending on EOL ruby versions anyway, I guess, or is at least untested with anything newer
[15:53:41] enty: their github says they test against 1.9
[15:53:59] cajone: has joined #ruby
[15:54:55] maletor3: has joined #ruby
[15:55:10] blaxter: has joined #ruby
[15:55:30] dumdedum: has joined #ruby
[15:55:53] etehtsea: has joined #ruby
[15:56:11] jhass: 1.9 it is then what you should be using, thought we established that
[15:56:19] smathy: Thankfully people came up with better, simpler ways to keep your ruby versions up to date than relying on the distro package manager.
[15:59:39] t1mxg0d: has joined #ruby
[16:00:46] jancel: has joined #ruby
[16:01:49] norc: has joined #ruby
[16:04:02] hahuang61: has joined #ruby
[16:04:49] lightt: has joined #ruby
[16:04:53] synthroid: has joined #ruby
[16:06:24] gooooodroot: has joined #ruby
[16:06:50] synthroid: has joined #ruby
[16:07:15] whathappens: has joined #ruby
[16:07:32] nankyokusei: has joined #ruby
[16:08:16] Mon_Ouie: has joined #ruby
[16:08:26] certainty: has joined #ruby
[16:09:04] amclain: has joined #ruby
[16:09:06] RobertBirnie: has joined #ruby
[16:10:35] Cohedrin: has joined #ruby
[16:11:11] tildes_: has joined #ruby
[16:13:10] elifoster: has joined #ruby
[16:13:18] flughafen_: has joined #ruby
[16:13:30] weemsledeux: has joined #ruby
[16:14:08] agit0: has joined #ruby
[16:14:53] mistermocha: has joined #ruby
[16:17:09] d0lph1n98: has joined #ruby
[16:18:02] SCHAAP137: has joined #ruby
[16:18:05] mdw: has joined #ruby
[16:20:34] ncthom91: has joined #ruby
[16:21:55] Spami_: has joined #ruby
[16:22:35] Eiam: has joined #ruby
[16:25:18] GodFather: has joined #ruby
[16:25:51] enty: has left #ruby: ("alright then")
[16:26:40] wrkrcoop: has joined #ruby
[16:26:52] wrkrcoop: im trying to use the Savon gem to make an xml request
[16:26:57] malconis: has joined #ruby
[16:27:02] nankyokusei: has joined #ruby
[16:27:13] wrkrcoop: im getting a 400 error, anyone able to take a look at my request code and see if there’s anything wrong with syntax? https://gist.github.com/anonymous/0955414d62d050b22771308a47389ab3
[16:28:23] jhass: plain 400 is usually an authorization or authentication issue
[16:29:01] norc: 400 means malformed input
[16:29:15] norc: 401/403 are used for authentication/authorization issues
[16:29:16] jhass: oh right, was at 403 for some reason :/
[16:29:37] norc: wrkrcoop, wireshark the output, see if the XML is well formed.
[16:30:02] wrkrcoop: yeah now getting ‘malformed SOAP message
[16:30:14] wrkrcoop: saying a namespace elment is not bound …
[16:30:18] norc: There you go.
[16:30:19] wrkrcoop: but i have the namespaces hash
[16:30:45] jhass: it's obfuscated enough that nobody will be able to help you on that level
[16:31:11] jhass: given even trying to spot missing elements or typos is completely pointless here
[16:31:26] wrkrcoop: i can’t image there’s a typo ..
[16:31:51] wrkrcoop: thanks ill check though
[16:32:31] sneakerh_: has joined #ruby
[16:33:06] Dimik: has joined #ruby
[16:35:06] pietr0: has joined #ruby
[16:35:59] wrkrcoop: has joined #ruby
[16:38:08] [Butch]: has joined #ruby
[16:38:59] lxsameer: has joined #ruby
[16:39:43] hutch34: has joined #ruby
[16:39:52] gtsai: has joined #ruby
[16:41:07] dcluna: has joined #ruby
[16:41:09] Vingador: has joined #ruby
[16:42:03] last_staff: has joined #ruby
[16:43:13] djbkd: has joined #ruby
[16:44:39] centrx: has joined #ruby
[16:45:35] DTZUBDUB: has joined #ruby
[16:46:27] pilne: has joined #ruby
[16:47:09] wrkrcoop: has joined #ruby
[16:47:29] johnmilton: has joined #ruby
[16:47:33] shinnya: has joined #ruby
[16:47:36] mwlang: has joined #ruby
[16:49:09] tatsuo: has joined #ruby
[16:49:35] finisherr: has joined #ruby
[16:50:37] nankyoku_: has joined #ruby
[16:50:53] ramfjord: has joined #ruby
[16:51:36] moeabdol1: has joined #ruby
[16:53:04] N1njturt1e: has joined #ruby
[16:53:48] codecop: has joined #ruby
[16:55:38] maletor3: has joined #ruby
[16:55:58] choke: has joined #ruby
[16:56:21] zotherstupidguy: has joined #ruby
[16:56:50] mleung: has joined #ruby
[16:57:40] inukshuk_: has joined #ruby
[16:59:06] hahuang61: has joined #ruby
[16:59:42] tatsuo_: has joined #ruby
[17:00:37] maletor3: has joined #ruby
[17:01:57] finisherr_: has joined #ruby
[17:02:11] aegis3121: has joined #ruby
[17:02:33] joonty: has joined #ruby
[17:05:41] johnmilton: has joined #ruby
[17:05:42] wrkrcoop: im trying to make a request with the Savon gem, and I’m getting a ‘Savon::SOAPFault: (SOAP-ENV:Server) This is an operation implementation generated fault’ https://gist.github.com/anonymous/39175621ad309bc200f52cc7a296cfda
[17:07:03] DTZUBDUB: has joined #ruby
[17:07:56] aegis3121: has joined #ruby
[17:08:44] weaksauce: has joined #ruby
[17:09:09] certainty: has joined #ruby
[17:09:17] mdw7: has joined #ruby
[17:09:46] darkxploit: has joined #ruby
[17:10:02] soroot: has joined #ruby
[17:10:55] soroot: #join #mvim
[17:11:04] madgen: has joined #ruby
[17:11:18] gtsai: has joined #ruby
[17:12:18] Coldblackice: has joined #ruby
[17:13:22] firstdayonthejob: has joined #ruby
[17:18:02] blockchan: has joined #ruby
[17:18:32] soroot: has joined #ruby
[17:18:47] qasaur: has joined #ruby
[17:21:04] crystal77: has joined #ruby
[17:21:21] Wolland: has joined #ruby
[17:21:28] raeoks: has joined #ruby
[17:22:30] Rasi: has joined #ruby
[17:23:01] raeoks: has joined #ruby
[17:24:22] centrx: has joined #ruby
[17:25:20] minimalism: has joined #ruby
[17:27:23] blockchan: has joined #ruby
[17:27:27] moeabdol2: has joined #ruby
[17:27:44] jrafanie: has joined #ruby
[17:30:00] chouhoul_: has joined #ruby
[17:30:37] gtsai: has joined #ruby
[17:31:44] chouhoul_: has joined #ruby
[17:33:42] last_staff: has joined #ruby
[17:33:51] Eiam: I constantly have resque jobs that just get stuck. It's driving me nuts. Any suggestions for how to either 1)debug the issue or 2) make resque not let the workers run for days after they are complete?
[17:34:03] Eiam: all I see are posts about how to clear them and unstick them. I don't want to clear them and unstick them, I want them to stop doing that.
[17:35:07] diegorv: has joined #ruby
[17:35:11] diegorv: has joined #ruby
[17:35:59] gregf: has joined #ruby
[17:36:09] lxsameer: has joined #ruby
[17:36:11] jhass: I guess spawn a thread that crashes the process after n seconds to get a ruby vm dump
[17:36:51] jhass: or attach an strace or even a full debugger (lldb, gdb)
[17:37:09] Eiam: it happens in heroku
[17:37:11] Eiam: (like instance)
[17:37:19] Eiam: so no attaching
[17:37:47] Eiam: jhass: so a secondary watchdog thread basically
[17:37:48] jhass: well, get a dump of everything and replicate?
[17:38:09] Eiam: jhass: the jobs run every 5 minutes on 10 different workers. once or twice a day, one worker hangs
[17:38:22] Eiam: but that means that thousands and thousands of times the jobs complete
[17:38:24] wrkrcoop: im getting an error that says ‘ns0 must be followed by either attribute specifications, “>” or “/>” does that mean “ns0>”: “…”
[17:40:21] Eiam: I'd do it on ONE worker, but chances are its goin to get hung and then everything is dead
[17:40:35] Eiam: which is why I have so many workers, to account for them randomly hanging until I can kill them all and restart
[17:40:42] Eiam: does no one else have this issue with resque? maybe im doing somethign wrong
[17:40:54] karthikselva: has joined #ruby
[17:41:34] Eiam: http://vitobotta.com/resque-automatically-kill-stuck-workers-retry-failed-jobs/ wacky stuff like this
[17:41:41] symm-: has joined #ruby
[17:41:50] Eiam: 'I created a worker that kills my hung workers'
[17:42:05] Eiam: ACTION looks for duct tape and a "there I fixed it' sign
[17:44:39] fiifi: has joined #ruby
[17:44:41] Eiam: jhass: how do you notice a failure to do the dump?
[17:44:44] Eiam: (to try and replicate)
[17:45:04] Eiam: I'm not convinced (for once...) that its my code thats failing to execute, but some PID/process mangaement thats just derping out
[17:45:18] Eiam: (mostly because the resulting "work" of each job seems to always complete, the job just never decides its done?)
[17:45:43] jhass: perhaps time to switch to sidekiq after all?
[17:45:47] Eiam: each job registers data into the DB when its finished (As its last line of code), and I can see those updated when a worker is hung
[17:46:15] Eiam: a different kind of duct tape solution
[17:46:27] floatingpoint: has joined #ruby
[17:46:35] jhass: if you suspect resque is the culprit, not at all
[17:46:47] jhass: also probably will save you some money actually
[17:46:47] Eiam: yeah reading https://github.com/mperham/sidekiq
[17:46:49] Eiam: says its drop in
[17:47:03] Eiam: not what I planned on doing this monday but what the hell
[17:47:09] duoi: has joined #ruby
[17:47:20] jhass: biggest issue is that you code needs to be thread safe
[17:47:22] smathy: Well, sidekiq also has better error visibility.
[17:47:56] Eiam: jhass:each worker starts a DB transsaction and locks the table while it does its work
[17:48:21] Eiam: but in an ideal world, I'd prefer to have ONE worker
[17:48:28] Eiam: I just can't because they always get f'ing hung
[17:48:39] Eiam: one worker, one job.
[17:48:59] jhass: do some plain old ruby and use redis directly?
[17:49:45] jhass: Eiam: loop do; Job.new(Redis.fetch_job).run; end
[17:49:48] fiifi: hello havenwood
[17:50:03] giz|work: has joined #ruby
[17:50:23] fiifi: new here need some help
[17:50:33] Eiam: jhass: yeah i see the por https://github.com/mperham/sidekiq/blob/master/examples/por.rb
[17:51:44] jhass: nah I mean without sidekiq, resque or any form of concurrency at all then
[17:52:15] fiifi: am new to ruby need nuturing
[17:52:21] Eiam: fiifi: ask the question
[17:52:42] j3r0: has joined #ruby
[17:53:30] fiifi: what are symbols in ruby?
[17:53:36] Eiam: fiifi: constant strings
[17:53:46] jhass: identifying values
[17:53:49] jhass: in doubt use a string
[17:53:58] Eiam: http://www.troubleshooters.com/codecorn/ruby/symbols.htm
[17:54:24] Eiam: jhass: hah, your answer was more useful than mine
[17:55:08] blackjid: has joined #ruby
[17:55:23] JakFrist: has joined #ruby
[17:55:52] rcvalle: has joined #ruby
[17:56:33] ramfjord: has joined #ruby
[17:56:51] Ishido: has joined #ruby
[17:56:51] qasaur: has joined #ruby
[17:59:13] synthroid: has joined #ruby
[17:59:16] gtsai: has joined #ruby
[17:59:39] LoneHermit: has joined #ruby
[17:59:52] wrkrcoop: when i make this soap request, i get the following error “(ns0:Receiver) The malformed SOAP message received.Open quote is expected for attribute "xmlns:ns1" associated with an element type "env:Envelope”.” cant find a good answer online explaining what to do, https://gist.github.com/anonymous/fa2eb24a6309e9d9d5a3bb557350a7e5#file-j-rb-L16
[18:00:22] centrx: has joined #ruby
[18:00:51] karthikselva2: has joined #ruby
[18:00:59] jackjackdripper: has joined #ruby
[18:01:51] antgel: has joined #ruby
[18:02:14] duckpuppy: has joined #ruby
[18:02:15] apeiros: wrkrcoop: sounds like either you sent or received invalid xml
[18:02:37] apeiros: but hard to tell from the very little context you give.
[18:02:38] wrkrcoop: apeiros: yeah definitely invalid, but i can’t figure out what it wants me to do …
[18:02:53] wrkrcoop: open quote is expected for attribute xmlns:ns1 …
[18:03:19] djbkd: has joined #ruby
[18:03:43] apeiros: I don't know savon, but "xmlns:ns1 = :.../>" doesn't look like it was part of how to build valid xml
[18:04:29] wrkrcoop: yeah but i was getting an error and it said you need /> then it said you need “ = “ now im getting this error
[18:04:32] apeiros: IMO: find a way to get the raw xml which you build in your client.call. I wouldn't be surprised if the problem became obvious through that.
[18:04:57] apeiros: aha, so you question above was related to xml… you do realize that you gave absolutely no helpful context in that question?
[18:07:45] flashpoint9: has joined #ruby
[18:09:00] apeiros: wrkrcoop: I see jhass already told you that the context you provide is insufficient. so I guess me telling you again won't change anything. good luck.
[18:09:35] wrkrcoop: i think the problem is with my nested attributes ..
[18:09:51] certainty: has joined #ruby
[18:10:53] antgel: has joined #ruby
[18:11:08] whathappens: has joined #ruby
[18:11:56] Yiota: has joined #ruby
[18:14:09] karthikselva: has joined #ruby
[18:17:34] k3rn31: has joined #ruby
[18:17:36] fiifi: thanks eiam
[18:18:45] spider-mario: has joined #ruby
[18:18:58] Gasher: has joined #ruby
[18:19:41] dcluna: has joined #ruby
[18:20:26] [Butch]: has joined #ruby
[18:20:30] qasaur: has joined #ruby
[18:23:14] duckpupp1: has joined #ruby
[18:23:58] djbkd: has joined #ruby
[18:24:13] karthikselva: has joined #ruby
[18:24:47] madgen: has joined #ruby
[18:25:39] choke: has joined #ruby
[18:25:55] nankyokusei: has joined #ruby
[18:26:08] arlek: has joined #ruby
[18:26:38] MrBusiness2: has joined #ruby
[18:26:53] duckpupp1: has joined #ruby
[18:27:05] nankyokusei: has joined #ruby
[18:27:07] nikger: has joined #ruby
[18:27:27] nikger: what is the best vimrc config for rails dev?
[18:27:28] whathapp_: has joined #ruby
[18:27:42] shevy: ban in 3 ... 2 ... 1 ...
[18:27:43] apeiros: !nick nikger
[18:27:53] apeiros: ACTION kicks ruby[bot]
[18:28:01] apeiros: apeiros kicked nikger: nick
[18:28:15] apeiros: +b nikger!*@*$#ruby-banned
[18:28:15] ruby[bot]: -b *!*@15.Red-79-159-88.dynamicIP.rima-tde.net$#ruby-banned
[18:28:34] apeiros: aha, that one it recognizes? half a botsnack for you. but only half.
[18:28:42] whathappens: has joined #ruby
[18:28:43] adaedra: shevy: once again, better do !ops and let go.
[18:28:46] apeiros: oh… !badnick, not !nick
[18:28:57] apeiros: shame on me. no snack for me :<
[18:29:01] cschneid: has joined #ruby
[18:29:11] adaedra: ?snackpeiros
[18:29:11] ruby[bot]: adaedra: I don't know anything about snackpeiros
[18:29:28] apeiros: good thing I still get dinner :D
[18:29:57] tildes_: has joined #ruby
[18:30:11] apeiros: and yeah, shevy, please just do !ops (+ nickname of offender if channel is busy), we'll figure the rest :)
[18:30:45] apeiros: oh… shevy is not identified - no !ops for them :-/
[18:30:46] yqt: has joined #ruby
[18:31:49] shevy: good old ruboto ...
[18:33:46] centrx: has joined #ruby
[18:34:35] chouhoulis: has joined #ruby
[18:35:18] multi_io: has joined #ruby
[18:37:30] k3rn31: has joined #ruby
[18:37:40] sumobob: has joined #ruby
[18:38:11] choke: has joined #ruby
[18:39:01] jerematic: has joined #ruby
[18:39:58] mebus: has joined #ruby
[18:40:08] mebus: Hi Does "Installing nokogiri 1.6.6.2 with native extensions" always take forever?
[18:40:42] apeiros: no, last time it took 3min less than forever
[18:40:56] mebus: apeiros: so it will take a long time?
[18:41:12] apeiros: on my machine, a minute or two
[18:41:25] adaedra: it has to compile the extension
[18:41:27] smathy: mebus, it takes about 3 seconds longer than whatever period of time you ^Ced it.
[18:41:59] mebus: smathy: I think it has been running for at least 15 minutes now.
[18:41:59] apeiros: grrrr, ChanServ stole my wizard hat :(
[18:42:08] adaedra: nope, it's me, you needed it?
[18:42:38] smathy: mebus, definitely long, but not unheard of depending on your machine specs and load.
[18:42:41] adaedra: mebus: look a process monitor, does it do anything?
[18:42:44] mebus: It's running on a Xeon CPU with 4 cores and almost 3 GHz.
[18:42:49] apeiros: $ time gem install nokogiri -> real 1m5.159s
[18:42:54] shevy: mebus yes I have that sometimes, also with nokogiri strangely enough
[18:43:04] smathy: mebus, won't mean much if you're out of physical ram.
[18:43:04] shevy: another weird gem is sinatra, sometimes it hangs
[18:43:06] apeiros: just tried
[18:43:20] mebus: cpu load is about 20% now
[18:43:30] mebus: why can't this shit give me any feedback?
[18:43:42] apeiros: that's a quad-core i7 @ 4ghz with 32GB ram
[18:43:49] u0_a134: has joined #ruby
[18:43:54] N1njturt1e: has joined #ruby
[18:44:00] adaedra: now we're talking.
[18:44:06] mebus: it's using 400 MB of 4 GB RAM.
[18:44:18] mebus: plenty of ram.
[18:44:20] mebus: what can I do?
[18:44:51] jrafanie: has joined #ruby
[18:45:01] mebus: I have another 48 GB here, if it needs more RAM :-/
[18:45:16] apeiros: hm, seems to be mainly IO constrained
[18:45:21] apeiros: CPU and memory are barely touched
[18:45:22] jancel: has joined #ruby
[18:45:28] jhass: compilation often is
[18:46:18] jhass: boot your entire system into a ramdisk \o/
[18:46:24] mebus: jhass: i will let it run for one more hour.
[18:46:26] karmatr0n: has joined #ruby
[18:46:38] jhass: mebus: it is still consuming CPU though?
[18:46:42] fiifi: when can one use symbols?
[18:46:45] mebus: jhass: yes.
[18:46:59] apeiros: fiifi: when you identify things
[18:47:14] jhass: nokogiri often compiles libxml2 these days, but it usually shouldn't take that long :/
[18:47:14] apeiros: fiifi: especially anything within your ruby code (instance variables, method names)
[18:47:48] mebus: jhass: actually I installed libxml2 in ubuntu.
[18:47:59] jhass: doesn't matter :)
[18:48:14] apeiros: aren't there config options to let it use the system libxml2?
[18:49:26] watersoul: has joined #ruby
[18:49:40] SDr: has joined #ruby
[18:49:41] mebus: I installed "1.6.7.2" in Ubuntu, why is it compiling "1.6.6.2" then?
[18:49:44] jhass: but iirc ubunutus is too old
[18:49:55] jhass: or too new :P
[18:49:59] mebus: no, the ubuntu's one is atually newer.
[18:50:00] xue: has joined #ruby
[18:50:01] jhass: something something version
[18:50:13] mebus: strange stuff.
[18:50:27] jhass: nokogiri is pretty strange stuff, yeah
[18:50:49] jhass: https://github.com/sparklemotion/nokogiri/blob/master/STANDARD_RESPONSES.md
[18:50:52] heftig: has joined #ruby
[18:51:53] mebus: I guess I am set back with not enough information ether.
[18:52:29] adaedra: Clever Nokogiri! With the time you just saved, approach enlightenment by meditating on this koan. (http://twitter.com/rjw1/status/2741916767)
[18:52:44] adaedra: (This sentence in the tutorial always amused me.)
[18:54:00] ChiefAlexander: has joined #ruby
[18:54:07] mikecmpbll: has joined #ruby
[18:54:42] dcluna: has joined #ruby
[18:55:01] jhass: well https://github.com/sparklemotion/nokogiri/blob/master/STANDARD_RESPONSES.md has the "best" explanation I could find so far "please first understand that you may be asking Nokogiri to work with an unsupported version of libxml2"
[18:55:16] Madplatypus: has joined #ruby
[18:55:32] jhass: eh copy paste fail
[18:55:43] jhass: http://www.nokogiri.org/tutorials/installing_nokogiri.html#using_your_system_libraries
[18:57:32] norc: has joined #ruby
[18:58:09] tAn: has joined #ruby
[18:59:16] mebus: can i specify the version I want?
[18:59:51] ule: has joined #ruby
[19:00:30] Eiam: jhass: ah, sidekiq is lgpl
[19:00:39] Eiam: man, wish I'd read that before I just converted it all
[19:00:42] Eiam: ACTION does a big fat revert in git
[19:00:51] jhass: well Mike's doing it fulltime
[19:01:03] jhass: http://sidekiq.org/products/pro
[19:01:04] Eiam: jhass: for sure, nothing against his choice, just impacts my ability to choose is all
[19:01:30] Eiam: I'm sure someone here is paying for a license, just have to figure out how that would impact me
[19:03:20] dane_jones: has joined #ruby
[19:04:06] u0_a134: has joined #ruby
[19:04:43] dane_jones: hey guys. Im practicing an interview. One of the questions is tor return all of the correct traversals of a graph the lead to a certain node. I can do the traversal correctly, but at the end I have a bunch of nested arrays (since each recursive call returns an array of arrays). Is there some way to avoid an array of arrays in questions like these?
[19:05:15] toretore: dane_jones: code?
[19:05:28] havenwood: dane_jones: Gist the question and your stab at it?
[19:05:33] drbrain: has joined #ruby
[19:05:53] fiifi: pls can one help me with an example of the usage of symbols
[19:05:54] snowy: has joined #ruby
[19:06:17] jhass: fiifi: "".respond_to?(:size) #=> true
[19:06:25] haraigo: has joined #ruby
[19:06:33] gnufied: has joined #ruby
[19:06:36] jhass: :size is a symbol
[19:06:43] apeiros: >> {this: "is", a: "hash", using: "Symbols", as: "keys"}
[19:06:44] ruby[bot]: apeiros: # => {:this=>"is", :a=>"hash", :using=>"Symbols", :as=>"keys"} (https://eval.in/584194)
[19:06:57] smathy: ACTION can't imagine how LGPL could be a problem for anyone using something like sidekiq
[19:07:00] ule: has joined #ruby
[19:07:01] apeiros: (alternative notation for symbols in hashes/named arguments)
[19:07:03] jancel: has joined #ruby
[19:07:34] apeiros: smathy: sometimes it's enough not being a lawyer and thus not knowing how you might misunderstand in which ways the license impacts you
[19:08:08] jhass: well, I can't imagine Mike going after anybody just evaluating whether sidekiq works/improves for them without buying pro first
[19:08:20] smathy: Sure, but to just bail out without asking.
[19:08:26] A124: Is there efficient way to parse large XMLs?
[19:08:41] fiifi: ohk getting gradually
[19:08:51] jhass: A124: Oga and Nokogori should both have SAX APIs iirc
[19:09:21] smathy: jhass, you won't get pro until you pay, he'd definitely refund you if you wanted a refund. But it's the free version that I assume Eiam is talking about, it's the one that's LGPLed
[19:09:45] gtsai: has joined #ruby
[19:09:47] blackmesa: has joined #ruby
[19:09:49] A124: jhass SAX, Ogi, got it will take look. 8GB files should be ok I guess. Never heard of Oga, thanks.
[19:09:54] jhass: yeah, I mean even if you would somehow violate the LGPL in your trial
[19:09:57] Eiam: smathy: right, seems straightforward
[19:10:07] agent_white: has joined #ruby
[19:10:22] kenichi: has joined #ruby
[19:10:26] russt: has joined #ruby
[19:10:37] certainty: has joined #ruby
[19:11:01] Junaos: has joined #ruby
[19:11:10] fiifi: how about the usage of self keyword
[19:11:25] apeiros: fiifi: you are using some resource to learn ruby, right?
[19:11:32] Eiam: fiifi: this stuff is covered in basic ruby resources
[19:11:34] smathy: Eiam, in case you don't realize, with LGPL you'd only need to redistribute any code that you write as part of sidekiq, the classic example is if you subclass something in sidekiq and alter it. *Using* sidekiq from your own code doesn't require a redistribution of your code.
[19:11:49] Eiam: smathy: I don't set corporate rules, just get to follow them
[19:11:57] apeiros: fiifi: otherwise I'd recommend #new2ruby if you want to learn it through asking on irc
[19:12:01] kirun: has joined #ruby
[19:12:05] Wolland_: has joined #ruby
[19:12:06] smathy: Eiam, oic, fair enough.
[19:12:15] shevy: Eiam seize the power!
[19:12:28] fiifi: kk thanks apeiros
[19:12:42] N1njturt1e: has joined #ruby
[19:12:49] smathy: ...then yeah, $1000 a year for the commercial license. Which is actually worth it for the batches and crash proofness.
[19:12:50] papercode: has joined #ruby
[19:13:14] norc: wrkrcoop, ask your SOAP provider. That SOAP error is generated on the far endpoint.
[19:13:24] jhass: and support in debugging obscure "getting stuck" issues ;)
[19:13:34] kareeoleez: has joined #ruby
[19:13:39] wrkrcoop: norc: thanks
[19:14:19] apeiros: smathy: funny. we have the pro license, but use regular sidekiq :D
[19:14:21] Vingador: has joined #ruby
[19:14:31] apeiros: (got the license mostly due to time constraints, so we could use support if necessary)
[19:14:34] electrostat: has joined #ruby
[19:14:58] norc: apeiros, feel free to pass the license around.
[19:15:05] norc: I know someone who could make use of it.
[19:15:11] Eiam: smathy: yep. I'm sure someone here is paying for it. matter of finding them, figuring out if that grants me the ability to use it too, or if thats another purchase ors omething,
[19:15:20] apeiros: also we still want that support in case we need it ;-)
[19:15:28] norc: I'll resell the support.
[19:15:32] Eiam: smathy: there is pretty much no way that NO ONE here is not paying for a pro license
[19:15:35] A124: ACTION to apeiros, oh hai
[19:15:42] apeiros: not sure mike would like
[19:15:53] mistermocha: has joined #ruby
[19:15:56] norc: apeiros, see - it is a new business strategy. I call it "license multiplexing"
[19:16:11] apeiros: norc: you're late to the party ;-)
[19:16:20] jancel: has joined #ruby
[19:16:20] jhass: oh while at it, y'all seen https://github.com/mperham/sidekiq.cr ? <3 :P
[19:16:22] einarj: has joined #ruby
[19:16:23] apeiros: we're in fact also using a license reseller…
[19:16:31] apeiros: but that'd be #ot :D
[19:16:35] norc: apeiros, but is your reseller a multiplexing license reseller?
[19:16:58] rikkipitt: has joined #ruby
[19:16:59] apeiros: norc: I think more the kind of "buy in mass, get it cheaper, resell with a margin"
[19:17:18] norc: I would go for "Buy once and sell twice, buy beer for the margin"
[19:17:18] apeiros: oh, and/or offer license management as added value
[19:17:33] smathy: apeiros, you know that you're just a `source` block in your Gemfile away from the cooler features? :)
[19:17:46] apeiros: smathy: never needed them :)
[19:17:59] norc: apeiros, oh license management we can do. It's easy since even with 500 customers we just need to manage a single license
[19:18:02] norc: The plan is beautiful.
[19:18:08] norc: apeiros, care if I run the business in your name?
[19:18:08] smathy: apeiros, the better crash protection is something you'll only need after it's too late :)
[19:18:13] Sou|cutter: has joined #ruby
[19:18:24] smathy: Eiam, gotcha, cool.
[19:18:34] Madplatypus: has joined #ruby
[19:18:34] smathy: Eiam, FWIW, it's a per server license.
[19:18:34] apeiros: smathy: none of our jobs will have any issues even when crashing in the middle ;-)
[19:18:48] smathy: apeiros, doesn't matter if they don't get run at all?
[19:19:12] apeiros: it would. but we notice without automation.
[19:19:32] apeiros: and so far the reason for a broken job was never sidekiq
[19:20:01] dmr8: has joined #ruby
[19:20:01] apeiros: 99% of all cases it was "the other side" of a soap/ftp job
[19:20:02] mistermocha: has joined #ruby
[19:20:04] smathy: Rarely is, but I still like the fact that I never need to worry about losing a job.
[19:20:20] smathy: Oh right, you meant not sidekiq or redis/server/worker-host/etc.
[19:20:46] Es0teric: has joined #ruby
[19:21:04] smathy: Yeah, I don't remember any part of that infrastructure ever falling over, still nice peace of mind to know that if it ever did I don't have to chase a lost job.
[19:21:09] smathy: (for the price of one line in my Gemfile ;)
[19:21:26] apeiros: I have that peace even without that line ;-)
[19:21:28] araujo_: has joined #ruby
[19:21:45] tildes_: has joined #ruby
[19:22:02] jenrzzz: has joined #ruby
[19:22:55] eve: has joined #ruby
[19:25:36] kiki_lamb: has joined #ruby
[19:25:50] jackjackdripper: has joined #ruby
[19:26:35] danostrowski: has joined #ruby
[19:27:05] danostrowski: anyone use Sinatra here (possibly on JRuby) and auto-generate API docs from routes? If so, what do you use?
[19:27:25] jancel: has joined #ruby
[19:28:14] madgen: has joined #ruby
[19:29:52] spudowiar: has joined #ruby
[19:31:10] palms: has joined #ruby
[19:32:05] jancel: has joined #ruby
[19:35:03] SilverKey: has joined #ruby
[19:35:07] duckpuppy: has joined #ruby
[19:35:28] dionysus70: has joined #ruby
[19:35:45] ekinmur: has joined #ruby
[19:36:13] antgel: has joined #ruby
[19:39:38] goodroot: has joined #ruby
[19:39:46] karthikselva: has joined #ruby
[19:42:57] cd83x: has joined #ruby
[19:44:47] centrx: has joined #ruby
[19:45:48] giz|work: has joined #ruby
[19:46:52] djbkd: has joined #ruby
[19:47:58] LoneHermit: has joined #ruby
[19:48:32] Pumukel: has joined #ruby
[19:48:59] duckpuppy: has joined #ruby
[19:50:07] Stazer: has left #ruby: ("PART #ruby-de :PING 1465242607")
[19:54:05] boboc: has joined #ruby
[19:55:04] lxsameer: has joined #ruby
[19:57:06] choke: has joined #ruby
[19:57:41] chouhoul_: has joined #ruby
[19:58:22] gtsai: has joined #ruby
[20:00:00] bruce_lee: has joined #ruby
[20:00:00] bruce_lee: has joined #ruby
[20:02:36] symm-: has joined #ruby
[20:03:59] art-solopov: has joined #ruby
[20:04:11] edmundo: has joined #ruby
[20:04:38] edmundo: im starting learning ruby on rails, i need a bit welcome, im confused with oauth2 from google
[20:04:47] ruby[bot]: Please join #RubyOnRails for Rails questions. You need to be identified with NickServ, see /msg NickServ HELP
[20:04:56] edmundo: i need to fill a form and create an event on google calendar with that
[20:05:14] hxegon: ?rails edmundo
[20:05:15] ruby[bot]: edmundo: Please join #RubyOnRails for Rails questions. You need to be identified with NickServ, see /msg NickServ HELP
[20:06:10] norc: edmundo, personally Id say stay away from oauth2 until you have an idea how to solve problems with rails.
[20:06:24] N1njturt1e: has joined #ruby
[20:06:27] edmundo: sorry about that
[20:06:33] norc: and yeah lets continue over there.
[20:06:42] edmundo: i have some knowledge about mvc
[20:06:53] TheHodge: has joined #ruby
[20:06:56] edmundo: join #RubyOnRails
[20:08:34] karthikselva: has joined #ruby
[20:11:25] certainty: has joined #ruby
[20:11:34] diegoviola: has joined #ruby
[20:11:52] diegoviola: has joined #ruby
[20:13:14] mistermocha: has joined #ruby
[20:15:45] nfk: has joined #ruby
[20:15:57] Gasher: has joined #ruby
[20:16:48] mistermocha: has joined #ruby
[20:18:05] ftj: has joined #ruby
[20:18:48] wrkrcoop: so im creating 5 threads
[20:18:56] wrkrcoop: and each thread creates an instance of a class
[20:19:06] wrkrcoop: will i need to worry about them overwriting each other?
[20:19:14] wrkrcoop: no write because an instance has its own variables …
[20:20:21] sumobob: has joined #ruby
[20:22:13] art-solopov: wrkrcoop: If you're creating a variable inside a thread, I guess they wouldn't. But I'd try it out.
[20:22:42] wrkrcoop: art-solopov: like User.new @name shouldn’t be touched by other threads right?
[20:22:46] wrkrcoop: ill try it out just checking
[20:22:57] ncthom91: has joined #ruby
[20:23:03] apeiros: only if you share state
[20:23:14] jhack: has joined #ruby
[20:23:17] apeiros: but your description makes it sound like you don't share any state
[20:23:23] apeiros: *mutable state
[20:23:26] mdw: has joined #ruby
[20:23:57] panpainter: has joined #ruby
[20:24:16] mdw: has joined #ruby
[20:26:58] malconis: has joined #ruby
[20:27:32] skweek: has joined #ruby
[20:27:35] jhack: has joined #ruby
[20:28:57] wrkrcoop: im going to make sure i dont sure state
[20:29:04] ips|malc: has joined #ruby
[20:30:02] norc: wrkrcoop, the problem is you have to make sure that User.new is reentrant (and that requires it and the entire call chain is completely reentrant).
[20:30:19] wrkrcoop: norc: whats reentrant?
[20:30:29] norc: wrkrcoop, the thing that is most often forgotten when talking about thread safety.
[20:30:55] wrkrcoop: norc: so im going to spin up 10 threads, create 10 instances, is that going to be a problem?
[20:31:04] norc: wrkrcoop, that is for you to figure out.
[20:31:15] norc: wrkrcoop, https://en.wikipedia.org/wiki/Reentrancy_(computing)
[20:31:48] N1njturt1e: has joined #ruby
[20:31:52] diegoviola: has joined #ruby
[20:31:55] wrkrcoop: reentrance is when threads get joined?
[20:32:09] norc: wrkrcoop, no it is a property of a function/method.
[20:32:28] wrkrcoop: i have a thread that isn’t closing …
[20:32:34] wrkrcoop: makes a http request and doesn’t close ..
[20:32:38] norc: wrkrcoop, a function is said to be reentrant if it can be entered twice before one finishes.
[20:32:40] wrkrcoop: is this a reentrant problem?
[20:32:53] flughafen_: has joined #ruby
[20:33:04] danostrowski: has joined #ruby
[20:33:07] toretore: wrkrcoop: how about sharing some code?
[20:33:18] wrkrcoop: can’t. work stuff ><
[20:33:30] toretore: (my general advice on threads is don't use threads unless you know what you're doing)
[20:33:36] norc: wrkrcoop, The real problem with reentrancy is that you have to make sure that User.new is reentrant. Then you have to make sure that any method User.new calls is reentrant, and so on until the last C function called.
[20:33:48] norc: wrkrcoop, and then you have to do the same for every single method you use in the thread.
[20:34:03] blackgoat: has joined #ruby
[20:34:08] wrkrcoop: norc: but what does it mean to be reentrant
[20:34:28] norc: wrkrcoop, say you have a function like this:
[20:34:46] norc: def foo; $a = $a + 1; end
[20:34:53] acidrainfall: has joined #ruby
[20:34:55] ur5us: has joined #ruby
[20:35:05] acidrainfall: has left #ruby: ()
[20:35:24] norc: wrkrcoop, now this function shares state with other threads, but you dont know about it.
[20:35:43] djbkd: has joined #ruby
[20:35:43] wrkrcoop: why does it share sate?
[20:35:48] wrkrcoop: $ = global?
[20:35:57] norc: Which means if that function is entered by thread a, and then entered by thread b before a completes you can create race conditions.
[20:36:00] vikaton: has joined #ruby
[20:36:12] ytti: technically that part of code is re-entrant
[20:36:24] norc: ytti, I know, but lets just assume for the sake of the discussion its not.
[20:36:30] kgrz: has joined #ruby
[20:36:38] ytti: it's not idempotent, but it's re-etrant
[20:36:44] ytti: but sure, let's assume it is not
[20:36:57] eam: why would that be reentrant?
[20:37:07] norc: actually
[20:37:08] ytti: because at any time it is running $a has single value
[20:37:11] norc: asm>> def foo; $a = $a + 1; end
[20:37:13] ruby[bot]: norc: I have disassembled your code, the result is at https://eval.in/584302
[20:37:16] ytti: you can re-enter it, and it change
[20:37:25] ytti: if example was
[20:37:33] ytti: $a = $a+1; p $a
[20:37:38] ytti: it wouldn't be re-etrant
[20:37:40] eam: ytti: I don't think that's true
[20:38:03] maloik: has joined #ruby
[20:38:14] ytti: you don't know in that code if $a changes doing context switch or not
[20:38:17] ytti: you cannot experience it
[20:38:21] eam: maybe it's true because of the GIL? But if it were C it wouldn't be reentrant
[20:38:27] ytti: even if no GIL
[20:38:31] ytti: it would be re-entrant
[20:38:32] eam: well definitely not then
[20:38:36] ytti: because you only use $a once
[20:38:41] ytti: in single operation
[20:38:48] eam: are you sure?
[20:38:53] ytti: you can't interrupt yourself within one operation
[20:38:56] wrkrcoop: so … what is reentrant?
[20:38:59] eam: ytti: why not?
[20:39:02] norc: wrkrcoop, in essence reentrancy is a property that says "this function can at any point be interrupted and reentered by another task without things blowing up" ... in a nutshell.
[20:39:08] ytti: re-entrancy is concept of stopping executing of method/function
[20:39:12] ytti: doing somehing else
[20:39:24] norc: wrkrcoop, and you have to make sure this holds true for every single method you use, and every method that each method uses, and so forth.
[20:39:25] eam: or, rather, are you suggesting that $a = $a + 1 is implemented in a single atomic assembly operation?
[20:39:36] ytti: re-entering that method/function, and everything still working grand
[20:39:37] ytti: if we have
[20:39:37] ytti: $a = $a+1; $a
[20:39:39] norc: eam, I just proved that its not.
[20:39:40] ytti: we might be stopping execution after $a=$a+1
[20:39:44] eam: and not a possible combination of loads, stores, fetching, etc?
[20:39:49] ytti: and then re-enter at p $a
[20:39:49] eam: er, adding
[20:40:03] ytti: and at p $a, it might be something else than the original $a was
[20:40:08] ytti: hence it's not re-entrant
[20:40:20] eam: well, neither are (in a GIL free context)
[20:40:20] ytti: but in just def foo; $a = $a + 1; end
[20:40:35] ytti: you're either stoping the execution before calling $a = $a +1 or after it
[20:40:40] ytti: in either case, behaviour is expected
[20:40:46] wrkrcoop: norc: why would you ever want to interput a function?
[20:40:47] norc: eam, either way. If code holds global/static data it is not reentrant. I know that as one of the 3 rules of reentrancy.
[20:41:01] ytti: but it's not idempotent, you ca't run it many times, and accept always same result
[20:41:02] norc: wrkrcoop, your computer right now is likely to be running about 1000-3000 threads.
[20:41:05] eam: I'm saying both aren't reentrant :)
[20:41:10] norc: wrkrcoop, on 2-8 CPU Cores.
[20:41:10] toretore: wrkrcoop: you don't; the scheduler does
[20:41:23] norc: wrkrcoop, which means your operating system is interrupting threads *all* the time
[20:41:27] icarus: has joined #ruby
[20:41:27] norc: Millions of times per second.
[20:41:37] toretore: wrkrcoop: threads = anything can be interrupted at any time, you don't know when
[20:41:38] norc: Okay, maybe not that much. But very frequently.
[20:41:46] norc: toretore, that applies to processes too.
[20:42:07] wrkrcoop: ok if i have a User class,
[20:42:11] wrkrcoop: and a method called update name
[20:42:20] wrkrcoop: and i create 10 instances of the class
[20:42:22] ChiefAlexander: has joined #ruby
[20:42:25] wrkrcoop: each which calls update_name
[20:42:34] moeabdol2: has joined #ruby
[20:42:34] wrkrcoop: why would i have to worry about them getting interrupted?
[20:42:36] toretore: wrkrcoop: it's impossible to give good advice without seeing the code
[20:42:38] wrkrcoop: aren’t they all seperate?
[20:42:48] toretore: this depends on how it's implemented
[20:42:50] norc: wrkrcoop, that is the thing. Threads still share the same memory.
[20:43:09] norc: wrkrcoop, and if *some* code in the chain holds global or static data it is not reentrant.
[20:43:19] norc: wrkrcoop, you might not see it, and that is the big problem about reentrancy.
[20:43:31] wrkrcoop: threads share memory but dont all instances exist in their own location?
[20:43:40] chipotle: has joined #ruby
[20:43:43] wrkrcoop: do i need to worry about them getting in each others way?
[20:43:47] al2o3-cr: you're all wrong
[20:43:49] Yiota: has joined #ruby
[20:43:54] norc: wrkrcoop, sure. But can you guarantee me that *all* code right into the last C function is reentrant?
[20:44:43] norc: wrkrcoop, Im not saying reentrancy prevents that, but if you dont know about reentrancy then you should leave your fingers away from multithreading.
[20:44:56] danostrowski: has joined #ruby
[20:45:00] wrkrcoop: yeah idk about that
[20:45:04] wrkrcoop: isn’t that rubys job haha
[20:45:28] wrkrcoop: if ruby doesn’t take care of that behind the scenes stuff does that mean it is not thread safe?
[20:45:44] norc: wrkrcoop, ruby does some guarantees, but the problem is that you using libraries which might not be reentrant.
[20:45:51] norc: wrkrcoop, and thread safety is NOT the same thing as reentrancy.
[20:45:52] al2o3-cr: and this is for work?
[20:45:55] norc: a function can be thread safe but not reentrant.
[20:46:19] al2o3-cr: ACTION sheesh
[20:46:45] norc: al2o3-cr, don't believe me? :p
[20:46:49] wrkrcoop: norc: ah you know maybe thats why my connection wasn’t running
[20:46:50] despai: has joined #ruby
[20:47:02] wrkrcoop: i was using Crack::XML.parse and my thread wouldn’t close
[20:47:13] chouhoulis: has joined #ruby
[20:47:19] al2o3-cr: norc: never said i didn't
[20:47:47] chouhoulis: has joined #ruby
[20:48:21] norc: al2o3-cr, a while ago we had a guy in #rubyonrails who was asking fairly basic questions about what a TLS certificate is and why he needs one... and then he explained that bit about how he was responsible for implementing some API for financial transfers between banks..
[20:48:41] norc: That got me scared.
[20:48:45] apeiros: norc: color me unsurprised
[20:48:56] apeiros: ACTION knows of bancs not using transactional databases
[20:49:07] apeiros: because… what could possibly go wrong
[20:49:15] norc: apeiros, you mean like... Deutsche Bank?
[20:49:24] apeiros: norc: not naming names.
[20:49:29] wrkrcoop: the more senior ppl will review so its all good right?
[20:49:38] norc: apeiros, oh I was just making fun of their name being in the news 2 days ago.
[20:49:50] norc: wrkrcoop, no.
[20:49:55] ule: has joined #ruby
[20:49:57] al2o3-cr: deutsche Bundesbank, that's where my money is!
[20:50:07] norc: wrkrcoop, writing thread safe code requires knowing what you do, not hoping someone with experience to find all the bugs.
[20:50:12] norc: al2o3-cr, *was
[20:50:18] norc: Ops. Sorry!
[20:50:33] adaedra: I know an ISP using MongoDB, internet facing, with default security settings (no password)
[20:50:47] diegoaguilar: has joined #ruby
[20:50:52] wrkrcoop: norc: well i read a couple blogs *haha*
[20:50:55] karthikselva: has joined #ruby
[20:51:15] wrkrcoop: so basically it just seems that you want to avoid messing with shared state when you thread. is that basically it?
[20:51:36] norc: wrkrcoop, no.
[20:52:02] norc: wrkrcoop, unless you can promise to call no external functions.
[20:52:27] wrkrcoop: hmm well im making an http request …
[20:52:38] al2o3-cr: all i know is; thread is a piece of string so long
[20:52:58] wrkrcoop: this is why node is better
[20:53:15] al2o3-cr: and i sometimes need it for my buttons
[20:53:22] norc: wrkrcoop, the problem is: If you make mistakes, you get huge weird bugs that you cannot debug because they often happen randomly.
[20:53:37] wrkrcoop: yeah >< pain
[20:53:41] binaryplease1: has joined #ruby
[20:53:48] norc: and if you debug them, the problem disappears, so you dont even know why its happening.
[20:53:50] norc: Or where its happening.
[20:54:02] Cohedrin_: has joined #ruby
[20:54:33] wrkrcoop: so basically dont do threading if you use any 3rd party libraries
[20:54:40] whathappens: has joined #ruby
[20:54:40] GarethAdams: has joined #ruby
[20:54:54] norc: al2o3-cr, I got this underpaid polish lady across the street who happily sews my buttons on for a buck.
[20:54:56] n_blownapart: has joined #ruby
[20:55:25] al2o3-cr: norc: a deer?
[20:56:03] norc: wrkrcoop, no. Dont do threading if you dont understand the implications.
[20:56:14] whathapp_: has joined #ruby
[20:56:33] wrkrcoop: norc: how can you be sure if every method is reentrant if you use a 3rd party library, unless you read every line of code in that library & who the hell is going to do that
[20:56:35] norc: wrkrcoop, or promise to not bother us if you spend a week in your office pulling your hairs out trying to understand why things crash or do things that you cannot possibly explain.
[20:56:54] djbkd: has joined #ruby
[20:57:49] ekinmur: has joined #ruby
[20:57:51] norc: wrkrcoop, now you see the problem.
[20:58:09] wrkrcoop: yeah so wtf you basically cant do threading
[20:58:20] norc: wrkrcoop, sure you can. You just have to be careful about what you are doing and which libraries you are using.
[20:58:26] norc: In essence: Know what you are doing.
[20:58:35] babblebre: has joined #ruby
[20:58:42] blaxter: has joined #ruby
[20:58:44] jancel: has joined #ruby
[20:59:34] joonty: has joined #ruby
[21:00:13] nettoweb: has joined #ruby
[21:00:42] tristanp: has joined #ruby
[21:01:24] lalalaaa: has joined #ruby
[21:01:57] norc: wrkrcoop, and another problem is recognizing reentrant code.
[21:01:58] lalalaaa: Trying to prettify this little snippet here, the bottom part of 2_new.rb looks horrible, what do I do? https://gist.github.com/anonymous/899ae8f2a5e184cf5777c1dda33af253
[21:02:28] norc: wrkrcoop, a popular example is "Mutex", while being a famous synchronization mechanism to write thread safe code, the usage of Mutex might not be reentrant (as it can lead to dead lock scenarios)
[21:02:57] toretore: lalalaaa: looks fine to me
[21:03:03] karthikselva: has joined #ruby
[21:03:51] LaT0rtue: has joined #ruby
[21:04:14] norc: lalalaaa, one small bit: Unless you really need $, use \Z instead.
[21:04:32] djbkd: has joined #ruby
[21:04:47] norc: (Getting used to the habit might save yourself from a security hole some day)
[21:05:15] lxsameer: has joined #ruby
[21:05:15] lxsameer: has joined #ruby
[21:05:45] apeiros: norc: I almost always use \z, but then again, I know whether my data has a terminal newline or not :D
[21:06:10] lalalaaa: toretore: idk, doesn't really feel rubyish
[21:06:11] karthikselva2: has joined #ruby
[21:06:14] lalalaaa: path = m[1]
[21:06:16] bruce_lee: has joined #ruby
[21:06:16] bruce_lee: has joined #ruby
[21:06:22] apeiros: >> ["foo\n" =~ /\Afoo\z/, "foo\n" =~ /\Afoo\Z/]
[21:06:24] ruby[bot]: apeiros: # => [nil, 0] (https://eval.in/584331)
[21:06:32] norc: lalalaaa, the only thing that sucks there is indentation.
[21:06:58] hahuang65: has joined #ruby
[21:07:02] lalalaaa: norc: shouldn't there be an end after the do |m|?
[21:07:22] lalalaaa: that way i could indent it i guess
[21:08:03] norc: lalalaaa, the problem is how you indent the }x)
[21:08:17] norc: lalalaaa, if you move it on the same column as watch it might be a bit prettier.
[21:08:42] norc: or meh, that is not pretty either.
[21:08:50] norc: lalalaaa, oh I know.
[21:08:53] MrBusiness3: has joined #ruby
[21:09:52] norc: lalalaaa, https://gist.github.com/norc/dd3b77776b4daa16edeb50ccf3181610
[21:10:15] norc: Contrary to popular belief local variables do not cause diseases and kill kittens.
[21:10:35] edwinvdgraaf: has joined #ruby
[21:10:52] dcluna: has joined #ruby
[21:11:10] Vingador: has joined #ruby
[21:11:19] norc: lalalaaa, and then move the regex out of the each block of course, becasue you dont need to assign that over and over again.
[21:12:11] certainty: has joined #ruby
[21:12:13] lalalaaa: norc: That was really pretty
[21:12:36] bobbycvi_: has joined #ruby
[21:12:53] norc: lalalaaa, gist updated.
[21:12:55] Rodya_: has joined #ruby
[21:15:07] moeabdol2: has joined #ruby
[21:15:23] zenspider: has joined #ruby
[21:15:49] lalalaaa: norc: i'm amazed. mind if i forward it to the authors? tell them norc did it
[21:18:30] Wolland: has joined #ruby
[21:18:53] lalalaaa: this is what ruby should look like
[21:22:08] madgen_: has joined #ruby
[21:22:18] pawnbox: has joined #ruby
[21:22:45] norc: lalalaaa, submit whatever you please. I don't care about credit for this.
[21:23:01] MrBusiness2: has joined #ruby
[21:25:14] karthikselva: has joined #ruby
[21:25:24] jancel: has joined #ruby
[21:27:55] postmodern: has joined #ruby
[21:28:35] nankyokusei: has joined #ruby
[21:28:35] kareeoleez: has joined #ruby
[21:29:53] Trynemjoel: has joined #ruby
[21:29:59] binaryplease1: has joined #ruby
[21:32:37] Mon_Ouie: has joined #ruby
[21:35:03] Eiam: random abstraction question, if you have a view that renders the same content but its style needs to be different depending on the context in which its viewed.. split the view into two files, one per content type, pass in parameters for the view to check to decide which styles should apply to it?
[21:35:09] Eiam: another option?
[21:35:15] lalalaaa: norc: im afraid that didnt go so well: https://gist.github.com/anonymous/52149d70897b70ed4a00603803c9e460
[21:35:24] hxegon: ?rails Eiam
[21:35:25] ruby[bot]: Eiam: Please join #RubyOnRails for Rails questions. You need to be identified with NickServ, see /msg NickServ HELP
[21:35:27] Eiam: (in one view, the content is inside a popover, in another its a full screen (not inside a popover)
[21:35:30] Eiam: totally not using rails =)
[21:35:42] Eiam: sinatra! but really I don't think the underlying back end matters
[21:36:10] hxegon: alright, just reflexively doing it
[21:36:29] Eiam: hxegon: =) I understand. I am just interested in the design pattern. neither feels great to me
[21:36:33] Eiam: I know how to make both work ofc
[21:37:03] danostrowski: anyone use Sinatra here (possibly on JRuby) and auto-generate API docs from routes? If so, what do you use?
[21:38:51] Eiam: danostrowski: have you checked google? yard seems to have a sintara plugin
[21:38:58] Eiam: danostrowski: https://github.com/rkh/yard-sinatra
[21:39:01] mikecmpbll: has joined #ruby
[21:39:03] yfeldblum: has joined #ruby
[21:39:36] danostrowski: It does, but there's also some chatter about it not working on JRuby and it seems quite old with outstanding issues.
[21:39:39] Eiam: I've just used plain yard in the past.. not sure what value there is in literally reading the code for me and telling me what the code already says.
[21:39:46] danostrowski: (chatter on the 'net about it not working with JRuby)
[21:39:53] Eiam: the extra comments from yard are the value add
[21:40:44] danostrowski: If you're exposing an API to people, it's obviously valuable for them to be able to pull up API docs about how to interact with your service.
[21:41:14] Eiam: right. so my suggestion was document your routes with yard
[21:41:17] Eiam: and have it generate an API
[21:41:45] danostrowski: Oh, I see what you mean.
[21:41:57] Eiam: you don't need any special extensions
[21:41:59] Eiam: just yard
[21:42:09] danostrowski: Sure, I guess I was just hoping there was a tool that did this, I would assume common, task without having to add new documentation to every route.
[21:42:37] dsea: has joined #ruby
[21:43:02] yfeldblum: has joined #ruby
[21:44:09] Eiam: danostrowski: why don't you give it a try on your existing project? yard supports sinatra out of the box..
[21:44:23] danostrowski: OK, will do. Thanks.
[21:44:45] Eiam: maybe by default youll get what you want
[21:44:55] Eiam: (I'm not exactly sure, all my routes are @decorated)
[21:45:28] dfinninger: has joined #ruby
[21:45:31] danostrowski: ACTION hopes so, that would be neat.
[21:45:45] Eiam: sinatra isn't exactly uncommon
[21:45:57] qasaur: has joined #ruby
[21:46:14] Azure: has joined #ruby
[21:46:46] gtsai: has joined #ruby
[21:47:27] jancel: has joined #ruby
[21:48:14] arooni: has joined #ruby
[21:49:24] finisherr: has joined #ruby
[21:51:07] finisherr: has left #ruby: ()
[21:51:21] ledestin: has joined #ruby
[21:55:41] Guest43: has joined #ruby
[21:55:59] gooodroot: has joined #ruby
[21:56:26] Guest43: has joined #ruby
[21:57:27] mdw: has joined #ruby
[21:58:41] jancel: has joined #ruby
[22:00:38] aep: has joined #ruby
[22:01:51] pawnbox: has joined #ruby
[22:02:18] klekot: has joined #ruby
[22:05:49] xerpexes: has joined #ruby
[22:06:14] xerpexes: Hi guys, I'm working on this problem here https://leetcode.com/problems/reconstruct-itinerary/
[22:06:28] xerpexes: Basically the problem boils down to a graph search
[22:06:44] chussenot: has joined #ruby
[22:06:47] mib_mib: has joined #ruby
[22:06:55] xerpexes: I've got a solution using DFS that returns a bunch of arrays of solutions at the end, which I then sort
[22:07:22] mib_mib: hi all - when using 'pry' console, sometimes when i try to paste some code into it, i get a 'help' screen i.e. "SUMMARY OF LESS COMMANDS" almost like a man page and stuff - why is this happening / how do i prevent it?
[22:07:24] xerpexes: I'm wondering if there is some way to use yield rather than return multiple arrays at each step
[22:07:32] QpQ4_: has joined #ruby
[22:07:43] QpQ4_: has left #ruby: ()
[22:08:16] mib_mib: its like the shell or console gets messed up somehwo
[22:12:20] goooodroot: has joined #ruby
[22:12:57] certainty: has joined #ruby
[22:13:27] karthikselva: has joined #ruby
[22:14:08] madgen: has joined #ruby
[22:19:19] Wolland: has joined #ruby
[22:21:40] lightt: has joined #ruby
[22:24:08] rattatmatt: has joined #ruby
[22:25:11] myntcake: has joined #ruby
[22:26:10] solocshaw: has joined #ruby
[22:28:21] millerti: has joined #ruby
[22:29:01] phredus: has joined #ruby
[22:29:40] shevy: https://rubygems.org/stats Total gems: 119,241
[22:29:49] shevy: I'll check on that number again in about a week
[22:32:33] solocshaw1: has joined #ruby
[22:33:25] mikecmpbll: has joined #ruby
[22:34:49] haraigoshi: has joined #ruby
[22:36:04] danostrowski: has joined #ruby
[22:36:19] giz|work: has joined #ruby
[22:36:29] hutch34: has joined #ruby
[22:38:02] gnufied: has joined #ruby
[22:39:30] SilverKey: has joined #ruby
[22:41:24] benlieb: has joined #ruby
[22:42:04] ensyde__: has joined #ruby
[22:42:25] mdw: has joined #ruby
[22:44:13] binaryplease1: has joined #ruby
[22:44:19] gtsai: has joined #ruby
[22:45:43] triangles3: has joined #ruby
[22:50:19] gtsai: has joined #ruby
[22:51:06] chouhoul_: has joined #ruby
[22:52:11] yfeldblum: has joined #ruby
[22:52:46] benlieb_: has joined #ruby
[22:52:55] wrkrcoop: has left #ruby: ()
[22:53:41] kraken: has joined #ruby
[22:54:04] krakenr: is [1, 3 ,4] or [ 1, 3, 4 ] proper styling?
[22:54:13] havenwood: kraken_: the former
[22:54:32] havenwood: you're welcome
[22:55:32] mikecmpbll: has joined #ruby
[22:58:20] despai: has joined #ruby
[22:59:01] firstdayonthejob: has joined #ruby
[22:59:14] jancel: has joined #ruby
[22:59:23] jphase: has joined #ruby
[23:00:32] tildes_: has joined #ruby
[23:00:39] pepee: has joined #ruby
[23:02:21] osiox: has joined #ruby
[23:03:23] osiox: has left #ruby: ("WeeChat 1.4")
[23:04:38] RobertBi_: has joined #ruby
[23:05:17] Azure: has joined #ruby
[23:07:29] Vingador: has joined #ruby
[23:08:43] sima_viniggor: has joined #ruby
[23:08:58] sima_viniggor: what is the most amazing thing created in ruby?
[23:09:08] danostrowski: has joined #ruby
[23:09:11] shevy: sima_viniggor All The Things.
[23:09:15] havenwood: sima_viniggor: depends on the beholder
[23:09:26] jhass: sima_viniggor: http://xiki.org/
[23:10:06] sima_viniggor: jhass: did you make that?
[23:10:12] shevy: that octopus thing
[23:10:16] jhass: never used it either
[23:10:29] GarethAdams: has joined #ruby
[23:10:35] shevy: is that OSX only? :(
[23:10:41] sima_viniggor: why are you saying it's the most amazing if you never used it?
[23:10:47] benlieb: has joined #ruby
[23:10:55] sima_viniggor: shevy: it can't be because ruby is cross platform
[23:11:01] jhass: shevy: don't think so
[23:11:18] shevy: sima_viniggor not everything works equally well or is available on all platforms
[23:12:14] havenwood: jhass: Crystal-lang is a pretty amazing thing created initially in Ruby. ;)
[23:12:27] jhass: yeah, already mentioned last time they asked
[23:12:46] jhass: we got variadic generics today! <3
[23:12:57] shevy: is that like a generic monad
[23:13:10] jhass: no clue, probably not at all
[23:13:44] certainty: has joined #ruby
[23:15:54] jhass: sima_viniggor: so, with a refined inquiry, better results might happen.
[23:16:01] panchiz: has joined #ruby
[23:16:06] sima_viniggor: i'm just curious
[23:16:14] sima_viniggor: i've only seen ruby on rails apps
[23:16:25] sima_viniggor: but i heard that ruby can do anything
[23:16:27] whathappens: has joined #ruby
[23:16:27] nettoweb: has joined #ruby
[23:16:46] jenrzzz: has joined #ruby
[23:16:46] jenrzzz: has joined #ruby
[23:16:51] hahuang65: has joined #ruby
[23:17:09] shevy: what do you need sima_viniggor
[23:17:17] shevy: and you have a peculiar nick
[23:17:52] jhass: sima_viniggor: well there you go, here's a whole programming language that can do everything too, written in Ruby https://github.com/crystal-lang/crystal/tree/04964442a2de0268f63c492b22b17cb502724fc7
[23:18:04] sima_viniggor: sima is my first name and viniggor is the thing you put on salad?
[23:18:07] bhaak: has joined #ruby
[23:19:14] sima_vinegar: bad english :/
[23:19:27] havenwood: sima_vinegar: https://github.com/trending/ruby
[23:19:41] lalalaaa: jhass: Are you running any social networks yourself?
[23:19:50] lalalaaa: Or similar apps
[23:20:00] jhass: I do run a diaspora* node
[23:20:07] nettoweb: has joined #ruby
[23:20:11] havenwood: sima_vinegar: https://github.com/search?l=ruby&q=stars%3A%3E1&s=updated&type=Repositories
[23:20:43] paul0: has joined #ruby
[23:21:08] sima_vinegar: i'm currently in college, but i met a guy at starbucks who said that i am wasting my time going to school for computer science and that i don't even need a degree to work as a programmer
[23:21:10] sima_vinegar: how true is that?
[23:21:20] sima_vinegar: this was the other yesterday
[23:21:25] Wolland: has joined #ruby
[23:21:39] jhass: it is both true and bullshit
[23:21:48] sima_vinegar: how can it be both?
[23:21:53] sima_vinegar: aren't they opposites?
[23:21:57] jhass: yes you can get a job without a degree
[23:22:00] havenwood: >> [true, false].sample
[23:22:01] ruby[bot]: havenwood: # => true (https://eval.in/584395)
[23:22:03] jhass: no, you're not wasting your time
[23:22:25] nettoweb: has joined #ruby
[23:22:26] lalalaaa: im not getting a degree. im spending my time trying to build apps to make me rich instead.
[23:22:27] sima_vinegar: what will it take to get a job without a degree?
[23:22:50] havenwood: sima_vinegar: learning ruby and being a nice person who folk would like to work with should more than do the trick
[23:22:51] sima_vinegar: if it is possible which doesn't make sense to me
[23:22:57] elomatreb: Taking career advice from a guy you met at starbucks?
[23:22:58] lalalaaa: sima_vinegar: insaaaaaaaaane charisma :P
[23:23:11] havenwood: with a few points in dexterity
[23:23:53] sima_vinegar: the guy claims to work at google
[23:24:05] benlieb: has joined #ruby
[23:24:24] havenwood: sima_vinegar: google favors CS degrees, but they do hire those without and there are many other companies
[23:24:35] nettoweb: has joined #ruby
[23:24:48] havenwood: and i'm sure it's a big enough company that even that isn't true - many, many jobs
[23:24:51] elomatreb: Time spent learning is not wasted though
[23:25:14] CloCkWeRX: has joined #ruby
[23:25:44] jhass: ^ my point
[23:26:03] jhass: don't eat the FUD
[23:26:04] sima_vinegar: oh so it's better if i finish my degree then right
[23:26:10] sima_vinegar: what's a FUD?
[23:26:20] flashpoint9: has joined #ruby
[23:26:30] jhass: https://github.com/crystal-lang/crystal/tree/04964442a2de0268f63c492b22b17cb502724fc7
[23:26:31] sima_vinegar: i'm sure it's not thishttp://www.urbandictionary.com/define.php?term=FUD
[23:26:35] jhass: https://en.wikipedia.org/wiki/Fear,_uncertainty_and_doubt
[23:26:36] havenwood: sima_vinegar: random chance probably has a larger determining factor in your future than whether you finish the degree. FUD is fear, uncertainty and doubt.
[23:26:41] jhass: my clipboard is broken today
[23:27:16] nettoweb: has joined #ruby
[23:27:28] sima_vinegar: ok thanks hadronzoo
[23:27:38] elomatreb: Keep in mind that a degree usually teaches you other valuable skills besides "just" programming, like scientific process or statistics
[23:27:52] sima_vinegar: what about a 2 year degree?
[23:28:09] sima_vinegar: will it be better to just get a 2 year degree or a 4 year?
[23:28:10] shevy: do you not have time
[23:28:27] shevy: a one year degree
[23:28:30] sima_vinegar: i'm in community college because i want to save money
[23:28:53] elomatreb: But I'm maybe not the best person to ask about this, as I still go to school
[23:29:06] sima_vinegar: my dad gave me all the money he saved up for me and i can become anyone i want without scholarships
[23:29:23] nankyokusei: has joined #ruby
[23:29:27] nettoweb: has joined #ruby
[23:29:34] sima_vinegar: but i would like to save it and make money from that money
[23:30:36] elomatreb: There are probably better places to ask for advice for your future than a Ruby IRC channel
[23:30:42] pepee: has joined #ruby
[23:30:49] sima_vinegar: oh i figured most people here were already professionals
[23:31:14] havenwood: sima_vinegar: most probably are, but there are so many paths to becoming so it's hard to generalize
[23:31:31] havenwood: sima_vinegar: the one thing we all share is reading and writing Ruby
[23:31:46] nettoweb: has joined #ruby
[23:31:59] jhass: what worked somebody doesn't have to work for you and what doesn't work for somebody can work for you
[23:33:23] sima_vinegar: i am going to figure it out
[23:33:40] sima_vinegar: maybe i'll switch majors and go to something where i'll make more money like financing or something in wall street
[23:33:57] havenwood: sima_vinegar: do what you love
[23:34:08] jhass: money as sole objective rarely made a good programmer, so yeah maybe
[23:34:22] sima_vinegar: but i enjoy making things on the computer
[23:34:26] sima_vinegar: even though it's hard for me
[23:34:27] phredus: has joined #ruby
[23:34:29] sima_vinegar: i think it's really cool
[23:34:51] hxegon: sima_vinegar: check out fintech
[23:34:55] jdelaney: has joined #ruby
[23:35:36] sima_vinegar: thanks hxegon
[23:35:45] sima_vinegar: later everyone i hope you have a great time doing what it is you're doing :)
[23:35:50] sima_vinegar: has left #ruby: ()
[23:37:22] charliesome: has joined #ruby
[23:37:25] jdelaney: has left #ruby: ()
[23:37:41] dionysus69: has joined #ruby
[23:39:39] mtkd: has joined #ruby
[23:40:17] RobertBirnie: has joined #ruby
[23:40:45] David27: has joined #ruby
[23:40:51] koooge: has joined #ruby
[23:41:04] wrkrcoop: has joined #ruby
[23:41:04] lightt: has joined #ruby
[23:41:16] wrkrcoop: is there a way to set a default value in a hash
[23:41:21] wrkrcoop: a = {"steve" => jeff =|| "bob"}
[23:41:29] lightt: has joined #ruby
[23:43:11] allcentury: has joined #ruby
[23:47:21] tildes_: has joined #ruby
[23:48:35] Respek: has joined #ruby
[23:49:41] jackjackdripper1: has joined #ruby
[23:50:51] jenrzzz: has joined #ruby
[23:52:26] wrkrcoop: just used a method to check if nil or not
[23:52:48] elomatreb: wrkrcoop: There's Hash#merge, which might be useful: http://ruby-doc.org/core-2.3.1/Hash.html#method-i-merge
[23:54:06] charliesome: has joined #ruby
[23:54:19] pepee: has joined #ruby
[23:55:37] gooooodroot: has joined #ruby
[23:56:11] arlek: has joined #ruby
[23:56:54] weemsledeux: has joined #ruby