« Back to channel list

#ruby - 15 August 2017

« Back 1 day Forward 1 day »
[00:00:28] Joufflu_Fail: has joined #ruby
[00:00:32] Derperperd: has joined #ruby
[00:00:40] infernix: has joined #ruby
[00:01:13] AustinMatherne: has joined #ruby
[00:01:30] uZiel: has joined #ruby
[00:01:30] aglorei1: has joined #ruby
[00:01:30] _aeris_: has joined #ruby
[00:02:01] boshhead: has joined #ruby
[00:02:17] quiller: has joined #ruby
[00:02:24] goyox86: has joined #ruby
[00:03:35] FastJack: has joined #ruby
[00:03:35] darix: has joined #ruby
[00:03:35] Cork: has joined #ruby
[00:03:35] mayamai: has joined #ruby
[00:03:35] tomaw: has joined #ruby
[00:03:57] boshhead: has joined #ruby
[00:04:00] okdas: has joined #ruby
[00:04:01] infernix: has joined #ruby
[00:04:02] edwardly: has joined #ruby
[00:04:06] KramerC: has joined #ruby
[00:04:22] armyriad: has joined #ruby
[00:04:22] electrostat: has joined #ruby
[00:04:23] BSaboia: has joined #ruby
[00:04:23] kculpis: has joined #ruby
[00:04:23] byte512: has joined #ruby
[00:04:23] ikopico: has joined #ruby
[00:04:23] nchambers: has joined #ruby
[00:04:23] DenSchub: has joined #ruby
[00:04:24] TomyLobo: has joined #ruby
[00:04:24] seitensei: has joined #ruby
[00:04:24] mtkd: has joined #ruby
[00:04:24] nobitanobi: has joined #ruby
[00:04:24] m27frogy: has joined #ruby
[00:04:28] bogdanteleaga: has joined #ruby
[00:04:39] sindork: has joined #ruby
[00:04:51] nicoulaj: has joined #ruby
[00:04:54] jphase: has joined #ruby
[00:05:10] giraffe: has joined #ruby
[00:05:33] WebDawg: has joined #ruby
[00:05:53] thinkpad: has joined #ruby
[00:06:16] duderonomy: has joined #ruby
[00:06:16] ahrs: has joined #ruby
[00:06:21] aglorei1: has joined #ruby
[00:06:43] hahuang65: has joined #ruby
[00:09:45] MissionCritical: has joined #ruby
[00:09:56] skweek: has joined #ruby
[00:11:55] Tagami[m]: has joined #ruby
[00:13:00] brent__: has joined #ruby
[00:13:12] skweek: has joined #ruby
[00:13:13] bruno-: has joined #ruby
[00:13:20] jenrzzz: has joined #ruby
[00:14:57] funkateer: has joined #ruby
[00:16:14] kiero: has joined #ruby
[00:17:19] hahuang65: has joined #ruby
[00:18:24] afromankenobi: has joined #ruby
[00:19:26] funkycrunchy: has joined #ruby
[00:19:50] kiero: has joined #ruby
[00:23:51] elcontrastador: has joined #ruby
[00:27:36] aidalgol: has joined #ruby
[00:27:37] joenas[m]: has joined #ruby
[00:27:37] yana[m]: has joined #ruby
[00:27:37] M107262[m]: has joined #ruby
[00:27:37] jonjits[m]: has joined #ruby
[00:27:37] torarne: has joined #ruby
[00:27:37] aviraldg: has joined #ruby
[00:27:38] gokul_mr[m]: has joined #ruby
[00:27:38] KevinMGranger: has joined #ruby
[00:27:38] turt2live: has joined #ruby
[00:27:38] dman[m]: has joined #ruby
[00:27:38] Giphy[m]: has joined #ruby
[00:27:38] heftig: has joined #ruby
[00:27:38] lasenna[m]: has joined #ruby
[00:27:44] Matt[m]1: has joined #ruby
[00:27:44] aagdbl[m]: has joined #ruby
[00:27:45] velu_aon[m]: has joined #ruby
[00:28:42] xuanrui: has joined #ruby
[00:28:51] Silthias: has joined #ruby
[00:29:44] funkycrunchy: has joined #ruby
[00:39:59] NeverTired: has joined #ruby
[00:40:15] sagax: has joined #ruby
[00:46:21] __Yiota: has joined #ruby
[00:48:30] perniciouscaffei: has joined #ruby
[00:50:15] carnegie: has joined #ruby
[00:51:20] wilbert_: has joined #ruby
[00:55:16] _aeris_: has joined #ruby
[00:55:48] jphase: has joined #ruby
[00:58:10] aglorei1: has joined #ruby
[00:58:20] mtkd: has joined #ruby
[01:00:52] tAn: has joined #ruby
[01:01:21] funkycrunchy: has joined #ruby
[01:02:10] nopolitica: has joined #ruby
[01:08:22] alfiemax: has joined #ruby
[01:09:52] senera: has joined #ruby
[01:10:47] milardovich: has joined #ruby
[01:11:45] Derperperd: has joined #ruby
[01:14:08] Silthias: has joined #ruby
[01:14:25] gix: has joined #ruby
[01:15:48] s3nd1v0g1us: has joined #ruby
[01:17:23] afromankenobi: has joined #ruby
[01:18:16] frozengeek_: has joined #ruby
[01:19:46] s3nd1v0g1us: has joined #ruby
[01:19:57] gizmore|2: has joined #ruby
[01:21:54] uZiel: has joined #ruby
[01:29:43] jtperreault: has joined #ruby
[01:35:54] mwlang: has joined #ruby
[01:42:07] MrBismuth: has joined #ruby
[01:43:30] dionysus69: has joined #ruby
[01:44:15] duderonomy: has joined #ruby
[01:51:09] astrobunny: has joined #ruby
[01:56:12] belmoussaoui_: has joined #ruby
[01:58:02] afromankenobi: has joined #ruby
[02:00:38] ecuanaso: has joined #ruby
[02:02:38] PorcoRex: has joined #ruby
[02:02:52] PorcoRex: Evening Ruby.
[02:03:15] harfangk: has joined #ruby
[02:04:04] Guest19682: has joined #ruby
[02:09:20] cdg: has joined #ruby
[02:11:02] Dimik: has joined #ruby
[02:14:54] AnoHito: has joined #ruby
[02:17:09] beilabs: has joined #ruby
[02:19:10] umaaji: has joined #ruby
[02:22:53] milardovich: has joined #ruby
[02:25:42] Silthias1: has joined #ruby
[02:29:02] ramfjord: has joined #ruby
[02:31:09] bougyman: rvm doesn't work under #/bin/sh
[02:31:15] bougyman: took me like 10 minutes to figure that out.
[02:32:27] jinie_: has joined #ruby
[02:37:29] belmoussaoui: has joined #ruby
[02:40:52] tAn: has joined #ruby
[02:41:39] sneep: Anyone else living in the Ruby City?
[02:41:47] ozcanesen: has joined #ruby
[02:47:43] afromankenobi: has joined #ruby
[02:48:31] afromankenobi: has joined #ruby
[02:49:19] afromankenobi: has joined #ruby
[02:50:08] afromankenobi: has joined #ruby
[02:50:55] afromankenobi: has joined #ruby
[02:52:00] afromankenobi: has joined #ruby
[02:54:50] elcontrastador: has joined #ruby
[02:57:55] __Yiota: has joined #ruby
[02:58:13] cagomez: has joined #ruby
[03:00:09] cadillac_: has joined #ruby
[03:01:48] skweek: has joined #ruby
[03:03:32] goyox86: has joined #ruby
[03:07:39] carnegie: has joined #ruby
[03:10:24] alfiemax: has joined #ruby
[03:11:41] kn-928: has joined #ruby
[03:15:32] xuanrui: has joined #ruby
[03:16:01] m27frogy: has joined #ruby
[03:21:32] tacotime: has joined #ruby
[03:23:14] m27frogy: has joined #ruby
[03:26:57] ur5us: has joined #ruby
[03:30:46] afromankenobi: has joined #ruby
[03:38:45] m27frogy: has joined #ruby
[03:40:15] funkycrunchy: has joined #ruby
[03:41:48] nacsurte: has joined #ruby
[03:42:48] alfiemax: has joined #ruby
[03:45:41] govg: has joined #ruby
[03:47:03] nofxxx: has joined #ruby
[03:49:18] tAn: has joined #ruby
[03:49:29] DTZUZO: has joined #ruby
[03:49:35] Silthias: has joined #ruby
[03:52:27] nobitanobi: has joined #ruby
[03:52:38] cdg_: has joined #ruby
[03:54:22] DTZUZO: has joined #ruby
[03:55:06] cadillac_: has joined #ruby
[03:56:25] gix: has joined #ruby
[03:57:01] opekktar: has joined #ruby
[04:02:13] justin_pdx: has joined #ruby
[04:04:42] creeg: has joined #ruby
[04:06:10] _whitelogger: has joined #ruby
[04:07:06] joenas[m]: has joined #ruby
[04:07:34] aagdbl[m]: has joined #ruby
[04:07:49] RealMarc: has joined #ruby
[04:08:15] alamar: has joined #ruby
[04:09:02] vondruch: has joined #ruby
[04:09:35] benjen: has joined #ruby
[04:12:38] hoangtg: has joined #ruby
[04:12:43] milardovich: has joined #ruby
[04:14:28] vondruch: has joined #ruby
[04:18:01] shortdudey123: has joined #ruby
[04:21:38] kculpis: has joined #ruby
[04:24:42] Puffball_: has joined #ruby
[04:28:40] oleo: has joined #ruby
[04:28:54] milardovich: has joined #ruby
[04:35:08] naprimer2: has joined #ruby
[04:38:21] nacsurte: has joined #ruby
[04:39:54] phate408: has joined #ruby
[04:41:42] aupadhye: has joined #ruby
[04:42:43] watzon: has joined #ruby
[04:43:30] runescape07rsps: has joined #ruby
[04:43:34] watzon: So weird, I can join #ruby but not #rubyonrails
[04:44:36] uZiel: has joined #ruby
[04:48:46] worknick: has joined #ruby
[04:48:59] worknick: how to connect to Push API in WAMP websocket?
[04:55:42] Puffball: has joined #ruby
[04:56:55] roboncloud: @watzon i think you need to be identified to join #rubyonrails becos DHH is a troll magnet
[04:56:58] funkycrunchy: has joined #ruby
[04:57:40] watzon: I am identified though haha. I even re-identified just to make sure
[04:58:01] roboncloud: what happens when you join..?
[04:59:13] roboncloud: you might have a happier life if you don't join anyway.
[05:01:19] watzon: I just get error `err_needreggednick`, you’re probably right though haha
[05:02:02] roboncloud: it depends what you're interested in but i don't consider the quality of conversation in that channel to be great
[05:02:42] watzon: Chances are I won’t need their help anyway
[05:09:11] tAn: has joined #ruby
[05:12:30] Bock: has joined #ruby
[05:15:05] djbkd: has joined #ruby
[05:22:12] hahuang65: has joined #ruby
[05:25:06] PaulCapestany: has joined #ruby
[05:28:58] dymaxion_: has joined #ruby
[05:32:27] nacsurte: has joined #ruby
[05:32:28] AxelAlex: has joined #ruby
[05:34:18] Radar: watzon: according to /whois you're not registered with Nickserv.
[05:34:44] Radar: roboncloud: It's because we used to get a lot of spammers in the channel.
[05:34:59] Radar: watzon: /msg nickserv identify <your password>
[05:39:37] Silthias1: has joined #ruby
[05:40:43] afromankenobi: has joined #ruby
[05:43:29] Puffball: has joined #ruby
[05:45:20] ur5us: has joined #ruby
[05:45:55] harfangk: has joined #ruby
[05:52:39] quobo: has joined #ruby
[05:55:16] alfiemax: has joined #ruby
[05:55:50] uZiel: has joined #ruby
[05:57:13] djbkd: has joined #ruby
[05:58:08] Moosashi: has joined #ruby
[06:02:03] alfiemax: has joined #ruby
[06:03:12] Moosashi: has joined #ruby
[06:10:42] claw: has joined #ruby
[06:10:56] alfiemax_: has joined #ruby
[06:11:55] ramfjord: has joined #ruby
[06:13:32] kies: has joined #ruby
[06:13:34] ur5us: has joined #ruby
[06:15:02] ur5us: has joined #ruby
[06:18:56] high_fiver: has joined #ruby
[06:20:21] Guest46105: has joined #ruby
[06:23:19] Silthias: has joined #ruby
[06:23:28] aglorei1: has joined #ruby
[06:25:38] Guest53: has joined #ruby
[06:25:39] aglorei1: has joined #ruby
[06:26:30] nacsurte: has joined #ruby
[06:27:54] nofxxxx: has joined #ruby
[06:27:56] elcontrastador: has joined #ruby
[06:27:56] rann: has joined #ruby
[06:29:15] djbkd: has joined #ruby
[06:29:53] carnegie: has joined #ruby
[06:30:34] funkycrunchy: has joined #ruby
[06:31:13] alfiemax: has joined #ruby
[06:46:40] astrobunny: has joined #ruby
[06:52:20] Silthias1: has joined #ruby
[06:53:22] beilabs: has joined #ruby
[06:54:57] Guest65270: has joined #ruby
[06:55:54] graingert: has joined #ruby
[06:57:29] conta: has joined #ruby
[06:57:32] workmad3: has joined #ruby
[06:58:20] Silthias: has joined #ruby
[07:02:16] djbkd: has joined #ruby
[07:03:14] dionysus69: has joined #ruby
[07:07:29] dionysus69: has joined #ruby
[07:07:54] Mortomes|Work: has joined #ruby
[07:09:10] alfiemax: has joined #ruby
[07:12:56] tAn: has joined #ruby
[07:13:08] TomyWork: has joined #ruby
[07:14:29] cagomez: has joined #ruby
[07:18:27] akkad: has joined #ruby
[07:20:41] nacsurte: has joined #ruby
[07:21:38] marchi: has joined #ruby
[07:23:19] anas: has joined #ruby
[07:23:20] hahuang65: has joined #ruby
[07:27:57] djbkd: has joined #ruby
[07:28:56] twe4ked: has joined #ruby
[07:36:03] TomyWork: has joined #ruby
[07:37:02] KeyJoo: has joined #ruby
[07:37:10] alex``: has joined #ruby
[07:43:09] burgestrand: has joined #ruby
[07:45:25] cagomez: has joined #ruby
[07:49:33] ur5us: has joined #ruby
[07:54:26] bladdezz: has joined #ruby
[07:54:54] Mia: has joined #ruby
[07:57:11] ams__: has joined #ruby
[07:57:11] SteenJobs: has joined #ruby
[07:57:58] mathys: has joined #ruby
[07:59:23] aufi: has joined #ruby
[08:01:13] InfinityFye: has joined #ruby
[08:01:20] cagomez: has joined #ruby
[08:09:08] rgr: has joined #ruby
[08:10:12] mikecmpbll: has joined #ruby
[08:14:44] nacsurte: has joined #ruby
[08:15:15] jaruga: has joined #ruby
[08:15:21] alfiemax: has joined #ruby
[08:17:42] kapil___: has joined #ruby
[08:18:09] burgestrand: has joined #ruby
[08:18:21] tvw: has joined #ruby
[08:22:32] biberu: has joined #ruby
[08:23:59] hahuang65: has joined #ruby
[08:25:12] djbkd: has joined #ruby
[08:31:54] marchi: has joined #ruby
[08:47:28] huyderman: has joined #ruby
[09:00:13] _whitelogger: has joined #ruby
[09:00:49] Beams: has joined #ruby
[09:03:05] cagomez: has joined #ruby
[09:03:23] mtkd: has joined #ruby
[09:04:49] SteenJobs: has joined #ruby
[09:08:54] nacsurte: has joined #ruby
[09:11:06] jenrzzz: has joined #ruby
[09:11:06] jenrzzz: has joined #ruby
[09:18:23] marchi: has joined #ruby
[09:19:04] cagomez: has joined #ruby
[09:19:46] marchi: has joined #ruby
[09:25:47] djbkd: has joined #ruby
[09:29:14] lexruee: has joined #ruby
[09:29:14] charliesome: has joined #ruby
[09:37:16] uZiel: has joined #ruby
[09:39:16] lexruee_: has joined #ruby
[09:40:23] Guest53: has joined #ruby
[09:40:49] rgr_: has joined #ruby
[09:46:21] belmoussaoui: has joined #ruby
[09:48:32] eroux: has joined #ruby
[09:49:58] cagomez: has joined #ruby
[09:50:21] ur5us: has joined #ruby
[09:55:28] belmoussaoui: has joined #ruby
[09:58:18] lexruee__: has joined #ruby
[10:02:56] nacsurte: has joined #ruby
[10:07:06] sepp2k: has joined #ruby
[10:09:46] howdoi: has joined #ruby
[10:17:32] mjolnird: has joined #ruby
[10:22:22] nobitanobi: has joined #ruby
[10:24:52] hahuang65: has joined #ruby
[10:32:02] nobitanobi: has joined #ruby
[10:34:08] sleetdrop: has joined #ruby
[10:39:07] gr33n7007h: good morning rublings
[10:39:37] harfangk: has joined #ruby
[10:45:08] dymaxion_: has joined #ruby
[10:52:22] apparition: has joined #ruby
[10:55:16] charliesome: has joined #ruby
[10:55:23] frozengeek_: has joined #ruby
[10:57:02] nacsurte: has joined #ruby
[11:01:01] ahrs: has joined #ruby
[11:04:00] m27frogy: has joined #ruby
[11:05:56] belmoussaoui: has joined #ruby
[11:11:30] belmoussaoui: has joined #ruby
[11:12:31] t-recx: has joined #ruby
[11:15:42] charliesome_: has joined #ruby
[11:23:19] m27frogy: has joined #ruby
[11:26:00] yosafbridge: has joined #ruby
[11:26:53] adlerdias: has joined #ruby
[11:29:39] ahrs: has joined #ruby
[11:35:33] ldnunes: has joined #ruby
[11:39:08] charliesome: has joined #ruby
[11:41:54] VladGh: has joined #ruby
[11:45:36] chouhoulis: has joined #ruby
[11:46:55] charliesome: has joined #ruby
[11:50:07] sagax: has joined #ruby
[11:51:12] nacsurte: has joined #ruby
[11:52:08] rikai: has joined #ruby
[11:54:15] cagomez: has joined #ruby
[11:56:02] Seenox: has joined #ruby
[11:57:00] charliesome: has joined #ruby
[11:58:11] guardianx: has joined #ruby
[12:01:25] uZiel: has joined #ruby
[12:01:42] chmurifree: has joined #ruby
[12:02:39] xcesariox: has joined #ruby
[12:03:26] dminuoso: apeiros: Encoding expert!
[12:06:35] uZiel: has joined #ruby
[12:07:08] synthroid: has joined #ruby
[12:07:13] aglorei1: has joined #ruby
[12:07:17] dminuoso: I have a codepoint 0xA7 that is supposed to represent ß - encoding could this possibly be?
[12:07:28] roboncloud: it's easy to be an encoding expert when the alphabet of your native tongue isn't only ascii.
[12:08:46] laekur: has joined #ruby
[12:09:26] dminuoso: roboncloud: I have tested all ~200 encodings ruby is aware of
[12:09:50] _aeris_: has joined #ruby
[12:09:51] dminuoso: None of them knows this to be an ß
[12:10:28] roboncloud: what's your test code look like?
[12:11:33] dminuoso: roboncloud: Encoding.constants.map { |e| begin 0xa7.chr(Encoding.const_get(e)); rescue; end }
[12:12:43] bmurt: has joined #ruby
[12:14:59] roboncloud: p Encoding.constants.find { |e|
[12:14:59] roboncloud: if not Exception === e
[12:14:59] roboncloud: 0xa7.chr(Encoding.const_get(e))
[12:15:05] roboncloud: i get :ASCII_8BIT
[12:17:20] roboncloud: p Encoding.constants.map { |e|
[12:17:20] roboncloud: if not Exception === e
[12:17:20] roboncloud: x = 0xa7.chr(Encoding.const_get(e)) rescue nil
[12:17:23] dminuoso: roboncloud: That's not enough
[12:17:24] roboncloud: many encodings there..
[12:17:29] dminuoso: There's quite a handful of encodings where that codepoint is valid.
[12:17:38] dminuoso: But none of them represent ß
[12:17:51] dminuoso: The bizarre thing is, macOS Textedit implicitly knows the encoding
[12:17:57] dminuoso: file -I fails however
[12:18:03] bruno-: has joined #ruby
[12:18:06] roboncloud: yeah.. for 165 of them it's valid.
[12:18:21] dminuoso: roboncloud: now print those ;)
[12:19:54] roboncloud: # coding: utf-8
[12:19:54] roboncloud: p Encoding.constants.map { |e|
[12:19:54] roboncloud: if not Exception === e
[12:19:54] roboncloud: x = 0xa7.chr(Encoding.const_get(e)) rescue nil
[12:19:55] roboncloud: }.compact.find {|e|
[12:19:55] roboncloud: 0xa7.chr(Encoding.const_get(e)) == "ß"
[12:20:28] dminuoso: Haha I like that exception handling
[12:20:44] lxnr: has joined #ruby
[12:21:22] charliesome: has joined #ruby
[12:21:51] ineb: yeah. that code is truly worth to be posted line by line
[12:22:24] lxnr: has left #ruby: ()
[12:23:31] dminuoso: roboncloud: Well there is an encoding, TextEdit can handle it/
[12:23:35] dminuoso: But.. I got an idea.
[12:24:14] roboncloud: i thought one of the awesome things about encodings in ruby is suppose to be that it supported all of them
[12:24:19] Papierkorb: roboncloud: It would be really nice if you could use a paste service like https://gist.github.com/ instead of pasting large swaths of code directly into the channel.
[12:24:35] dminuoso: Papierkorb: Dont fix his behavior, fix my encoding!
[12:24:48] roboncloud: yeah. sorry, my irc client usually does it but didn't this time.
[12:25:00] Papierkorb: roboncloud: It hasn't done it either yesterday.
[12:25:13] roboncloud: what did i paste yesterday?
[12:25:44] hahuang65: has joined #ruby
[12:26:07] Papierkorb: roboncloud: No idea, can't be bothered to look up tbh. Yesterday chunks of code were posted here all the time, so I simply assumed it was you. Apologies if I'm wrong.
[12:26:20] bmurt: has joined #ruby
[12:26:31] roboncloud: well, if you have "no idea" then yes, you shouldn't throw accusations around.
[12:26:51] roboncloud: but probably i did, so i will fix the client
[12:27:10] DTZUZO: has joined #ruby
[12:27:25] dminuoso: roboncloud: also turns out we have Encoding.list :P
[12:29:17] guardianx: has joined #ruby
[12:29:57] chouhoulis: has joined #ruby
[12:33:26] dminuoso: roboncloud: THe thing that majorly throws me off is that textedit understands it
[12:33:29] dminuoso: And its not Mac Os Roman
[12:33:41] dminuoso: There's also nothing in extended file attributes
[12:35:56] roboncloud: could try with iconv i guess..
[12:37:01] dminuoso: roboncloud: iconv cant guess, it just converts based on specified encodings
[12:37:05] dminuoso: essentially what we just did with ruby
[12:37:21] dminuoso: though I could probably iterate over all available encodings until I find the one that doesnt mojibake
[12:37:41] roboncloud: yea. worth a shot
[12:39:11] uZiel: has joined #ruby
[12:45:04] gr33n7007h: hmm, that's weird
[12:45:18] nacsurte: has joined #ruby
[12:46:47] dminuoso: Still no luck. What is going on ?
[12:47:56] K3rber0s: has joined #ruby
[12:48:20] roboncloud: does textedit display the encoding its using?
[12:48:44] __Yiota: has joined #ruby
[12:49:26] dminuoso: But I found one mistake I did. There's an extended attribute, denoting the encoding as "macintosh;"
[12:50:46] roboncloud: if you paste the char into textedit, save, then read in ruby with: `p File.binread(..)`. what's it look like?
[12:51:57] dminuoso: Yes thats it!
[12:52:11] dminuoso: My iconv trick must have had a bug. I's the standardized macintosh encoding.
[12:52:14] cdg: has joined #ruby
[12:52:22] roboncloud: so what encoding is it?
[12:52:39] dminuoso: That is an actual character encoding it turns out
[12:52:46] dminuoso: https://encoding.spec.whatwg.org/index-macintosh.txt
[12:52:49] dminuoso: The really strange thing though is.
[12:52:58] dminuoso: That code point thing..
[12:53:31] roboncloud: does the ruby method work now?
[12:53:35] roboncloud: without iconv
[12:53:52] dminuoso: roboncloud: ruby does not have that encoding
[12:55:00] kapil___: has joined #ruby
[12:55:57] dminuoso: roboncloud: the rfc says differently though...
[12:56:55] roboncloud: ah ok, yea prefer not to start my morning with RFCs.
[12:58:30] dminuoso: Oh well that was painful
[12:59:44] nopolitica: has joined #ruby
[13:02:58] anas: has joined #ruby
[13:03:13] charliesome: has joined #ruby
[13:03:37] bmurt: has joined #ruby
[13:04:48] Polymorphism: has joined #ruby
[13:04:50] Polymorphism: I still love ruby
[13:05:11] Polymorphism: if I need to make something fast or anything involving web its my go-to
[13:05:14] Polymorphism: elegant, beautiful, clean
[13:05:55] milardovich: has joined #ruby
[13:06:37] nacsurte: has joined #ruby
[13:08:07] DTZUZO: has joined #ruby
[13:11:12] roboncloud: most of the time :P
[13:13:43] banisterfiend: has joined #ruby
[13:15:16] raynold: has joined #ruby
[13:15:55] milardov_: has joined #ruby
[13:18:42] aufi: has joined #ruby
[13:20:10] Mon_Ouie: has joined #ruby
[13:20:47] jinie_: has joined #ruby
[13:21:30] charliesome_: has joined #ruby
[13:22:20] jphase: has joined #ruby
[13:23:01] dminuoso: Polymorphism: I wouldnt go as far as calling it clean
[13:26:46] konsolebox: has joined #ruby
[13:31:59] bmurt: has joined #ruby
[13:34:47] gnufied: has joined #ruby
[13:35:45] charliesome: has joined #ruby
[13:38:15] ana__: has joined #ruby
[13:38:25] anas: has joined #ruby
[13:38:33] oleo: has joined #ruby
[13:39:42] aufi_: has joined #ruby
[13:42:23] uZiel: has joined #ruby
[13:44:05] anas: has joined #ruby
[13:44:46] charliesome_: has joined #ruby
[13:45:50] dymaxion_: has joined #ruby
[13:47:23] Joufflu_Fail: has joined #ruby
[13:47:39] MichaelBurge: has joined #ruby
[13:50:39] bmurt: has joined #ruby
[13:53:45] eb0t: has joined #ruby
[13:56:28] __Yiota: has joined #ruby
[14:00:38] ahrs: has joined #ruby
[14:03:20] arne: has joined #ruby
[14:03:29] arne: anyone familiar with faye-websocket?
[14:03:43] gr33n7007h: anyone know why `int uuid_generate_time_safe(uuid_t out);` works in C but return -1 with ffi bindings?
[14:03:47] arne: im trying to send a messag eto all websockets, how woulld i do that+
[14:03:54] bmurt: has joined #ruby
[14:04:30] Papierkorb: arne: you just keep a list of clients around, and send one to #each
[14:05:35] NeverTired: has joined #ruby
[14:05:39] Guest53: has joined #ruby
[14:06:18] polishdub: has joined #ruby
[14:06:22] Papierkorb: arne: in the simplest case, a @@class_var where each client adds itself to on connect, and removes itself on disconnect. That's quite crude, but for fine for prototyping (or getting started)
[14:06:45] arne: Papierkorb: hmpf, okay
[14:07:17] Papierkorb: arne: For more production-oriented stuff, I commonly have a ClientManager or similar offering a #broadcast
[14:07:28] arne: nah it's just a PoC
[14:07:35] arne: still depressed about the way i have to do this with ruby
[14:07:41] gr33n7007h: disregard what i just said, i didn't read the man page properly
[14:07:50] Papierkorb: arne: "about the way"?
[14:07:59] arne: yes, this is not very clean
[14:08:21] herwin: which is often true for PoCs
[14:12:31] bmurt: has joined #ruby
[14:14:34] Mon_Ouie: has joined #ruby
[14:16:03] chouhoul_: has joined #ruby
[14:18:25] carnegie: has joined #ruby
[14:20:13] ResidentBiscuit: has joined #ruby
[14:24:19] Mon_Ouie: has joined #ruby
[14:24:56] bmurt: has joined #ruby
[14:25:53] Rapture: has joined #ruby
[14:27:17] hahuang65: has joined #ruby
[14:31:11] nopolitica: has joined #ruby
[14:35:16] brahmana: has joined #ruby
[14:35:37] bmurt: has joined #ruby
[14:36:42] goyox86: has joined #ruby
[14:43:19] Caerus: has joined #ruby
[14:45:14] carnegie: has joined #ruby
[14:45:53] armando: has joined #ruby
[14:48:59] theunraveler: has joined #ruby
[14:50:29] nopoliti1: has joined #ruby
[14:50:35] bruno-: has joined #ruby
[14:51:38] wkoszek: has joined #ruby
[14:51:46] xall: has joined #ruby
[14:56:12] dionysus69: has joined #ruby
[14:57:14] Guest53: has joined #ruby
[14:59:18] bmurt: has joined #ruby
[15:00:36] charliesome: has joined #ruby
[15:01:41] ecuanaso: has joined #ruby
[15:02:33] armando: has joined #ruby
[15:03:02] ltem: has joined #ruby
[15:03:58] ozcanesen: has joined #ruby
[15:07:18] armando: has joined #ruby
[15:07:53] cdg: has joined #ruby
[15:09:05] universa1: has joined #ruby
[15:11:08] cdg: has joined #ruby
[15:17:15] mikecmpbll: has joined #ruby
[15:20:09] TomyLobo: has joined #ruby
[15:26:30] armando: has joined #ruby
[15:29:27] Fin1te: has joined #ruby
[15:30:34] cagomez: has joined #ruby
[15:30:37] setuid: has joined #ruby
[15:30:56] setuid: Is there a web-based ruby profiler, something like jqplay, for testing conditionals, filters, things like that?
[15:31:17] setuid: I'm profiling a conditional change to a stanard if... else... then... test
[15:32:54] havenwood: setuid: It's not web-based but benchmark-ips is a good tool: https://github.com/evanphx/benchmark-ips#readme
[15:34:11] setuid: havenwood: I'll pastebin something, just making sure I've got this syntactically correct:
[15:34:32] ruby[bot]: https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
[15:36:08] armando: has joined #ruby
[15:36:48] nacsurte: has joined #ruby
[15:36:55] setuid: Does this look right? https://paste.debian.net/hidden/023b9443/
[15:37:36] cdg: has joined #ruby
[15:39:29] BlueDragons: has joined #ruby
[15:39:58] brent__: has joined #ruby
[15:40:38] jamesaxl: has joined #ruby
[15:43:25] bmurt: has joined #ruby
[15:43:30] cdg: has joined #ruby
[15:44:45] nobitanobi: has joined #ruby
[15:45:19] __Yiota: has joined #ruby
[15:48:12] setuid: havenwood: Reasonable replacement?
[15:54:43] carnegie: has joined #ruby
[15:58:26] cadillac_: has joined #ruby
[15:58:30] havenwood: setuid: No, avoid ternaries like that.
[15:58:31] havenwood: setuid: default['foo']['bar']['blort'] = if ...
[15:58:32] matthewd: setuid: No, that looks to be neither reasonable nor a replacement. What are you trying to do?
[16:00:23] gusrub: has joined #ruby
[16:01:48] username: has joined #ruby
[16:01:53] havenwood: setuid: Only use ternaries straightforwardly, on one line, when it's quite simple.
[16:02:30] havenwood: setuid: Assign to the result of the conditional rather than inside the conditional when you can.
[16:04:11] howdoi: has joined #ruby
[16:05:13] havenwood: setuid: For example: https://gist.github.com/havenwood/d5c02f6435ad0195fcf4570a6c7233dd
[16:06:58] konsolebox: has joined #ruby
[16:09:56] balazs: has joined #ruby
[16:11:47] cdg: has joined #ruby
[16:12:12] cwonrails: has joined #ruby
[16:12:59] setuid: havenwood: So you recommend NOT using a conditional there? Ok.
[16:13:12] havenwood: setuid: An if statement is a conditional, no?
[16:14:21] setuid: Well, yes, but not a ternary conditional... I should have clarified
[16:14:32] havenwood: setuid: You could replace that if statement with a case statement or ternary. They're all conditionals.
[16:14:33] setuid: I'll make a PR to the code where this was found, using your suggestion
[16:14:44] cdg: has joined #ruby
[16:15:07] matthewd: setuid: You still haven't clarified what your goal is. What is your purpose for changing the code at all?
[16:15:12] Xiti: has joined #ruby
[16:16:15] rippa: has joined #ruby
[16:16:53] wilbert: has joined #ruby
[16:18:23] setuid: matthewd: Just trying to clean up the readability and maintainership, I very much prefer to change a line of code in one place, not two. IOW, if 'foo' becomes 'foobar', I have to change it in two places in the current check, vs. havenwood's example, where I change it in one place.
[16:18:34] carnegie: has joined #ruby
[16:23:25] Moosashi: has joined #ruby
[16:23:44] herbmillerjr: has joined #ruby
[16:24:06] Xeago: has joined #ruby
[16:24:19] beilabs: has joined #ruby
[16:27:48] justin_pdx: has joined #ruby
[16:28:10] saltsa: has joined #ruby
[16:31:37] Nimzowitsch: has joined #ruby
[16:32:03] Nimzowitsch: ip_set: #<Set: {"UNKNOWN"}>
[16:32:28] Nimzowitsch: so I have a have an array of ips, which I then turn into a set
[16:32:38] Nimzowitsch: and then I iterate over the set and delete duplicates from another array
[16:32:51] Nimzowitsch: at the end of the iteration the result is #<Set: {"UNKNOWN"}>
[16:32:58] Nimzowitsch: I've never seen before..
[16:33:21] Nimzowitsch: and could not find anything about it on google
[16:36:46] eckhardt: has joined #ruby
[16:38:01] havenwood: nimzowitsch: Have you been able to create a minimal reproduction example of the issue yet?
[16:38:11] havenwood: nimzowitsch: Or can you show the code that results in it?
[16:38:39] havenwood: >> Set.new << "UNKNOWN"
[16:38:40] ruby[bot]: havenwood: # => uninitialized constant Set (NameError) ...check link for more (https://eval.in/845675)
[16:38:46] havenwood: => #<Set: {"UNKNOWN"}>
[16:39:06] havenwood: nimzowitsch: It looks like you have one element in your set, the string: "UNKNOWN"
[16:40:08] aurelien: has joined #ruby
[16:40:58] dlitvak: has joined #ruby
[16:46:09] beilabs: has joined #ruby
[16:47:54] hutch34: has joined #ruby
[16:52:35] hahuang65: has joined #ruby
[16:56:24] [Butch]: has joined #ruby
[16:57:41] uZiel: has joined #ruby
[17:00:41] SteenJobs: has joined #ruby
[17:10:18] MrBismuth: has joined #ruby
[17:15:53] johnny56: has joined #ruby
[17:17:02] Joufflu_Fail: has joined #ruby
[17:19:27] dviola: has joined #ruby
[17:25:46] alfiemax: has joined #ruby
[17:27:07] conta2: has joined #ruby
[17:28:40] Tohuw_: has joined #ruby
[17:32:48] ledestin: has joined #ruby
[17:34:38] bmurt: has joined #ruby
[17:34:45] jphase: has joined #ruby
[17:35:19] SeepingN: has joined #ruby
[17:42:38] uZiel: has joined #ruby
[17:43:42] nopolitica: has joined #ruby
[17:44:13] brent__: has joined #ruby
[17:46:33] xuanrui: has joined #ruby
[17:52:40] jackjackdripper: has joined #ruby
[17:53:01] jackjackdripper1: has joined #ruby
[17:54:00] Fin1te: has joined #ruby
[17:56:00] cahoots: has joined #ruby
[17:56:55] perniciouscaffei: has joined #ruby
[17:57:09] benlieb: has joined #ruby
[17:59:48] creature: has joined #ruby
[18:00:55] creature: Hello. I need to generate a lot of unique identifiers. I can do this with a call to `SecureRandom.uuid`, but that "secure" part gives me pause. I'm not worried about the security; speed is more important. Is there a less-secure way to generate UUIDs?
[18:01:31] creature: (I'm guessing that SecureRandom will back onto the system's entropy pool, and could block if I read a lot of data out of that... but I might be out of date with this knowledge.)
[18:03:25] mtkd: has joined #ruby
[18:04:16] ski7777: has joined #ruby
[18:13:10] alamar: has joined #ruby
[18:14:35] cadillac_: has joined #ruby
[18:16:29] ShekharReddy: has joined #ruby
[18:17:44] Hobbyboy: has joined #ruby
[18:26:25] tAn: has joined #ruby
[18:26:25] Joufflu_Fail: has joined #ruby
[18:28:13] kies: has joined #ruby
[18:29:12] Hanmac: has joined #ruby
[18:29:18] dfedde: has joined #ruby
[18:33:22] dfedde: has joined #ruby
[18:35:46] havenwood: creature: Internally it'll use the nanosecond from the system clock, etc, to seed openssl then: OpenSSL::Random.random_bytes(n)
[18:36:02] havenwood: creature: Benchmark it to see the speed.
[18:36:34] quobo: has joined #ruby
[18:37:19] SteenJobs: has joined #ruby
[18:38:09] creature: havenwood: Does OpenSSL use /dev/urandom? Can I rely on that behaviour?
[18:38:40] goyox86: has joined #ruby
[18:39:30] creature: My concern is less "Generating a secure random number is going to be too slow", and more along the lines of "If I try to generate a million at once, am I going to inadvertently end up with a million blocking reads on /dev/random?"
[18:39:31] SteenJobs: has joined #ruby
[18:40:16] SteenJobs: has joined #ruby
[18:41:11] havenwood: creature: It starts here: https://github.com/ruby/ruby/blob/a0acd82f2af3278bcdba3df33a13e4604d5d68fc/lib/securerandom.rb#L270-L273
[18:41:33] havenwood: creature: Then it'll end up here: https://github.com/ruby/ruby/blob/a0acd82f2af3278bcdba3df33a13e4604d5d68fc/lib/securerandom.rb#L88-L99
[18:41:35] SteenJobs: has joined #ruby
[18:41:57] havenwood: creature: Which goes here: https://github.com/ruby/ruby/blob/202bbda2bf5f25343e286099140fb9282880ecba/ext/openssl/ossl_rand.c#L112-L124
[18:41:57] roboncloud: see here: https://bugs.ruby-lang.org/issues/9569 for what `random_bytes` may be generated by.
[18:43:08] roboncloud: so may not go to OpenSSL, or /dev/urandom, if OS provides something.
[18:43:51] havenwood: Selection is here: https://github.com/ruby/ruby/blob/a0acd82f2af3278bcdba3df33a13e4604d5d68fc/lib/securerandom.rb#L47-L112
[18:44:05] havenwood: creature: Presuming you have OpenSSL installed?
[18:44:14] vedu: has left #ruby: ("Konversation terminated!")
[18:44:30] Polymorphism: has left #ruby: ("Leaving")
[18:45:00] creature: Presumably!
[18:45:01] roboncloud: is that recent for HEAD?
[18:45:12] havenwood: creature: I'd suggest trying a few million at once. ;-)
[18:46:10] creature: Mmm. :) I was hoping to find a documented "This might not be crytographically secure, but is definitely non-blocking" method though. (As opposed to "reading the code shows Ruby currently reads from urandom, but I can't guarantee that remaining the case in future.")
[18:46:23] creature: Thank you for the help! I think I can deal with the knowledge that it backs onto urandom for now.
[18:46:29] creature: I'm probably being overly cautious.
[18:46:50] roboncloud: this is frustrating, but when people refuse to read the advice, who cares i guess. /dev/urandom is the second preference, openssl is the last, but read the first preference, it is neither of those
[18:46:57] roboncloud: it is a function provided by the OS
[18:47:39] creature: roboncloud: Sorry! I did read the advice, but I guess I missed that nuance to it.
[18:48:15] roboncloud: if you hit the first, i think it should be fast, especially on OpenBSD where arc4random is available.
[18:48:26] brent__: has joined #ruby
[18:49:22] SuperLag: has joined #ruby
[18:49:52] tvw: has joined #ruby
[18:50:36] Dimik: has joined #ruby
[18:50:45] ltem: has joined #ruby
[18:50:51] moei: has joined #ruby
[18:51:22] uZiel: where can I find documentation of TCPSocket methods?
[18:51:31] roboncloud: rubydoc.info
[18:54:37] DTZUZO: has joined #ruby
[18:55:03] uZiel: that has only a few methods while TCPSocket_Object.methdos lists a lot more
[18:56:26] uZiel: I am not sure what is the difference bw write, printf, print, putc, puts, syswrite etc.. where to find documentation for these?
[18:57:09] adlerdias: has left #ruby: ()
[18:57:26] roboncloud: http://www.rubydoc.info/stdlib/socket/TCPSocket - it inherits from "IPSocket", so you can check the docs there, and anything else in its inheritance chain, but `.methods()` includes everything it responds to from all ancestors afaik, so it's not a good gauge.
[18:58:33] roboncloud: sock.method(:printf).owner will tell you what module/class it resolves to
[19:00:25] jaequery: has joined #ruby
[19:01:17] setuid: has left #ruby: ()
[19:03:18] MichaelBurge: has joined #ruby
[19:03:20] creature: has joined #ruby
[19:03:20] creature: has joined #ruby
[19:03:24] Xeago: has joined #ruby
[19:03:33] Caerus: has joined #ruby
[19:03:36] Xiti: has joined #ruby
[19:03:36] Seenox: has joined #ruby
[19:03:37] synthroid: has joined #ruby
[19:03:42] claw: has joined #ruby
[19:03:43] gnufied: has joined #ruby
[19:03:46] cadillac_: has joined #ruby
[19:03:47] jphase: has joined #ruby
[19:03:52] tvw: has joined #ruby
[19:03:53] chouhoulis: has joined #ruby
[19:03:55] phate408: has joined #ruby
[19:03:55] jtperreault: has joined #ruby
[19:03:57] m27frogy: has joined #ruby
[19:03:57] djbkd: has joined #ruby
[19:03:59] redondos: has joined #ruby
[19:04:06] dlitvak: has joined #ruby
[19:04:11] howdoi: has joined #ruby
[19:04:14] MrBismuth: has joined #ruby
[19:04:14] creeg: has joined #ruby
[19:04:14] Hanmac: has joined #ruby
[19:04:38] chouhoulis: has joined #ruby
[19:04:40] eb0t: has joined #ruby
[19:04:49] theta8: has joined #ruby
[19:04:56] PaulCapestany: has joined #ruby
[19:05:26] cjohnson: is foo(&:bar) the same as foo() { |x| x.bar } ?
[19:05:39] Papierkorb: cjohnson: yes
[19:05:44] havenwood: cjohnson: A bit faster, but yes.
[19:05:47] cjohnson: Awesome thanks
[19:06:21] cjohnson: Is it just the & that does that?
[19:06:30] havenwood: cjohnson: The `&` is sugar that calls #to_proc on the `:bar` symbol.
[19:06:42] havenwood: cjohnson: And passes the result as the block.
[19:07:03] uZiel: roboncloud: thanks
[19:07:55] jinie: has joined #ruby
[19:08:02] benjen: has joined #ruby
[19:08:15] bokayio: has joined #ruby
[19:08:27] mtkd: has joined #ruby
[19:11:40] wilbert: has joined #ruby
[19:12:58] cahoots: hi, i see that gems like https://rubygems.org/gems/method_source/versions/0.8.2 don't have any license. does that mean that you can't even download them, because they're protected by copyright law?
[19:13:04] FernandoBasso: has joined #ruby
[19:13:41] dionysus69: has joined #ruby
[19:13:43] Guest80368: has joined #ruby
[19:14:01] S007: has joined #ruby
[19:14:39] ur5us: has joined #ruby
[19:14:42] mikecmpbll: has joined #ruby
[19:15:06] havenwood: cahoots: That gem is licensed MIT.
[19:15:13] havenwood: cahoots: https://github.com/banister/method_source/blob/master/LICENSE
[19:15:28] havenwood: cahoots: It's just missing from the gemspec.
[19:18:54] mtkd: has joined #ruby
[19:19:18] havenwood: cahoots: The author's implicit copyright doesn't prevent you from downloading work they've publicly posted.
[19:20:14] matthewd: Indeed, that logic would make it rather hard to browse the web
[19:20:47] Fin1te: has joined #ruby
[19:20:53] sagax: has joined #ruby
[19:21:02] dstrunk: has joined #ruby
[19:21:13] roboncloud: more likely you'll have issues with GPL software on rubygems than any 'proprietary' licensing issues.
[19:22:35] ResidentBiscuit: has joined #ruby
[19:23:02] mars777: has joined #ruby
[19:25:36] hutch34: has joined #ruby
[19:25:49] WeiJunLi: has joined #ruby
[19:31:04] nostalgiccloud: has joined #ruby
[19:31:17] gusrub: has joined #ruby
[19:32:57] Inoperable: has joined #ruby
[19:33:33] eckhardt: has joined #ruby
[19:34:47] SteenJobs_: has joined #ruby
[19:43:13] eroux: has joined #ruby
[19:45:26] weaksauce: has joined #ruby
[19:48:17] jphase: has joined #ruby
[19:48:43] dviola: roboncloud: how so?
[19:49:02] dviola: roboncloud: you mean like in the case of using a GPL library in a proprietary codebase and distributing it?
[19:49:53] roboncloud: for web software i guess it doesn't matter
[19:50:10] Guest85042: has joined #ruby
[19:50:18] SteenJobs_: has joined #ruby
[19:52:08] brent__: has joined #ruby
[19:52:40] roboncloud: i think you're also obliged to share any improvements you make to GPL code. it's the most complicated and restrictive of open source licenses i've come across, and proprietary licenses generally aren't a thing on rubygems. maybe very rare cases.
[19:55:02] dviola: that's because it wasn't created with "open source" in mind, but it was written as a free software license, different terms for different meanings
[19:55:56] Rapture: has joined #ruby
[19:56:17] cahoots: havenwood, ah i see, thanks
[19:56:28] SteenJobs_: has joined #ruby
[19:56:30] cahoots: can you believe anyone uses gpl?
[19:56:49] dfedde: has joined #ruby
[19:56:50] roboncloud: i avoid it if i can.
[19:57:05] Papierkorb: dviola: Well of course, Free Software isn't "Open Source" :)
[19:57:13] eam: you're not obligated to share improvements to gpl code, but you are obligated to provide the source code to anyone you distribute it to
[19:57:39] eam: it's no more restrictive than any other commercial license
[19:58:16] matthewd: eam: Except when it's applied to a library
[19:58:29] roboncloud: i think it's less restrictive cos at least you can look at the source and modify it, but in the realm of open source licenses it's more annoying than useful.
[19:58:36] dviola: the GPL encourages contributions as it is a strong copyleft license, whereas the other licenses have weak copyleft or none at all
[19:59:13] eam: even with libraries, the GPL is strictly more permissive than the default controls provided by copyright -- it must be, because it leverages copyright
[19:59:31] dviola: https://www.gnu.org/philosophy/open-source-misses-the-point.html
[19:59:31] Papierkorb: imho, LGPL for libs is quite reasonable
[20:00:08] eam: often people freak out because "the GPL is viral" or whatever, but they forget that it's actually copyright itself which behaves that way
[20:00:19] matthewd: eam: You said "any other commercial license", not "unlicensed copyright"
[20:00:23] roboncloud: dviola a lot of that requires buying into stallmans world view.
[20:00:38] eam: matthewd: or unlicensed copyright
[20:00:55] eam: anything the GPL prohibits, unlicensed use also prohibits
[20:01:01] eam: it's a strict subset
[20:01:02] dviola: roboncloud: personally I think his arguments are rational and make sense, proprietary software is a bad thing
[20:01:14] matthewd: Any standard commercial license for a software library will [in general] permit works using said library to be distributed without their source
[20:01:22] eam: it has to be, because it derives its authority *from* copyright
[20:02:02] eam: matthewd: nah, plenty of my licenses don't permit me to distribute at all - only use
[20:03:05] matthewd: You said "any other commercial license". Not "copyright" (which yes, is obviously more restrictive by default), and not "plenty of my licenses".
[20:03:34] roboncloud: dviola, i'm not arguing for closed source, but i'm not arguing for a license every venture i make, commercial or not, has to be made open source. GPL is fine but if you want the most freedom, to reuse it in commercial setting or not, best to avoid GPL if you can, and i only said it's more troublesome other licenses in context of rubygems.
[20:03:35] wilbert_: has joined #ruby
[20:04:44] dviola: roboncloud: I disagree, there is no reason to fear the GPL unless you want to enslave your users into using proprietary stuff
[20:04:46] postmodern: has joined #ruby
[20:05:02] roboncloud: i just want to offer users fun software
[20:05:07] roboncloud: that's useful and high quality
[20:05:32] roboncloud: im not enslaving them and tbh it seems kinda crazy to think that way. there's already a balance that prevents closed source running rampant.
[20:05:42] matthewd: eam: To be clear, I'm not arguing a "GPL is bad because it's viral" position; I'm arguing "GPL is not strictly as/more permissive than 'any other commercial license'"
[20:06:12] jphase: has joined #ruby
[20:08:21] lxsameer: has joined #ruby
[20:08:48] guacamole: has joined #ruby
[20:11:21] cahoots: let's say i have a gem with a dependency with a version like "~> 1.1", and i want to restrict it to using a specific version, say, 1.1.1. how can i do this?
[20:12:44] cahoots: roboncloud, so would i add that i want the dependency explicitly and give it a specific version in the same file as i specify the gem with that dependency?
[20:13:01] username: has joined #ruby
[20:13:46] dviola: roboncloud: freedom and rights are not crazy things at all
[20:13:48] roboncloud: Gem::Specification.new { |s| s.add_runtime_dependency "mygem", "=1.1.1" }, maybe just "1.1.1" works. not sure where i'm getting "=1.1.1" from.
[20:14:07] SteenJobs_: has joined #ruby
[20:15:09] nostalgiccloud: has joined #ruby
[20:16:16] cahoots: hopefully there's an easier way than doing real code
[20:16:20] roboncloud: @dviola yeah, sure, but i think stallman is just another side of an extreme solution to the problem. open source & business should be able to integrate and work well together, but GPL makes that more diffilcult, other open source licenses are preferable if you want to make money to actually survive in life, before you can worry about the dreamy ideals of mr stallman.
[20:16:23] cahoots: i was thinking i could do it in the dsl of a Gemfile
[20:19:59] FernandoBasso: has joined #ruby
[20:20:07] AnoHito_: has joined #ruby
[20:20:52] roboncloud: stallman basically never left university, don't forget that. he's had a lot of time dream of an ideal world while not worrying about how to pay his rent. his contribution is still very valuable, but not practical as the ultimate solution.
[20:21:22] dviola: roboncloud: I don't see it as extreme at all, if anything, his arguments are rational and makes tons of sense, if you read their website you'll see that they are not against businesses or selling software, their whole point is about what your end users *receive* -- do they receive something they can change and fix themselves or share it with others?
[20:21:25] goyox86: has joined #ruby
[20:21:55] dviola: that's the whole point of the GPL license
[20:22:23] matthewd: cahoots: Yes, you can just specify your own more specific dependency in your Gemfile... though one might wonder why you would want to.
[20:22:31] goyox86: has left #ruby: ()
[20:22:57] dviola: I understand the GPL will conflict with some people's desire to profit though by limiting what users can and cannot do (removing their freedom/rights)
[20:22:58] roboncloud: i don't think it's practical in the real world, but if he wins and it becomes the main model for software, great, because it would be better.
[20:23:16] goyox86_: has joined #ruby
[20:24:35] SteenJobs_: has joined #ruby
[20:25:00] brent__: has joined #ruby
[20:25:19] ecuanaso: has joined #ruby
[20:28:03] nostalgiccloud: has joined #ruby
[20:34:59] dviola: roboncloud: there was a discussion about this on HN just a couple of days ago: https://news.ycombinator.com/item?id=14974563
[20:36:23] cahoots: matthewd, just keeping versions constant because our legal team requires all open-source stuff to be approved by them. so if i leave the version open-ended, technically they could release a new version with a different license
[20:36:51] matthewd: cahoots: Gemfile.lock is probably sufficient for that
[20:36:52] nacsurte: has joined #ruby
[20:36:55] cahoots: the way i'm specifying the dependency version is by just listing out that dependency as a separate gem, and it seems to work. is there a better way?
[20:37:23] cahoots: so i should edit the Gemfile.lock with s/~> /=/ ?
[20:37:27] matthewd: It is, by definition, a list of exact versions of every package in use
[20:37:35] matthewd: No, you don't need to edit anything
[20:37:52] cahoots: the issue is that ~> doesn't restrict it to a single version
[20:38:04] roboncloud: @dviola yeah stallman is an inspiration.
[20:38:08] matthewd: List your dependencies with sensible range selectors in Gemfile, then use Gemfile.lock as the list of exact versions in use
[20:38:43] roboncloud: but when you cross into commercial software, "here's my product, go rebrand it in china, and resell it in hong kong, for free!" doesn't work.
[20:38:54] cahoots: even when i list out my dependencies in the Gemfile, the Gemfile.lock still shows "~>". but in practice it seems to download the gem i want
[20:38:58] cdg_: has joined #ruby
[20:39:23] cahoots: https://gist.github.com/michaeleiselsc/323a3fc0912121c5ec81acf171897d95
[20:39:41] matthewd: cahoots: The top level under specs: lists all the gems, with the exact version in use. Nested underneath each of those is a copy of that version's stated dependencies.
[20:40:24] cahoots: matthewd, it lists the exact version of the gem, but not the exact version of its dependencies necessarily
[20:40:29] matthewd: So yes, pry is happy with any coderay ~> 1.1.0, but you're currently using exactly coderay (1.1.1)
[20:41:00] matthewd: Yes, it does
[20:41:45] matthewd: Clean out your Gemfile to just list your top-level deps (so no mention of coderay), then bundle to regenerate the lockfile
[20:42:13] matthewd: It'll disappear from the DEPENDENCIES section, but under specs: you'll still see "coderay (1.1.1)"
[20:42:22] cdg_: has joined #ruby
[20:43:15] matthewd: This is exactly what the lockfile is for: reproducible deployments of a well-defined set of package versions
[20:46:28] ecuanaso: has joined #ruby
[20:48:21] dviola: has joined #ruby
[20:49:12] dviola: roboncloud: people have found other ways to still make a profit while working on free software, both things are entirely compatible and were never against each other
[20:49:27] nacsurte: has joined #ruby
[20:49:54] dviola: roboncloud: see all those developers earning money with patreon or Red Hat
[20:51:30] matthewd: roboncloud: dviola: I think it's time for this conversation to head to #ruby-offtopic
[20:53:57] dviola: matthewd: ok, agreed
[20:55:10] roboncloud: "other ways" makes an already difficult venture even more difficult.
[20:55:46] skweek: has joined #ruby
[20:55:49] cdg: has joined #ruby
[20:57:04] minimalism: has joined #ruby
[20:57:55] cdg_: has joined #ruby
[20:58:30] cdg__: has joined #ruby
[21:02:22] ur5us: has joined #ruby
[21:03:06] alfiemax: has joined #ruby
[21:09:31] jaequery: has joined #ruby
[21:10:48] jenrzzz: has joined #ruby
[21:10:48] jenrzzz: has joined #ruby
[21:10:53] cahoots: has joined #ruby
[21:13:58] cdg_: has joined #ruby
[21:20:02] FernandoBasso: has joined #ruby
[21:26:44] jaequery: has joined #ruby
[21:31:10] Azure: has joined #ruby
[21:36:49] FastJack: has joined #ruby
[21:39:10] Sembei: has joined #ruby
[21:40:26] Fin1te: has joined #ruby
[21:48:23] Tharbakim: has joined #ruby
[21:48:23] Tharbakim: has joined #ruby
[21:53:53] workmad3: has joined #ruby
[21:53:55] kn-928: has joined #ruby
[21:57:18] sinequanon: has joined #ruby
[21:57:37] alfiemax: has joined #ruby
[21:59:57] alfiemax: has joined #ruby
[22:01:03] slayman: has joined #ruby
[22:02:21] alfiemax: has joined #ruby
[22:04:41] alfiemax: has joined #ruby
[22:07:06] alfiemax: has joined #ruby
[22:09:26] alfiemax: has joined #ruby
[22:11:51] alfiemax: has joined #ruby
[22:14:16] alfiemax: has joined #ruby
[22:16:37] alfiemax: has joined #ruby
[22:16:43] Azure: has joined #ruby
[22:18:24] runescape07rsps: has joined #ruby
[22:19:02] alfiemax: has joined #ruby
[22:19:27] Murda: has joined #ruby
[22:19:48] abort: has joined #ruby
[22:19:59] SpComb: has joined #ruby
[22:20:02] seitensei: has joined #ruby
[22:20:50] gusrub: has joined #ruby
[22:20:57] linduxed: has joined #ruby
[22:21:09] arthurnn: has joined #ruby
[22:21:21] alfiemax: has joined #ruby
[22:21:31] Map: has joined #ruby
[22:23:46] alfiemax: has joined #ruby
[22:26:05] jinie_: has joined #ruby
[22:26:10] alfiemax: has joined #ruby
[22:26:15] cahoots: has joined #ruby
[22:27:36] t-recx: has joined #ruby
[22:28:31] alfiemax: has joined #ruby
[22:30:33] alfiemax: has joined #ruby
[22:32:59] alfiemax: has joined #ruby
[22:34:24] dogman: has joined #ruby
[22:35:06] dogman: hello everyone
[22:35:22] alfiemax: has joined #ruby
[22:35:24] dogman: im just begining to learn ruby, and was wondering if i can get some help
[22:37:40] alfiemax: has joined #ruby
[22:39:14] dogman: i just wrote a very basic HTTP server and based off the book im using they recommend to use the TRAP method. I couldnt really find anything online on what this method does. i understand its a signal but from where is it expectig a signal?
[22:40:05] alfiemax: has joined #ruby
[22:40:43] elnner: has joined #ruby
[22:40:49] Radar: dogman: do you have some example code for this trap method?
[22:40:58] dogman: yes on second
[22:41:24] dogman: server = WEBrick::HTTPServer.new(:Port => 1234)
[22:41:24] dogman: server.mount '/',Myservlet
[22:41:24] dogman: trap('INT'){server.shutdown}
[22:41:26] dogman: server.start
[22:42:19] justinmcp: has joined #ruby
[22:42:28] alfiemax: has joined #ruby
[22:42:54] Radar: That looks to be calling the Kernel#trap method. It will catch Ctrl+C or interrupt signals sent to your process and gracefully shut down your server.
[22:43:15] Radar: Try commenting out that line, running the program and then hitting Ctrl+C. Look at how the behaviour differs.
[22:44:23] huyderman: has joined #ruby
[22:44:25] AndBobsYourUncle: has joined #ruby
[22:44:44] nacsurte: has joined #ruby
[22:44:55] aglorei1: has joined #ruby
[22:45:33] roboncloud: 💪 webrick
[22:45:50] dogman: Radar: ahh ok i see now. thank you. so 'INT' is interpreted by the kernel then. would i be able to find different possible params to the method, or is it kernel specific?
[22:45:53] carnegie: has joined #ruby
[22:46:19] Radar: >> Signal.list
[22:46:21] ruby[bot]: Radar: # => {"EXIT"=>0, "HUP"=>1, "INT"=>2, "QUIT"=>3, "ILL"=>4, "TRAP"=>5, "ABRT"=>6, "IOT"=>6, "FPE"=>8, "KILL ...check link for more (https://eval.in/845698)
[22:46:35] Radar: dogman: depends on your operating system too
[22:46:46] Radar: Signal.list in your irb console might return a different list to that one.
[22:48:57] alfiemax: has joined #ruby
[22:49:00] dogman: thats great thank you again...and yeah i see the list
[23:04:56] hahuang65: has joined #ruby
[23:05:04] nostalgiccloud: has joined #ruby
[23:10:02] ur5us: has joined #ruby
[23:17:11] jphase: has joined #ruby
[23:24:29] m27frogy: has joined #ruby
[23:25:27] jphase: has joined #ruby
[23:28:36] ecuanaso: has joined #ruby
[23:29:09] jphase: has joined #ruby
[23:29:27] zenspider: also `kill -l`
[23:34:46] m27frogy: has joined #ruby
[23:36:53] guacamole: has joined #ruby
[23:46:20] Cyrus: So a common pattern in my code is to define an empty array before iterating through an Enumerable and then appending the result of a method called from within the Enumerable's block into the array. I feel like maybe there's a better more Rubyesque way to handle this common need/pattern?
[23:46:39] Papierkorb: Cyrus: `Enumerable#map`
[23:47:08] Papierkorb: >> [2,3,4].map{|x| x ** 2}
[23:47:09] ruby[bot]: Papierkorb: # => [4, 9, 16] (https://eval.in/845703)
[23:47:44] Cyrus: Hrm, yeah, I suppose that would work.
[23:51:08] alfiemax: has joined #ruby
[23:54:04] elomatreb: I know rspec is a little unpopular here, but I'll ask anyway: Does anyone know a way to group examples (and have before/after and subject) without having to give that grouping a name (like context does)?
[23:55:02] Papierkorb: elomatreb: isn't the context name optional?
[23:55:42] elomatreb: It is, thank you