Activity Graph

Page 1 of 258 | Next »


[21:32:54] baweaver:
[21:33:05] baweaver: used in production, bad things happened, please fix.


[00:49:00] baweaver: Caerus: Me and havenwood both gave talks this year too.


[01:18:03] baweaver: Yeah, it was ImageTragic


[00:36:58] baweaver: Read through Enumerable, see what you find
[00:38:07] baweaver: There's a method in there which does pretty well exactly that
[04:59:57] baweaver: Working on interpreting NodePattern in RuboCop
[05:00:03] baweaver: May end up rewriting some fun parts of it.
[05:00:45] baweaver: To truly understand something you must be able to write it yourself I figure
[23:40:56] baweaver: havenwood loves them some modiule_method


[06:01:36] baweaver: Radar / sevenseacat - So I did a fun thing
[06:01:53] baweaver: I listed out all my crazy lemur talk ideas:
[06:02:02] baweaver: Any of them particularly interesting?


[17:40:41] baweaver: &>> 'abcde'.chars.each_cons(2)


[23:01:58] baweaver: riceandbeans: What're you trying to do?
[23:03:58] baweaver: because you probably want map.
[23:04:12] baweaver: but placeholder names make that hard to know.
[23:05:15] baweaver: map then select
[23:05:40] baweaver: If you can get an example written that'd help


[07:08:41] baweaver: havenwood: we should add parser later
[07:08:54] baweaver: VM ISec is kinda nasty
[16:41:48] baweaver: matthewd:
[16:42:11] baweaver: Submitted some of that async stuff I'd mentioned earlier.
[16:42:14] baweaver: We'll see if there's much interest. I already have most of the code ready for it if they are though.


[20:50:02] baweaver: Who all's around?
[20:50:04] baweaver: I have something fun
[20:50:25] baweaver: miah / phaul / Radar / matthewd / etc
[20:50:57] baweaver: Open 8 to 10 tabs of this -
[20:51:13] baweaver: You'll see, fun incoming :)
[20:52:02] baweaver: Also hit connect on the tabs
[20:52:34] baweaver: 8 to 10 because you're probably not all in the same place, and that gives all the instruments
[20:53:27] baweaver: Ah, and let me know when you're connected
[20:54:02] baweaver: If it says connected it's fine
[20:54:04] baweaver: Getting a few other people in on it
[20:54:04] baweaver: Nope, I have to start it up.
[20:54:35] baweaver: You'll probably want 8 phaul
[20:54:47] baweaver: Waiting on one more person to get clients connected and I'll rev things up
[20:56:02] baweaver: Now you might notice some lemurs wandering in right about now.
[20:56:18] baweaver: and when they wander in, there's a song they like to play.
[20:57:19] baweaver: You've just seen the ActionCable Symphony, a distributed orchestra performed by cartoon lemurs.
[21:01:12] baweaver: If anyone else sees this later, ping me and I can get it running


[19:52:28] baweaver: Someone tell Swyper whenever they get back on that - and _ aren't the same
[19:55:45] baweaver: Oi Swyper, what character are you using for a placeholder there on line 13?
[19:56:27] baweaver: ....versus the ones on 50 and 53?
[19:56:50] baweaver: Also use `attr_reader` for guess_word
[19:57:19] baweaver: Make sure to read the RSpec errors carefully, it would have probably told you something like this.
[19:57:37] baweaver: `attr_reader :guess_word` will make a method for guess_word
[19:57:57] baweaver: making 22, 50, and 53 unnecessary
[20:01:06] baweaver: Asterisk is more visually distinct `*`
[20:16:03] baweaver: Radar: You've dealt with webpacker right? Any idea how to import css from a node_module? Anything I'm finding right now isn't working out.
[20:20:50] baweaver: Lovely -


[02:28:04] baweaver: havenwood: how do you get a list of Ruby operators?
[02:29:09] baweaver: &>> Integer.methods.grep(/^[^a-z]{1,3}$/)


[02:45:09] baweaver: ...and some more practical examples:
[02:45:09] baweaver: Pattern Matching just landed in Ruby as an experimental feature:
[19:40:23] baweaver: lupine: yep, I wrote the articles on it:


[15:58:39] baweaver: havenwood: It brings me great joy to do this
[15:58:58] baweaver: Beat you to a Ruby update XD
[20:28:35] baweaver: Guess what hit Ruby core:
[20:42:35] baweaver: ACTION shrugs
[20:42:36] baweaver: That's the one that came to mind immediately
[20:42:41] baweaver: Also a note not to write articles at 2am
[20:48:03] baweaver: Honestly me either
[20:48:35] baweaver: The keys bit confuses me, and it seems really prone to race conditions
[20:48:36] baweaver: I'll need to poke Nightly for a while to see what in the world it's even doing.
[21:09:55] baweaver: zenspider: Fair.
[21:10:07] baweaver: It feels like we all gave a ton of input and they went their own way
[21:10:39] baweaver: Some of it got in but they've really taken it in another direction for other parts.


[20:43:25] baweaver: What the right thing is tends to change as time goes by
[20:43:46] baweaver: In early Ruby everyone was enamored with monkey patching. That one certainly didn't age well.


[16:49:55] baweaver: *.net *.split


[18:08:05] baweaver: IGnorAND: The thing to remember about Metz's rules are that they're not a hard and fast law
[18:08:23] baweaver: They were designed to give constraints to people who wanted them as an arbitrary guideline of what to pursue
[18:08:48] baweaver: Artificially refactoring your code to hit those numbers may be counter-intuitive
[18:12:17] baweaver: Yeah, that's what I'd keep in mind in general :)
[18:12:27] baweaver: They're good guidelines in general
[18:12:36] baweaver: just some folks take them very religiously and get carried away.
[18:13:13] baweaver: Have you read her book, Practical Object Oriented Design in Ruby?
[18:14:16] baweaver: It's a pretty good book
[18:14:26] baweaver: Typically I recommend it and Eloquent Ruby


[20:33:48] baweaver: Just been busy on my end getting ready for RailsConf
[20:34:51] baweaver: maxdoubt: Depends, though a lot tend to be on Slack anymore
[20:35:14] baweaver: I tend to dislike that though as I have enough slacks already and it gets to be a mess keeping track of all of them.
[20:35:29] baweaver: terens: 404
[20:37:56] baweaver: Tech demo is coming up on Friday at work to see how it works
[20:38:04] baweaver: Just bought to use


[20:02:18] baweaver: Regexp.union str.chars


[04:29:14] baweaver: havenwood: Did you write an article on it yet?


[18:40:55] baweaver: As someone who's built similar functionality in-house, it's cheaper in most cases than doing the same yourself.


[18:30:30] baweaver: JL: RubyKatas iirc
[18:30:35] baweaver: Or RubyMonk
[18:30:52] baweaver: The latter is up and down depending on how much the owners are paying attention


[04:14:17] baweaver: sevenseacat: Well this makes my work even easier :D
[04:14:18] baweaver:
[04:14:52] baweaver: Trying to keep track of connected users to send them all instrument tracks
[04:15:32] baweaver: This gives me a viable way to track connected users, define a channel path for each of them, and a way to send/receive whatever to each individual client :D
[04:15:44] baweaver: Which was the annoying problem I've been trying to find a solution for for a while
[04:19:49] baweaver: Also validates my idea of using Redis for connected users
[22:58:02] baweaver: If you're using TruffleRuby that speed hit is a lot smaller.
[22:59:13] baweaver:
[23:00:22] baweaver:
[23:00:33] baweaver: havenwood: It's showtime
[23:01:00] baweaver: your favorite topic


[05:01:46] baweaver: Aren't we all anymore? :P
[05:01:47] baweaver: How's things sevenseacat?
[07:30:23] baweaver: Woo, just finished all the new lemurs


[00:55:08] baweaver:
[03:36:03] baweaver: t0xik: No. What do you think you need it for?
[03:36:04] baweaver: havenwood: Don't correct that :P
[03:36:05] baweaver: or you either al2o3-cr
[04:21:17] baweaver: ^ that. It's called the XY problem, you want a specific solution and fixate on that when another solution may be available t0xik
[04:24:57] baweaver: Most of the time you use methods from Enumerable
[04:26:13] baweaver: Name a use case from C where you would use a goto and we can show you a method from Ruby to do the same
[18:24:53] baweaver: It is, by about 10x graft
[18:24:57] baweaver: I was curious so I looked.
[18:25:39] baweaver: I kinda wonder if that holds up in TruffleRuby
[18:26:09] baweaver: havenwood: `wc -l` vs `` in TruffleRuby?
[18:26:24] baweaver: Don't have it installed on the work computer, should probably fix that
[23:14:34] baweaver: 'morning Radar
[23:21:19] baweaver: &ri Enumerable#transform_values
[23:21:27] baweaver: &ri Hash#transform_values


[04:14:59] baweaver: keyword parameters for one
[04:15:09] baweaver: Though ** would work
[04:15:34] baweaver: Na, just use keyword params
[21:46:46] baweaver: Radar: ohai
[21:47:40] baweaver: Tons of new lemurs, websockets, and react are coming
[21:48:02] baweaver: Busy, it seems. Hackathon and conference coming up next week, then moving, then sprint to RailsConf
[21:48:42] baweaver: (moving closer to work)


[01:42:58] baweaver:
[04:34:23] baweaver:


[21:06:26] baweaver: Depends on what you mean by sort.
[21:06:49] baweaver: Anything is sortable if you have a criteria to sort on
[21:09:44] baweaver: xco: You can sort by more than keys
[21:10:36] baweaver: It looks like you're trying to sort by the value, but the problem is if there's more than one value in there
[21:10:43] baweaver: Why does the data look like that?
[21:10:52] baweaver: essentially it's mimicking array indexes
[21:11:28] baweaver: What does the original look like, and what problem are you trying to solve?
[21:13:59] baweaver: &ri Enumerable#each_with_index
[21:14:52] baweaver: >> [4, 1, 5].each_with_index.max_by(&:last)
[21:15:04] baweaver: >> [4, 1, 5].each_with_index.minmax_by(&:last)
[21:15:15] baweaver: >> [4, 1, 5].each_with_index.sort_by(&:last)
[21:15:29] baweaver: ack, by first rather
[21:19:22] baweaver: You're still working with the first element in any case
[21:19:28] baweaver: Just do something with the block
[21:22:26] baweaver: Mostly Sublime.
[21:23:03] baweaver: Been trending towards VS Code because of some React work


[05:14:27] baweaver:
[18:19:53] baweaver: dawidof: YARDoc tends to be fairly standard for docs.
[18:20:04] baweaver: It also allows you to get a server up for documentation
[18:20:23] baweaver: and gemstash may well have a YARD flag later for hosting docs for any installed gem on the server


[23:03:16] baweaver: zenspider: evil me is writing in only double-quotes for the book
[23:03:39] baweaver: It feels like a bad idea to teach newbies otherwise, too much potential for confusion for very little gain.
[23:07:02] baweaver: cxl: HIRB, but it hasn't been updated in quite a while:
[23:07:59] baweaver: Fair. Trying not to add a ton of nuance to the book, and more of just "do it this way"


[17:19:41] baweaver: Excess Flood
[17:19:51] baweaver: has joined #RubyonRails-offtopic
[17:19:51] baweaver: has joined #elixir-lang
[17:19:51] baweaver: has joined #logga
[17:19:51] baweaver: has joined #ruby
[17:19:51] baweaver: Changing host
[17:19:51] baweaver: has joined #ruby
[17:19:51] baweaver: has joined #logga
[17:19:51] baweaver: has joined #elixir-lang
[17:19:51] baweaver: has joined #RubyonRails-offtopic
[17:20:26] baweaver: has joined #ruby-offtopic
[17:20:26] baweaver: has joined #RubyOnRails


[22:21:42] baweaver: sagax: Use begin / rescue
[22:31:58] baweaver: sagax: Use begin / rescue, you'll have a lot easier time.
[22:32:08] baweaver: What code do you _need_ it for?
[22:32:27] baweaver: begin / rescue can also return a result.
[22:33:12] baweaver: Very often when one thinks they _need_ a language feature that's not entirely accurate. It depends heavily on context, and sometimes we're bent on shoehorning our problem to match.
[22:33:43] baweaver: What problem are you trying to solve?
[22:33:44] baweaver: because it sounds a lot like `break` or `next`
[22:34:11] baweaver: You're fixating on try/catch, not your actual problem.
[22:34:18] baweaver: Do you have a code example?
[22:34:38] baweaver: You can use `return` for that as well.
[22:35:22] baweaver: Can you show us some example code?:
[22:35:44] baweaver: What if we said that try/catch is ugly?
[22:35:55] baweaver: If you're bent on using it, use it.
[22:36:32] baweaver: leftylink: fixation is fun.
[23:08:08] baweaver: Yeah, just use `return`.
[23:09:04] baweaver: You're not gaining any clarity there.
[23:09:43] baweaver: If anything you're trying to ad-hoc on pattern matching
[23:10:01] baweaver: It's an approximation of an Either type.
[23:10:32] baweaver: You're using throw/catch as a psuedo-either type to pass additional context with returns
[23:10:49] baweaver: It's more commonly known as Railway Oriented Programming:
[23:11:42] baweaver: I'm not really sure what you want here.
[23:11:44] baweaver: You're fixated on one solution, so just use it.
[23:11:53] baweaver: Just be warned it's not very common and will likely confuse other programmers.
[23:22:35] baweaver: How's things phaul?


[04:53:38] baweaver: has joined #RubyonRails-offtopic
[04:53:39] baweaver: has joined #RubyOnRails
[04:53:40] baweaver: has joined #ruby-offtopic
[04:53:43] baweaver: has joined #elixir-lang
[04:53:44] baweaver: has joined #ruby
[04:53:45] baweaver: has joined #logga
[22:20:27] baweaver: ACTION reads back
[22:21:12] baweaver: What's `nwserver` doing BoomerBile?
[22:21:36] baweaver: Left I guess.
[22:21:55] baweaver: al2o3-cr: Doesn't really read like bashing, just annoyance at something breaking.


[23:26:29] baweaver: Darmani: How do blocks work in Ruby?
[23:26:55] baweaver: Give you a hint: they're not parens in this case.
[23:27:08] baweaver: Also that scan isn't going to do what you think it will.
[23:27:33] baweaver: Also it's `grade`, not `string`
[23:27:57] baweaver: psuedo code might not run so well in Ruby :P
[23:28:15] baweaver: also `sort_by` only works on Enumerable types.
[23:28:29] baweaver: Is the grade a string or what is it?
[23:28:40] baweaver: If it's an array you might want to call it grades instead.
[23:28:48] baweaver: and also split the string
[23:29:08] baweaver: Line 5 though, that's a string?
[23:29:42] baweaver: What's an example of input?
[23:29:46] baweaver: and the expected output?
[23:30:42] baweaver: What's in the string?
[23:30:53] baweaver: and what's a greade
[23:31:02] baweaver: Anything doesn't really help.
[23:31:09] baweaver: There we go
[23:31:28] baweaver: and you want to sort by those grades lexically? (alphabetical order)
[23:31:54] baweaver: You want sort, which yields two items
[23:32:11] baweaver: collection.sort { |a, b| ... }
[23:32:27] baweaver: sort_by if you have a property available
[23:32:49] baweaver: I wonder...
[23:33:06] baweaver: &>> %w(A+ F B- B B+).sort
[23:33:45] baweaver: So it'll get the letter right, you just have to give a higher priority to the +.
[23:33:46] baweaver: which property?
[23:33:56] baweaver: No, that's what you're sorting
[23:34:01] baweaver: each item would have a property
[23:37:17] baweaver: Make a map for the second property
[23:37:45] baweaver: yeah, sort_by would work here, not thinking clearly.
[23:43:43] baweaver: &>> OPS = { '+' => 0, nil => 1, '-' => 2 }; %w(A+ F B- B B+).sort_by { |g| [g[0], OPS[g[1]]] }
[23:47:57] baweaver: Just tend not to post full solutions in channel
[23:48:04] baweaver: Kinda curious how I'd teach that though
[23:50:49] baweaver: It's a hard balance
[23:51:04] baweaver: iirc Darmani was a bit vampy


[04:36:59] baweaver: Ruby isn't that smart.