<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>
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.
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]