« Back to channel list

#ruby - 30 November 2018

« Back 1 day Forward 1 day »
[00:08:09] href: has joined #ruby
[00:08:24] krawchyk: has joined #ruby
[00:14:46] cthu|: what's the Object called in Ruby?
[00:15:39] cthu|: I want to overload puts and add a few checks in it
[00:15:54] cthu|: and I also don't want to change local context of my local puts
[00:16:14] cthu|: so I want to say in it something like Object.puts(message)
[00:16:21] akem: has joined #ruby
[00:16:24] cthu|: wonder if it'd work
[00:16:33] cthu|: by now everything I try just works
[00:16:42] cthu|: it's gonna be fun if it works
[00:17:57] baweaver: cthu|: Why?
[00:18:09] cthu|: I need to check if debug is on
[00:18:15] cthu|: in this class
[00:18:27] cthu|: it's not meant to puts anything for other people who don't touch it
[00:18:27] cschneid: has joined #ruby
[00:18:47] cthu|: so I use my local var that it checks for to decide whether puts or not
[00:18:58] cthu|: but I add that logic to every puts here and I have a bunch of them
[00:18:58] baweaver: just use suffix conditionals
[00:19:10] cthu|: I know, but I will forget and continue using puts
[00:19:16] cthu|: so I want to overload real puts
[00:19:19] cthu|: it's also fun
[00:19:22] baweaver: No you don't
[00:19:37] cthu|: fun it the main reason
[00:19:49] cthu|: I don't care that overloading native methods is bad
[00:19:52] cthu|: I know it.
[00:20:05] cthu|: never in my life have I done it. For Ruby.
[00:20:08] cthu|: HAve to do it once
[00:20:13] cthu|: you know, like I have to.
[00:20:32] baweaver: You don't particularly _have_ to do anything.
[00:20:40] baweaver: That's what you make loggers for
[00:20:53] baweaver: https://ruby-doc.org/stdlib-2.4.0/libdoc/logger/rdoc/Logger.html
[00:21:13] cthu|: I don't like it
[00:21:16] coltkirk: has joined #ruby
[00:21:23] cthu|: I actually have the logger gem installed
[00:21:27] cthu|: it doesn't do the trick
[00:21:34] cthu|: or does it rather awkwardly
[00:21:40] baweaver: easy on the enter key
[00:21:42] akemot: has joined #ruby
[00:21:47] cthu|: it doesn't allow me to create custom crap
[00:22:08] cthu|: just use the six levels it offers and that's it.
[00:22:21] cthu|: None of them is good for me
[00:22:23] baweaver: Chances are you really don't need to.
[00:22:36] cthu|: anyhow, my aim is to have fun
[00:22:45] cthu|: so... I will try $stdout.puts("qwe")
[00:22:55] cthu|: I'm also curious about $
[00:22:57] cthu|: what is $?
[00:22:57] baweaver: There's a difference between learning something useful and just developing bad habits.
[00:23:07] baweaver: Like global variables
[00:23:08] cthu|: yeah, so I'm learning
[00:23:15] cthu|: $ is a global?
[00:23:26] cthu|: it's strange that stdout is a variable
[00:23:35] cthu|: although ues
[00:23:39] cthu|: it makes sense
[00:23:49] cthu|: I guess that will give me the context I want
[00:23:57] baweaver: What was that that was _just_ mentioned about going easy on the enter key?
[00:24:23] baweaver: It's not a space bar, give the poor thing a break.
[00:24:45] cthu|: ok, ok, enough rumbling about enter. So typical of irc
[00:26:24] darkhanb: has joined #ruby
[00:26:59] cthu|: Ha! works! It's the first and the last time I'm overloading a native method in Ruby. I wonder if I could use something else, instead of $stdout. Could I?
[00:27:09] coltkirk: ive been prattling with emacs/elisp for a few years, thinking about taking the next step into the ruby-verse
[00:27:12] nowhere_man: has joined #ruby
[00:27:23] baweaver: puts is a method defined on IO type objects.
[00:27:41] baweaver: That's why you get things like File puts, IO puts, and other such methods
[00:28:49] cthu|: right, but I thought maybe there was a child of stdout that is closer to our beloved puts
[00:30:04] jaddison: has joined #ruby
[00:30:06] cthu|: although, it may be the other way around. Maybe put is somewhere above and then stdout just uses it to create puts
[00:30:30] baweaver: It's in Kernel and IO
[00:30:38] baweaver: ACTION heads back home
[00:36:01] Dreamer3: has joined #ruby
[00:47:42] nchambers: has joined #ruby
[00:52:21] Renich: has joined #ruby
[00:54:05] graphene: has joined #ruby
[00:58:04] graphene: has joined #ruby
[01:00:11] akem: has joined #ruby
[01:20:13] havenwood: &>> method(:puts).owner
[01:20:16] rubydoc: # => Kernel (https://carc.in/#/r/5noy)
[01:22:25] arescorpio: has joined #ruby
[01:38:48] Puffball: has joined #ruby
[01:53:04] houhoulis: has joined #ruby
[01:57:06] tdy: has joined #ruby
[02:08:22] bmurt: has joined #ruby
[02:14:41] Renich_: has joined #ruby
[02:33:13] Renich: has joined #ruby
[02:41:55] orbyt_: has joined #ruby
[02:52:02] Renich_: has joined #ruby
[03:00:09] esrse: has joined #ruby
[03:05:10] Inside: has joined #ruby
[03:05:14] Inside: anyone in here use opencv?
[03:05:24] Inside: it seems like the ruby gem is at 2.4 whereas latest is 4.0
[03:13:52] kapil____: has joined #ruby
[03:19:28] cd: has joined #ruby
[03:34:15] jaddison: has joined #ruby
[03:34:21] robscomputer: has joined #ruby
[03:39:59] nchambers: has joined #ruby
[03:39:59] bambanx: has joined #ruby
[04:00:42] arescorpio: has joined #ruby
[04:07:26] chouhoulis: has joined #ruby
[04:09:52] braincrash: has joined #ruby
[04:10:05] \void: has joined #ruby
[04:12:53] Renich_: has joined #ruby
[04:23:09] Renich: has joined #ruby
[04:24:16] Renich: has joined #ruby
[04:29:33] Renich: has joined #ruby
[04:29:39] coltkirk: has left #ruby: ("ERC (IRC client for Emacs 26.1)")
[04:29:47] cschneid: has joined #ruby
[04:31:42] Renich: has joined #ruby
[04:43:25] coltkirk: has joined #ruby
[04:52:00] Renich: has joined #ruby
[04:52:29] Renich: has joined #ruby
[04:56:21] alicef: has left #ruby: ("Fatal : Bad Magic")
[04:58:24] jaddison: has joined #ruby
[05:01:15] mooe: has joined #ruby
[05:02:40] coltkirk: has left #ruby: ("ERC (IRC client for Emacs 26.1)")
[05:23:14] za1b1tsu: has joined #ruby
[05:42:36] cschneid: has joined #ruby
[05:44:00] hiroaki: has joined #ruby
[05:58:16] graphene: has joined #ruby
[06:02:49] reber: has joined #ruby
[06:09:04] Tempesta: has joined #ruby
[06:14:36] Nicmavr: has joined #ruby
[06:16:38] za1b1tsu: has joined #ruby
[06:22:51] Renich: has joined #ruby
[06:23:53] Renich: has joined #ruby
[06:23:57] arekushi: has joined #ruby
[06:27:46] hiroaki: has joined #ruby
[06:41:33] LunarDinosaur: has joined #ruby
[06:42:21] LunarDinosaur: has joined #ruby
[06:43:07] LunarDinosaur: has joined #ruby
[06:43:52] LunarDinosaur: has joined #ruby
[06:44:41] LunarDinosaur: has joined #ruby
[06:48:16] armyriad: has joined #ruby
[06:53:11] aupadhye: has joined #ruby
[06:56:08] tdy: has joined #ruby
[07:10:30] akaiiro: has joined #ruby
[07:11:12] daemonwrangler: has joined #ruby
[07:13:07] cschneid: has joined #ruby
[07:16:06] LunarDinosaur: has joined #ruby
[07:17:36] za1b1tsu: has joined #ruby
[07:19:02] za1b1tsu: has joined #ruby
[07:20:08] conta: has joined #ruby
[07:20:29] Exuma: has joined #ruby
[07:20:47] spectra: has joined #ruby
[07:24:11] kapil____: has joined #ruby
[07:33:23] za1b1tsu: has joined #ruby
[07:39:46] za1b1tsu: has joined #ruby
[07:43:32] chussenot: has joined #ruby
[08:09:11] Renich: has joined #ruby
[08:09:50] za1b1tsu: has joined #ruby
[08:10:17] Renich: has joined #ruby
[08:14:30] johnny56: has joined #ruby
[08:17:31] MyMind: has joined #ruby
[08:18:07] waheedi: has joined #ruby
[08:19:47] ams__: has joined #ruby
[08:43:14] clemens3: has joined #ruby
[08:44:35] za1b1tsu: has joined #ruby
[08:47:18] ghormoon: has joined #ruby
[08:50:41] keden: has joined #ruby
[08:51:21] gigetoo: has joined #ruby
[08:51:25] cschneid: has joined #ruby
[08:57:22] i4: has joined #ruby
[08:59:46] ellcs: has joined #ruby
[09:05:36] piks3l: has joined #ruby
[09:13:09] mikecmpbll: has joined #ruby
[09:19:26] dbz: has joined #ruby
[09:32:32] LunarDinosaur: has joined #ruby
[09:35:38] Renich: has joined #ruby
[09:36:41] Renich: has joined #ruby
[09:40:35] Guest21835: has joined #ruby
[09:40:53] lunarkitty7: has joined #ruby
[09:41:56] venmx: has joined #ruby
[09:47:54] DTZUZO: has joined #ruby
[09:48:23] cnsvc_: has joined #ruby
[09:48:33] jottr: has joined #ruby
[09:49:59] cschneid: has joined #ruby
[09:50:56] phaul: has joined #ruby
[09:51:33] apparition47: has joined #ruby
[09:52:32] ua: has joined #ruby
[10:01:11] dhollin3: has joined #ruby
[10:05:39] LinuxKnight: has joined #ruby
[10:13:59] roshanavand: has joined #ruby
[10:14:32] za1b1tsu: has joined #ruby
[10:18:43] akemot: has joined #ruby
[10:27:47] malen: has joined #ruby
[10:29:50] roshanavand: has joined #ruby
[10:34:05] malen: has joined #ruby
[10:37:03] Renich: has joined #ruby
[10:37:28] Renich: has joined #ruby
[10:38:59] n13z: has joined #ruby
[10:45:41] roshanavand: has joined #ruby
[10:46:15] xco: has joined #ruby
[10:47:17] akemot: has joined #ruby
[10:48:41] cnsvc_: has joined #ruby
[10:50:07] xco: hi everyone, need some second pair of eyes, i rewrote this method can someone please tell me if they are the same? i think they are https://gist.github.com/xcobar/e485b5e7e591959e993aedae35423991
[10:59:07] dinfuehr_: has joined #ruby
[11:42:46] keden: has joined #ruby
[11:42:50] Renich: has joined #ruby
[11:43:53] roshanavand: has joined #ruby
[11:43:56] Renich: has joined #ruby
[11:46:47] cschneid: has joined #ruby
[11:52:11] aupadhye: has joined #ruby
[11:54:10] segy: has joined #ruby
[11:55:51] cnsvc_: has joined #ruby
[11:55:54] mangold: has joined #ruby
[12:03:46] akem: has joined #ruby
[12:06:37] xco: has joined #ruby
[12:07:35] xco: hi everyone, need some second pair of eyes, i rewrote this method can someone please tell me if they are the same? i think they are https://gist.github.com/xcobar/e485b5e7e591959e993aedae35423991
[12:07:42] phaul: has joined #ruby
[12:13:28] cnsvc_: has joined #ruby
[12:14:03] al2o3-cr-tmp: has joined #ruby
[12:19:56] AJA4350: has joined #ruby
[12:20:25] Iambchop: xco: try "puts admin_link(false)" with both versions
[12:44:20] roshanavand: has joined #ruby
[12:44:57] xco: Iambchop: got it ;)
[12:46:11] aupadhye: has joined #ruby
[12:58:39] LunarDinosaur: has joined #ruby
[12:58:41] akem: has joined #ruby
[13:15:35] conta: has joined #ruby
[13:18:08] mondz: has joined #ruby
[13:19:44] jcalla: has joined #ruby
[13:20:01] beeman: has joined #ruby
[13:20:23] cschneid: has joined #ruby
[13:22:02] keden: has joined #ruby
[13:23:23] piks3l: has joined #ruby
[13:23:33] rippa: has joined #ruby
[13:25:29] cnsvc_: has joined #ruby
[13:27:29] dinfuehr: has joined #ruby
[13:29:35] akaiiro: has joined #ruby
[13:32:16] cd: has joined #ruby
[13:34:36] bmurt: has joined #ruby
[13:40:12] Inline: has joined #ruby
[13:44:42] roshanavand: has joined #ruby
[13:57:39] keden: has joined #ruby
[14:01:22] RiPuk: has joined #ruby
[14:01:44] cschneid: has joined #ruby
[14:02:56] jsc: has joined #ruby
[14:05:28] conta: has joined #ruby
[14:07:36] clemens3: has joined #ruby
[14:13:33] eclm: has joined #ruby
[14:18:35] gregf_: has joined #ruby
[14:23:01] catphish: has joined #ruby
[14:25:59] cnsvc_: has joined #ruby
[14:30:55] dinfuehr_: has joined #ruby
[14:32:41] yoones: has joined #ruby
[14:33:40] orbyt_: has joined #ruby
[14:34:35] mtkd: has joined #ruby
[14:39:14] Renich: has joined #ruby
[14:40:17] Renich: has joined #ruby
[14:50:34] Renich: has joined #ruby
[14:51:31] crankharder: has joined #ruby
[14:52:42] Renich: has joined #ruby
[14:55:07] crankharder: I'm trying to improve a gem's test suite (that uses appraisal) and it's spitting out a huge amount of these warnings: "warning: method redefined; discarding old request" - Does anyone know how to reproduce a warning like that? Can't say I've seen it much. Seems like it's a warning coming out of ruby-core, but maybe not?
[14:56:56] malen: has joined #ruby
[15:01:38] dinfuehr: has joined #ruby
[15:01:47] gnufied: has joined #ruby
[15:07:07] Mike11: has joined #ruby
[15:11:11] KeyJoo: has joined #ruby
[15:29:45] cnsvc_: has joined #ruby
[15:38:15] chouhoulis: has joined #ruby
[15:45:23] pwned: has joined #ruby
[15:45:46] catphish: has left #ruby: ("Leaving")
[15:46:03] pwned: hi, is it possible to use multiple cores using one process in MRI ruby ?
[15:47:17] cschneid: has joined #ruby
[15:48:03] Renich: has joined #ruby
[15:49:07] Renich: has joined #ruby
[15:49:38] pwned: I'm imagining perhaps there could be a gem that delegates some work to pthreads?
[15:56:06] havenwood: pwned: Ruby Threads are backed by pthreads but there's a global vm lock (GVL) that sometimes prevents parallel.
[15:57:30] havenwood: pwned: Here's a three-part article on how the GVL (used to be called GIL) works: https://www.jstorimer.com/blogs/workingwithcode/8085491-nobody-understands-the-gil
[15:57:46] polishdub: has joined #ruby
[15:57:49] pwned: oh that's what I thought it was called, too :-)
[15:57:50] havenwood: For fun, you can unlock the GVL with Fiddle: https://gist.github.com/tenderlove/5733632
[15:58:24] nowhere_man: has joined #ruby
[15:59:16] pwned: wow, he's monkey patching the GVL
[15:59:26] pwned: that's high level
[16:00:29] pwned: thanks havenwood
[16:01:05] bak1an: has joined #ruby
[16:03:53] dinfuehr_: has joined #ruby
[16:09:56] dinfuehr: has joined #ruby
[16:20:18] LunarDinosaur: has joined #ruby
[16:24:03] al2o3-cr: havenwood: that gist needs updating to use rb_thread_call_without_gvl.
[16:29:05] mondz: has joined #ruby
[16:30:46] dinfuehr: has joined #ruby
[16:34:25] Renich: has joined #ruby
[16:35:29] Renich: has joined #ruby
[16:36:47] cnsvc_: has joined #ruby
[16:41:32] jaddison: has joined #ruby
[16:46:11] dinfuehr_: has joined #ruby
[16:54:51] Nicmavr: has joined #ruby
[16:55:42] Rapture: has joined #ruby
[16:55:47] Renich: has joined #ruby
[16:56:55] Renich: has joined #ruby
[16:57:52] keden: has joined #ruby
[16:57:58] nicolasb: has joined #ruby
[17:06:32] desperek: has joined #ruby
[17:07:29] reber: has joined #ruby
[17:24:44] crankharder: has joined #ruby
[17:26:12] al2o3-cr: havenwood: https://gist.github.com/2d65a03e16dee2f1581f75fd5cd5c355
[17:26:50] havenwood: al2o3-cr: nice
[17:30:14] al2o3-cr: use gvl2 if you want interrupt
[17:31:33] cthulchu_: has joined #ruby
[17:42:44] cnsvc_: has joined #ruby
[17:45:13] ajaya: has joined #ruby
[17:54:17] eb0t: has joined #ruby
[17:59:17] mikecmpbll: has joined #ruby
[18:18:21] dbz: has joined #ruby
[18:19:02] dbz_: has joined #ruby
[18:22:53] robscomputer: has joined #ruby
[18:26:20] eckhardt_: has joined #ruby
[18:35:41] clemens3: has joined #ruby
[18:41:53] cnsvc_: has joined #ruby
[18:43:45] desnudopenguino: has joined #ruby
[18:44:27] sarink: has joined #ruby
[18:54:36] orbyt_: has joined #ruby
[18:57:18] Renich: has joined #ruby
[18:57:43] gix: has joined #ruby
[18:57:46] tdy: has joined #ruby
[19:00:45] sarink: has joined #ruby
[19:01:02] yokel: has joined #ruby
[19:05:11] za1b1tsu: has joined #ruby
[19:11:34] sarink: has joined #ruby
[19:19:17] houhoulis: has joined #ruby
[19:25:33] reber: has joined #ruby
[19:28:02] Exuma: has joined #ruby
[19:29:59] ramfjord: has joined #ruby
[19:39:16] \void: has joined #ruby
[19:40:59] bak1an: has joined #ruby
[19:42:45] Fernando-Basso: has joined #ruby
[19:43:10] keden: has joined #ruby
[19:48:04] sarink: has joined #ruby
[19:52:28] za1b1tsu: has joined #ruby
[19:54:20] sarink: has joined #ruby
[19:54:31] za1b1tsu: has joined #ruby
[19:55:09] sarink: has joined #ruby
[19:59:51] havenwood: @baweaver's RubyConf talk was just posted: https://www.youtube.com/watch?v=x3b9KlzjJNM
[19:59:55] graphene: has joined #ruby
[20:00:21] havenwood: (We get an IRC #ruby channel shoutout.) :)
[20:03:35] Blaguvest: has joined #ruby
[20:09:26] GodFather: has joined #ruby
[20:12:41] Renich: has joined #ruby
[20:13:44] Renich: has joined #ruby
[20:20:43] Mike11: has joined #ruby
[20:23:15] bmurt: has joined #ruby
[20:24:14] ur5us: has joined #ruby
[20:24:43] sebuba: has joined #ruby
[20:27:00] SeepingN: has joined #ruby
[20:30:27] GodFather: has joined #ruby
[20:31:15] Guest21835: has joined #ruby
[20:34:42] miah: such a fun talk
[20:34:51] miah: baweaver did such a great job
[20:39:47] baweaver: Much fun and pun were had, I hope you all enjoy it :D
[20:40:39] waheedi: has joined #ruby
[20:41:48] havenwood: &>> %w[f p].sample + 'un'
[20:41:51] rubydoc: # => "pun" (https://carc.in/#/r/5nwc)
[20:42:07] baweaver: It's a bundle of fun
[20:45:10] LunarDinosaur: has joined #ruby
[20:47:51] LunarDinosaur: has joined #ruby
[20:49:21] SeepingN: from price pfister
[20:54:03] Renich: has joined #ruby
[20:54:19] Blaguvest: has joined #ruby
[20:55:06] Renich: has joined #ruby
[20:57:11] Guest21835: has joined #ruby
[21:07:56] bak1an: has joined #ruby
[21:13:30] jeffreylevesque_: has joined #ruby
[21:15:18] roshanavand: has joined #ruby
[21:18:08] orbyt_: has joined #ruby
[21:20:29] nickjj_: has joined #ruby
[21:21:40] lxsameer: has joined #ruby
[21:26:57] graphene: has joined #ruby
[21:30:10] Puffball: has joined #ruby
[21:32:12] jeffreylevesque: has joined #ruby
[21:32:15] orbyt_: has joined #ruby
[21:32:57] Freshnuts: has joined #ruby
[21:37:24] sgen: has joined #ruby
[21:38:58] GodFather: has joined #ruby
[21:49:20] cschneid: has joined #ruby
[22:01:29] Renich: has joined #ruby
[22:01:58] jaddison: has joined #ruby
[22:02:35] venmx: has joined #ruby
[22:06:17] mochiyoda: has joined #ruby
[22:07:49] patr0clus: has joined #ruby
[22:10:18] al2o3-cr: has joined #ruby
[22:11:44] LunarDinosaur: has joined #ruby
[22:28:30] keden: has joined #ruby
[22:32:53] cnsvc_: has joined #ruby
[22:37:37] keden: has joined #ruby
[22:41:07] tdy: has joined #ruby
[22:53:43] agent_white: has joined #ruby
[22:57:08] cnsvc_: has joined #ruby
[23:01:16] cd: has joined #ruby
[23:01:51] Renich: has joined #ruby
[23:02:22] Renich: has joined #ruby
[23:06:26] Nicmavr: has joined #ruby
[23:07:41] Renich: has joined #ruby
[23:08:44] Renich: has joined #ruby
[23:11:14] dviola: has joined #ruby
[23:11:48] nowhere_man: has joined #ruby
[23:13:07] uplime: has joined #ruby
[23:16:09] sarink: has joined #ruby
[23:17:55] tjmcginnis: has joined #ruby
[23:19:01] Renich: has joined #ruby
[23:20:07] tdy: has joined #ruby
[23:20:07] Renich: has joined #ruby
[23:36:12] kapil____: has joined #ruby
[23:40:26] Renich: has joined #ruby
[23:41:28] Renich: has joined #ruby
[23:42:37] tdy: has joined #ruby
[23:46:28] Eiam: just watched!
[23:46:36] baweaver: Ah! Enjoy it?
[23:52:20] jaddison: has joined #ruby
[23:56:49] Renich: has joined #ruby
[23:56:59] jcarl43: has joined #ruby
[23:57:21] Renich: has joined #ruby