havenwood changed the topic of #ruby to: Rules: https://ruby-community.com | Ruby 3.2.2, 3.1.4, 3.0.6, 3.3.0-preview1: https://www.ruby-lang.org | Paste 4+ lines to: https://gist.github.com | Books: https://t.ly/9ua4 | Logs: https://libera.irclog.whitequark.org/ruby/
roadie has joined #ruby
roadie has quit [Ping timeout: 240 seconds]
roadie has joined #ruby
FetidToot has quit [Ping timeout: 240 seconds]
roadie has quit [Ping timeout: 240 seconds]
FetidToot has joined #ruby
gasbag has joined #ruby
gasbag has quit [Client Quit]
Al2O3 has quit [Quit: I'm quitting, thanks for all the sharks.]
markong has quit [Ping timeout: 258 seconds]
roadie has joined #ruby
jprokop has quit [Quit: Leaving.]
roadie has quit [Ping timeout: 240 seconds]
moldorcoder7 has quit [Ping timeout: 246 seconds]
roadie has joined #ruby
caedmon has joined #ruby
roadie has quit [Ping timeout: 240 seconds]
caedmon has quit [Ping timeout: 246 seconds]
jhass has quit [Ping timeout: 240 seconds]
desnudopenguino1 has joined #ruby
desnudopenguino has quit [Ping timeout: 240 seconds]
desnudopenguino1 is now known as desnudopenguino
caedmon has joined #ruby
jhass has joined #ruby
caedmon has quit [Ping timeout: 240 seconds]
duderonomy has joined #ruby
ap4y has quit [Remote host closed the connection]
c10l6832 has joined #ruby
brokkoli_origin has quit [Ping timeout: 260 seconds]
brokkoli_origin has joined #ruby
caedmon has joined #ruby
c10l683 has quit [Ping timeout: 240 seconds]
c10l6832 is now known as c10l683
caedmon has quit [Ping timeout: 258 seconds]
dviola has quit [Ping timeout: 240 seconds]
roadie has joined #ruby
roadie has quit [Ping timeout: 240 seconds]
caedmon has joined #ruby
caedmon has quit [Ping timeout: 260 seconds]
havenwood has quit [Quit: The Lounge - https://thelounge.chat]
havenwood has joined #ruby
ultralan has joined #ruby
ultralan has quit [Remote host closed the connection]
_ht has joined #ruby
reset has quit [Quit: reset]
roadie has joined #ruby
dviola has joined #ruby
grenierm has joined #ruby
roadie has quit [Ping timeout: 240 seconds]
tomtmym has joined #ruby
tomtmym has joined #ruby
tomtmym has quit [Changing host]
factor has quit [Read error: Connection reset by peer]
roadie has joined #ruby
factor has joined #ruby
roadie has quit [Ping timeout: 240 seconds]
gonix has joined #ruby
caedmon has joined #ruby
jhass has quit [Ping timeout: 240 seconds]
caedmon has quit [Ping timeout: 240 seconds]
jhass has joined #ruby
gonix has quit [Ping timeout: 258 seconds]
roadie has joined #ruby
mexen has joined #ruby
roadie has quit [Ping timeout: 240 seconds]
_ht has quit [Quit: _ht]
balo_ has quit [Server closed connection]
balo has joined #ruby
Sankalp has quit [Ping timeout: 268 seconds]
roadie has joined #ruby
otisolsen70 has joined #ruby
jprokop has joined #ruby
Sankalp has joined #ruby
gr33n7007h has quit [Ping timeout: 268 seconds]
Tempesta has quit [Quit: See ya!]
gr33n7007h has joined #ruby
Tempesta has joined #ruby
dvu has joined #ruby
teclator has joined #ruby
johnjaye has quit [Ping timeout: 260 seconds]
johnjaye has joined #ruby
<johnjaye> hmm. did my message show
rvalue has quit [Ping timeout: 240 seconds]
rvalue has joined #ruby
znpy has quit [Ping timeout: 246 seconds]
prophe36 has joined #ruby
Furai has quit [Quit: WeeChat 3.8]
roadie has quit [Quit: ERC 5.5.0.29.1 (IRC client for GNU Emacs 29.0.91)]
nektro has quit [Remote host closed the connection]
nektro has joined #ruby
Furai has joined #ruby
mark22k has quit [Server closed connection]
mark22k has joined #ruby
duderonomy has quit [Ping timeout: 240 seconds]
Pixi` has joined #ruby
Pixi has quit [Ping timeout: 260 seconds]
duderonomy has joined #ruby
roshanavand_ has joined #ruby
friendlypunk has quit [Remote host closed the connection]
friendlypunk has joined #ruby
prophe36 has quit [Ping timeout: 240 seconds]
c10l683 has quit [Ping timeout: 258 seconds]
jvalleroy has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
jvalleroy has joined #ruby
dionysus69 has joined #ruby
grenierm has quit [Ping timeout: 246 seconds]
nona has joined #ruby
BazzaBazaa has joined #ruby
roshanavand_ has quit [Ping timeout: 260 seconds]
roadie has joined #ruby
johnjaye has quit [Ping timeout: 246 seconds]
johnjaye has joined #ruby
roshanavand_ has joined #ruby
rvalue has quit [Ping timeout: 252 seconds]
rvalue has joined #ruby
Momentum has quit [Ping timeout: 265 seconds]
BazzaBazaa has quit [Remote host closed the connection]
BazzaBazaa has joined #ruby
roshanavand_ has quit [Ping timeout: 246 seconds]
szkl has quit [Quit: Connection closed for inactivity]
BazzaBazaa has quit [Ping timeout: 246 seconds]
markong has joined #ruby
phryk has quit [Server closed connection]
phryk has joined #ruby
<adam12> johnjaye: I haven't seen anything.
gr33n7007h has quit [Quit: WeeChat 3.8]
Momentum has joined #ruby
gr33n7007h has joined #ruby
roshanavand_ has joined #ruby
Guest20 has joined #ruby
Guest20 has quit [Client Quit]
znpy has joined #ruby
yassernasc has joined #ruby
fcser has quit [Server closed connection]
fcser has joined #ruby
moldorcoder7 has joined #ruby
brokkoli_origin has quit [Ping timeout: 258 seconds]
reset has joined #ruby
brokkoli_origin has joined #ruby
desnudopenguino1 has joined #ruby
desnudopenguino has quit [Ping timeout: 260 seconds]
desnudopenguino1 is now known as desnudopenguino
caedmon has joined #ruby
___nick___ has joined #ruby
dionysus69 has quit [Remote host closed the connection]
___nick___ has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
___nick___ has joined #ruby
Al2O3 has joined #ruby
___nick___ has quit [Client Quit]
___nick___ has joined #ruby
joto has quit [Server closed connection]
joto has joined #ruby
Linux_Kerio has joined #ruby
Sankalp has quit [Ping timeout: 240 seconds]
<leah2> i'm confused about Thread::Queue, it seems to push a nil element when i close it?
<leah2> "When an empty queue is closed, all consumers blocking on deq will be woken up and given nil."
<leah2> can i distinguish that from sending a nil, hrm
Sankalp has joined #ruby
<adam12> leah2: I don't even know where Thread::Queue is defined... I presumed it would be in thread.c but don't see it.
<leah2> sync.c or so
<leah2> https://l2.re/Aaa1sw reproduces it
<leah2> so i need to detect that closed switches and empty doesnt
<leah2> gah this is all crap
<adam12> Ah yes. thread_sync.c.. naturally. lol.
<leah2> i'll send a sentinel instead -.-
CalculusCats has quit [Server closed connection]
<adam12> That's what I've normally done.
<leah2> but why add this close stuff at all then
<leah2> if it's not reliable
<adam12> I can't actually remember ever closing a queue...
<adam12> Normally I use the queue for a worker setup, so I might send :shutdown instead.
CalculusCats has joined #ruby
caedmon has quit [Ping timeout: 240 seconds]
roshanavand_ has quit [Ping timeout: 258 seconds]
phenom has quit [Server closed connection]
phenom has joined #ruby
BazzaBazaa has joined #ruby
moo- is now known as moo
caedmon has joined #ruby
caedmon has quit [Ping timeout: 240 seconds]
candlestick has joined #ruby
candlestick has left #ruby [#ruby]
teclator has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
caedmon has joined #ruby
TomyWork has joined #ruby
caedmon has quit [Ping timeout: 258 seconds]
candlestick has joined #ruby
candlestick has left #ruby [#ruby]
caedmon has joined #ruby
jprokop has quit [Remote host closed the connection]
BazzaBazaa has quit [Remote host closed the connection]
<adam12> Ah, HTTP nested array params. A fun and also annoying piece of web dev.
<leftylink> pandabot: what's ruby globals
caedmon has quit [Quit: caedmon]
caedmon has joined #ruby
olspookishmagus has quit [Quit: All for nothing]
olspookishmagus has joined #ruby
_ht has joined #ruby
caedmon has quit [Quit: caedmon]
caedmon has joined #ruby
r3m has quit [Read error: Connection reset by peer]
r3m has joined #ruby
donofrio has joined #ruby
<wakaflaka> I want more of that Röyksopp - Melody AM and Flying Lotus - Los Angeles sound (two best electronic music albums of modern times)
<wakaflaka> Sadly, subsequent work from these artists never managed to get back to that sound
<wakaflaka> If anybody knows of anybody similar (and largely unknown), do let me know. Cheers!
markong has quit [Ping timeout: 258 seconds]
roadie has quit [Quit: ERC 5.5.0.29.1 (IRC client for GNU Emacs 29.0.91)]
<ox1eef_> adam12: Rack::Utils can parse those AFAIK.
<adam12> ox1eef_: Yeah. I was actually looking at the source code for that earlier today (and wondering if leah2 cursed at the time they were involved in it :P)
<ox1eef_> :)
<adam12> ox1eef_: I usually just do the "Rails" way, which is where its `field[0][key]`, which is fine but gives me a hash with a bunch of keys I never need.
<leah2> adam12: yes
<leah2> putting that code into rack was a mistake
<ox1eef_> Might be worth making a Roda plugin for it ?
<adam12> I saw somewhere where someone did `field[key][]`, then `.transform` + `.zip`. And thought that was actually kind of simpler, in some weird way. I added some functionality to a param-like plugin I have a while back to experiment with that strategy.
<adam12> But now I know why they use the integer for keys: it allows missing fields.
<adam12> The second approach requires every field to always exist, which might not always be true (a new record would have no `id` or maybe an empty or nil `id` form param).
<ox1eef_> I think the param handling Rails does is a big part of what makes accepts_nested_attributes_for possible.
<adam12> ox1eef_: It is.
<adam12> I'm not using Roda for this project. I did use typecast_params (the Roda plugin in the past) and it worked OK (but it's narly). Also, I used dry-schema for this and it breaks down with the integer keys :|
<adam12> I wonder who pioneered the Rails approach. I remember using the form-array pattern pre-Rails, but never with the integer array indexes.
<adam12> leah2: It's OK. You're still alright in my books. :P
Huckleberry777 has joined #ruby
<ox1eef_> I wouldn't be surprised if it came from PHP.
<leah2> a simple key=value would have been easier and rails could do a magic thing themselves
<wakaflaka> rails <3
<wakaflaka> my rails sites will become so big they'll get featured on rubyonrails.org some day (i'm a dreamer)
<adam12> Basically write-once as far as I am concerned. I dont' think anybody else ever understood it.
<wakaflaka> yo adam, you gotta see this
<adam12> I made an API similer to https://github.com/zendesk/stronger_parameters which has been not too bad, but I don't have it 100% for nested param types yet (I think I need an optional type).
<adam12> leah2: Jeremy/Samuel have been on a pursuit of extracting parts from Rack, which I think is noble, but after all these years, I wish it shipped with a damn flash implementation. I carry my own around for plain Rack/Sinatra apps and I am surprised it's the one piece of middleware never included.
<adam12> leah2: Or maybe it's a Sinatra responsibility (after all, Roda ships with one). But sometimes I want a simple Rack app with no dependencies.
<wakaflaka> man jeremy and samuel
<wakaflaka> <3 them both to death
<leah2> adam12: i'm pretty much out ;)
<wakaflaka> what's missing? :|
<adam12> leah2: I figured. I'm just ranting :P
<leah2> but isnt a flash like 5 loc :>
<wakaflaka> (please do not share)
<adam12> leah2: My last one was 32 LOC
<adam12> I think I stole part of it from Roda. Which I suspect was partly stolen from sinatra-flash.
<adam12> wakaflaka: Does it work? Or does it halucinate a lot of it.
yassernasc has quit [Remote host closed the connection]
<wakaflaka> good q
yassernasc has joined #ruby
<wakaflaka> just hallucinating for now
<adam12> wakaflaka: Cool. I was just curious. Seems valuable if it can take the titles and abstract some sort of knowledge from them.
<wakaflaka> the bit where it takes action, finds your niche, your new domain, generates content and pro-looking related photos
<wakaflaka> still in the works (although the individual parts are done)
<wakaflaka> you can indeed
<adam12> wakaflaka: I'm not great at SEO, but one of my contracts hired a SEO person, so I've seen some of the reports. Some of the suggestions are basically "copy your competitors"
<adam12> and "delete/derank pages that are not crticial and canibalize views". Gotta make Daddy Google happy.
<wakaflaka> yup. same here, doing this to learn seo
<wakaflaka> ouch, yeah
<wakaflaka> i probably need a script to analyze my biz and make sure it's within google's limits
Linux_Kerio has quit [Ping timeout: 252 seconds]
<wakaflaka> already applying a lot of stuff to please google
qxz2 has quit [Server closed connection]
<wakaflaka> schema.org ofcourse, but also not ie. posting 4000 articles at once, but rather in a timely fashion
<adam12> ox1eef_: This is the API I ended up with, which as been reasonably decent so far. Not full-on dry-schema/dry-validation but not as barebones/blocky as typecast_params (from Roda). https://gist.github.com/adam12/d574b04ecc9c1a5b3b90f85658b8c479
<adam12> I think Parameter.values should accept another Hash, with the types there too. Parameter.values({ address: Parameter.string }). But nested params supports tricks like "_delete" => "t", so that would have to be accounted for somehow.
polychromata has quit [Server closed connection]
r3m has quit [Quit: WeeChat 4.0.0-rc1]
r3m has joined #ruby
seisatsu has quit [Server closed connection]
seisatsu has joined #ruby
polychromata has joined #ruby
<ox1eef_> Looks good to me.
grenierm has joined #ruby
caedmon has quit [Quit: caedmon]
Linux_Kerio has joined #ruby
weaksauce has quit [Ping timeout: 260 seconds]
xuochi has joined #ruby
Linux_Kerio has quit [Ping timeout: 240 seconds]
weaksauce has joined #ruby
sarna has joined #ruby
xuochi has quit [Ping timeout: 252 seconds]
xuochi has joined #ruby
TomyWork has quit [Remote host closed the connection]
caedmon has joined #ruby
Spitfire has quit [Server closed connection]
Spitfire has joined #ruby
___nick___ has quit [Ping timeout: 265 seconds]
<ox1eef_> Oh wow the new GitHub layout is nice.
otisolsen70__ has joined #ruby
otisolsen70__ has quit [Remote host closed the connection]
otisolsen70 has quit [Ping timeout: 240 seconds]
donofrio has quit [Ping timeout: 258 seconds]
EvanR has joined #ruby
<EvanR> can someone clarify somewhat what jargon "late binding" means in ruby
subdue has joined #ruby
_ht has quit [Quit: _ht]
<leftylink> could the person who clarifies that also clarify for me: it seems to me that if someone wants early binding, they have to use a statically-typed language; it doesn't seem possible in a dynamically-typed language. is this impression incorrect?
<xuochi> /4
<havenwood> leftylink: Dynamic languages with a JIT make that distinction fairly moot.
<havenwood> (Depending on the JIT.)
<havenwood> YJIT for example will optimize function calls just in time.
braxas has quit [Server closed connection]
<havenwood> --jit ftw
braxas has joined #ruby
yassernasc has quit [Remote host closed the connection]
<havenwood> Or TruffleRuby has the most advanced Ruby JIT at the moment.
<havenwood> JRuby's is nice too.
<xuochi> Although, with TruffleRuby, you can also use the GraalVM native image feature.
Linux_Kerio has joined #ruby
tomtmym has quit [Quit: Gone.]
nmollerup has joined #ruby
markong has joined #ruby
ruby[bot] has quit [Remote host closed the connection]
ruby[bot] has joined #ruby
lucartc has joined #ruby
Linux_Kerio has quit [Ping timeout: 260 seconds]
<lucartc> Does someone know where the 'fetch' method/attribute is defined in this gem https://github.com/SeleniumHQ/selenium/blob/selenium-4.7.1-ruby/rb/lib/selenium/webdriver/devtools/network_interceptor.rb ? I've been studying it for quite some time and cant figure it out. This gem is used alongside with selenium-devtools, and my devtools version is 0.109.0
<lucartc> I know that fetch, in line 50, is a reference to Selenium::DevTools::V109::Fetch. 'devtools' is a Selenium::WebDriver::DevTools object
brokkoli_origin has quit [Ping timeout: 252 seconds]
<ox1eef_> lucartc: You might be able to find it easily if at the call site you use 'p method(:fetch).source_location'.
brokkoli_origin has joined #ruby
<lucartc> oxleef_ thank you, I'm gonna try it
xuochi has quit [Quit: leaving]