havenwood changed the topic of #ruby to: Rules: https://ruby-community.com | Ruby 2.7.2, 2.6.6, 3.0.0-preview1: https://www.ruby-lang.org | Paste 4+ lines of text to https://dpaste.org | Books: https://goo.gl/wpGhoQ | Logs: https://irclog.whitequark.org/ruby | BLM <3 | Can't talk? Register/identify with NickServ
<ignorand> "-request_time_iso_date, phone_number, -id".split(',').map{|key| key.strip.start_with?('-')?"#{key.strip.slice(1, key.strip.length-1)} :desc":key.strip } <- would this work?
postmodern has joined #ruby
<Nowaker> ignorand: it's a good start. it's still getting you an array of strings but it's close to what you want
<pwnd_sfw> https://gist.github.com/rob-saunders/b06d409bd77c7e7a4754660acbb9acca So, I'm gathering this syntax is not correct, but I'm not sure what I should be doing otherwise
<pwnd_sfw> since this feels right lol
<pwnd_sfw> It's telling me my "check_xxx" methods are not defined
<Nowaker> pwnd_sfw: works for me on rb 2.6.3
<Nowaker> ah, that's not a syntax error
<Nowaker> it's a runtime error
<pwnd_sfw> I have updated the gist with my full code and the sample data
aremaref has quit [Ping timeout: 265 seconds]
<pwnd_sfw> it may not run or do what it's supposed to yet. I got to testing the code, but got stuck at the case
<pwnd_sfw> statement
<ignorand> Nowaker: "-request_time_iso_date, phone_number, -id".split(',').map{|key| key.strip.start_with?('-')?"#{key.strip.slice(1, key.strip.length-1)}: :desc":":#{key.strip}"}.join(', ') seems to create a string, but I can't sent it to order
<pwnd_sfw> I don't know yet that the check methods do things appropriately
<pwnd_sfw> But that will be something I will tackle later.
drincruz_ has quit [Ping timeout: 260 seconds]
<ignorand> Nowaker: .split(',').map{|key| key.strip.start_with?('-')?"#{key.strip.slice(1, key.strip.length-1)} DESC":key.strip}.join(', ') seems to work :)
aremaref has joined #ruby
<leftylink> oh
<pwnd_sfw> updated gist has syntax that doesn't break
<pwnd_sfw> control flow is still broken though
<leftylink> it's important to note that functions can't be called before they're defined
<pwnd_sfw> This isn't php now
<leftylink> this is ruby
<leftylink> &>> foo; def foo; :no end
<rubydoc> stderr: -e:4:in `<main>': undefined local variable or method `foo' for main:Object (NameError)... check link for more (https://carc.in/#/r/a25e)
weaksauce has quit [Quit: Textual IRC Client: www.textualapp.com]
<leftylink> &>> def foo; bar end; def bar; :yes end; foo
<rubydoc> # => :yes (https://carc.in/#/r/a25f)
<leftylink> big difference between those two
<pwnd_sfw> Good looks lol
<pwnd_sfw> that worked
<pwnd_sfw> I guess I'm usually working with class definitions instead of just in main
<pwnd_sfw> pomodoro just popped. I should be in a better spot now ty
bambanx has quit [Ping timeout: 260 seconds]
haxx0r has joined #ruby
<haxx0r> It's so easy, yet i struggle hard. https://i.imgur.com/GhcfPTd.png is there a certain algorithm idea which i can use to actually go from 1 to 1.1.1 ? I tried it myself, failed. i tried it with rubytree but i can't wrap my head around on how to create the tree based on given input. might also be a factor that it's 3am
roshanavand has quit [Ping timeout: 240 seconds]
<haxx0r> the only solution i have in my mind is with loads of spaghetti code :-)
cthu| has quit [Read error: Connection reset by peer]
cthu| has joined #ruby
weaksauce has joined #ruby
roshanavand has joined #ruby
lucasb has quit [Quit: Connection closed for inactivity]
Rudd0 has quit [Ping timeout: 240 seconds]
roshanavand has quit [Quit: Quitting...]
umjisus has quit [Ping timeout: 240 seconds]
drincruz_ has joined #ruby
drincruz_ has quit [Ping timeout: 272 seconds]
TCZ is now known as toxic_worm
drincruz_ has joined #ruby
poguez_ has quit [Quit: Connection closed for inactivity]
AndyC has quit [Ping timeout: 265 seconds]
gavlee has quit [Ping timeout: 260 seconds]
<pwnd_sfw> all of the sample data for day 4 AOC returns results that it is supposed to but my answer is still incorrect lol
gavlee has joined #ruby
<leftylink> make own sample data
aremaref has quit [Ping timeout: 260 seconds]
aremaref has joined #ruby
<havenwood> haxx0r: If you can make your input code available as text, you'll have a much better chance of getting someone to bite on a solution.
<havenwood> haxx0r: https://dpaste.org
<pwnd_sfw> There's something wrong with this challenge..
pienkowb has quit []
<pwnd_sfw> I can't find anything wrong
<leftylink> well, if the code is still as it was in https://gist.github.com/rob-saunders/b06d409bd77c7e7a4754660acbb9acca, then there certainly is something
<pwnd_sfw> It has to be somewhere in the constraints of a valid passport. Part 1 validates the rest of the process.
<pwnd_sfw> It's not anything like that gist
<pwnd_sfw> The sample data is the same
<pwnd_sfw> HMMMM, well I have found a passport that should have passed
<pwnd_sfw> I believe anyways
<pwnd_sfw> Nope, I lied
aremaref has quit [Ping timeout: 246 seconds]
<pwnd_sfw> I think it's time to learn pry lol
bambanx has joined #ruby
umjisus has joined #ruby
ChmEarl has quit [Quit: Leaving]
aremaref has joined #ruby
bambanx has quit [Quit: Leaving]
tosaraja has quit [*.net *.split]
batisi[m] has quit [*.net *.split]
gypsy5[m] has quit [*.net *.split]
jo-so has quit [*.net *.split]
turt2live has quit [*.net *.split]
hahuang65 has quit [*.net *.split]
peteretep has quit [*.net *.split]
cstrahan has quit [*.net *.split]
Guest41501_ has quit [*.net *.split]
sparr has quit [*.net *.split]
darris has quit [*.net *.split]
kermit has quit [*.net *.split]
kevinsjoberg has quit [*.net *.split]
r3my has quit [*.net *.split]
mnemon has quit [*.net *.split]
kashike has quit [*.net *.split]
wnd has quit [*.net *.split]
Rush has quit [*.net *.split]
darris has joined #ruby
helpa has quit [Remote host closed the connection]
helpa has joined #ruby
c0san0stra has quit [Ping timeout: 245 seconds]
tekk has quit [Ping timeout: 264 seconds]
Nahra has quit [Quit: leaving]
tekk has joined #ruby
tosaraja has joined #ruby
batisi[m] has joined #ruby
gypsy5[m] has joined #ruby
turt2live has joined #ruby
Guest41501_ has joined #ruby
peteretep has joined #ruby
cstrahan has joined #ruby
kevinsjoberg has joined #ruby
kermit has joined #ruby
r3my has joined #ruby
kashike has joined #ruby
mnemon has joined #ruby
wnd has joined #ruby
Rush has joined #ruby
jo-so has joined #ruby
hahuang65 has joined #ruby
aremaref has quit [Ping timeout: 265 seconds]
sparr has joined #ruby
sparr has quit [Changing host]
sparr has joined #ruby
c0san0stra has joined #ruby
bambanx has joined #ruby
toxic_worm has quit [Remote host closed the connection]
jottr has quit [Quit: WeeChat 3.0]
elcuervo has joined #ruby
cuerbot has quit [Ping timeout: 240 seconds]
Rudd0 has joined #ruby
bambanx has quit [Quit: Yaaic - Yet another Android IRC client - http://www.yaaic.org]
AndyC has joined #ruby
umjisus has quit [Ping timeout: 264 seconds]
umjisus has joined #ruby
ua has quit [Quit: Leaving]
ua has joined #ruby
gix- has joined #ruby
gix has quit [Disconnected by services]
umjisus has quit [Ping timeout: 264 seconds]
cloud69 has joined #ruby
orbyt_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
cd has quit [Quit: cd]
mozzarella has quit [Read error: Connection reset by peer]
baojg has quit [Remote host closed the connection]
baojg has joined #ruby
postmodern has quit [Quit: Leaving]
nowhere_man has joined #ruby
drincruz_ has quit [Ping timeout: 256 seconds]
jenrzzz has joined #ruby
jenrzzz has quit [Ping timeout: 265 seconds]
jenrzzz has joined #ruby
blackmesa has joined #ruby
Technodrome has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
donofrio has quit [Remote host closed the connection]
mozzarella has joined #ruby
al2o3-cr has left #ruby ["WeeChat 2.9"]
umjisus has joined #ruby
cthu| has quit [Ping timeout: 260 seconds]
nowhere_man has quit [Ping timeout: 272 seconds]
cloud69 has quit [Quit: Connection closed for inactivity]
blackmesa has quit [Ping timeout: 265 seconds]
nofxx has quit [Read error: Connection reset by peer]
nofxx has joined #ruby
haxx0r has quit [Quit: Connection closed]
junaidnaseer2 has joined #ruby
cloud69 has joined #ruby
AndyC has quit [Ping timeout: 240 seconds]
Axy has joined #ruby
Axy has quit [Changing host]
Axy has joined #ruby
Mia has quit [Ping timeout: 256 seconds]
baojg has quit [Remote host closed the connection]
baojg has joined #ruby
batisi[m] has quit [Quit: Idle for 30+ days]
gavlee has quit [Ping timeout: 260 seconds]
gix- has quit [Ping timeout: 240 seconds]
ignorand has quit [Disconnected by services]
jenrzzz has joined #ruby
jenrzzz has quit [Ping timeout: 260 seconds]
tempate60 has joined #ruby
<tempate60> Hello. Is there a more concise way of doing some_list.map{ |bar| foo(bar) } ?
<leftylink> there is *a* way, but whether you'll like it is not guaranteed
<leftylink> pinkpandabot: rb [1, 2, 3, 4, 5].map(&method(:print))
<pinkpandabot> 12345[nil, nil, nil, nil, nil] - https://carc.in/#/r/a26w
<leftylink> I don't think it even manages to be fewer characters
<tempate60> It's probably not worth it
<tempate60> Thanks anyway
nowhere_man has joined #ruby
jenrzzz has joined #ruby
Technodrome has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<nakilon> leftylink, I guess you can remove one pair of ()
<nakilon> IIRC
<jhass> to save a whooping whole of 1 character? :D
jenrzzz has quit [Ping timeout: 260 seconds]
<nakilon> yes, /r/frugal
jenrzzz has joined #ruby
Technodrome has joined #ruby
tempate60 has quit [Remote host closed the connection]
_whitelogger has joined #ruby
davispuh has joined #ruby
<cloud69> whooptiedoo!
<cloud69> burgerking whooper cheese, just for you!
rorymckinley has joined #ruby
<rorymckinley> I am seeing behaviour with a script that has its STDOUT output piped to awk, where STDOUT.sync does not behave the way I think the docs say it should. Code plus observations here: https://gist.github.com/rorymckinley/fe7a78e3022a936275664af9311926a5. Any ideas?
ruby[bot] has quit [Ping timeout: 272 seconds]
Atro has quit [Ping timeout: 272 seconds]
noodle has quit [Ping timeout: 272 seconds]
junaidnaseer2 has quit [Ping timeout: 272 seconds]
shenghi has quit [Ping timeout: 272 seconds]
shenghi1 has joined #ruby
EvilJStoker has quit [Ping timeout: 272 seconds]
tv- has quit [Ping timeout: 272 seconds]
<jhass> rorymckinley: maybe it's awk? https://p.jhass.eu/9b.txt
EvilJStoker has joined #ruby
noodle has joined #ruby
fowl has quit [Ping timeout: 272 seconds]
<jhass> or even just the pipe, idk
fowl has joined #ruby
Atro has joined #ruby
junaidnaseer2 has joined #ruby
claw has joined #ruby
tv- has joined #ruby
<rorymckinley> jhass: Hmm - I had not thought of that - my assumption is usually that I am doing something wrong :) - thank you for the suggestion, I will do some further experimentation.
<cloud69> Is there a way to force Bundler to install a gem? Getting `Bundler could not find compatible versions for gem "solidus"` when trying to install https://github.com/solidusio-contrib/solidus_multi_domain because I'm running Solidus 3.0.0.alpha: https://gist.github.com/cloud69420/4b612c94574d63d929b617f7176198fa
<rorymckinley> jhass: This suggests that you may be on to something: https://unix.stackexchange.com/a/33655
<jhass> well, fwiw even cat shows the same behaviour
<jhass> cloud69: I guess you want to make solidus_multi_domain a git dependency since the last tag is from 2016
nowhere_man has quit [Remote host closed the connection]
<cloud69> Great idea! Thanks :)
nowhere_man has joined #ruby
junaidnaseer2 has quit [Remote host closed the connection]
ellcs has joined #ruby
PaulePanter has quit [Remote host closed the connection]
PaulePanter has joined #ruby
dviola has quit [Ping timeout: 272 seconds]
akem__ has joined #ruby
dviola has joined #ruby
akem_ has quit [Ping timeout: 240 seconds]
akem__ has quit [Ping timeout: 246 seconds]
Technodrome has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nowhere_man has quit [Ping timeout: 272 seconds]
gavlee has joined #ruby
ellcs has quit [Remote host closed the connection]
ellcs has joined #ruby
TCZ has joined #ruby
ellcs has quit [Ping timeout: 260 seconds]
weaksauce has quit [Ping timeout: 264 seconds]
bkuhlmann has joined #ruby
crankharder has joined #ruby
Technodrome has joined #ruby
bkuhlmann has quit []
pwnd_sfw6 has joined #ruby
pwnd_sfw has quit [Ping timeout: 272 seconds]
pwnd_sfw6 is now known as pwnd_sfw
<pwnd_sfw> leftylink, I didn't put boundaries on my regexs.. One passport was getting validated improperly. There was no way I was going to manually find that haha
deadbee has joined #ruby
akem has joined #ruby
<adam12> Over the last 12 days, I've been conducting an experiment by building docs for every gem published on Rubygems. It's been .. interesting.
<adam12> 2459 gems (avg 205 per day). Largest one built had docs 7.75 MB compressed and longest one took 54 minutes to build O_O
cd has joined #ruby
<adam12> (on average they are 159kb compressed and take 8 seconds to build)
pwnd_sfw0 has joined #ruby
aremaref has joined #ruby
pwnd_sfw has quit [Ping timeout: 240 seconds]
pwnd_sfw0 is now known as pwnd_sfw
aremaref has quit [Ping timeout: 240 seconds]
deadbee has quit [Quit: WeeChat 2.9]
carbone5 has joined #ruby
baojg has quit [Remote host closed the connection]
baojg has joined #ruby
AndyC has joined #ruby
AndyC has quit [Client Quit]
AndyC has joined #ruby
Swyper has quit [Remote host closed the connection]
<cloud69> adam12: https://i.imgur.com/N6Pi1ZV.png <3
vortex2wenty has joined #ruby
cuerbot has joined #ruby
<apotheon> cloud69: nice logo design
<cloud69> apotheon: thanks man
<cloud69> i've already had people copying it. like driftingruby.com
<apotheon> It's also nice that you linked directly to the image, instead of to an imgur page.
<cloud69> apotheon: yes sir!
elcuervo has quit [Ping timeout: 265 seconds]
<apotheon> Holy crap, Drifting Ruby's student price is a bit much.
<apotheon> I just got up, so . . . time to do morning stuff.
<apotheon> ta
<cloud69> :D
<cloud69> later man!
cloud69 has quit []
cloud69 has joined #ruby
cloud69 has quit [Client Quit]
TCZ has quit [Remote host closed the connection]
HighMemo` has joined #ruby
<HighMemo`> Any way to change my gem 'USER INSTALLATION DIRECTORY'? I already properly modified GEM_HOME.
<havenwood> HighMemo`: $GEM_HOME or --install-dir set the installation directory.
<havenwood> HighMemo`: --install-dir DIR
Swyper has joined #ruby
rorymckinley has quit [Quit: Leaving]
<havenwood> HighMemo`: See: gem install --help
orbyt_ has joined #ruby
<apotheon> Bummer -- cloud69 is gone.
drincruz_ has joined #ruby
TCZ has joined #ruby
blackmesa has joined #ruby
ChmEarl has joined #ruby
HighMemo` has quit [Remote host closed the connection]
drincruz_ has quit [Ping timeout: 240 seconds]
gix has joined #ruby
MarkPryor has joined #ruby
MarkPryor has quit [Read error: Connection reset by peer]
nowhere_man has joined #ruby
Technodrome has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
gix has quit [Quit: Client exiting]
Swyper has quit [Remote host closed the connection]
gix has joined #ruby
Rudd0 has quit [Ping timeout: 246 seconds]
Swyper has joined #ruby
carbone5 has quit [Quit: carbone5]
orbyt_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jmcgnh has quit [Ping timeout: 260 seconds]
carbone5 has joined #ruby
jmcgnh has joined #ruby
carbone5 has quit [Quit: carbone5]
deadbee has joined #ruby
deadbee has quit [Client Quit]
Technodrome has joined #ruby
deadbee has joined #ruby
pwnd_sfw has quit [Ping timeout: 240 seconds]
pwnd_sfw has joined #ruby
AndyC has quit [Ping timeout: 265 seconds]
drincruz_ has joined #ruby
deadbee has quit [Quit: WeeChat 2.9]
drincruz_ has quit [Ping timeout: 256 seconds]
TCZ has quit [Quit: Diabe? tkwi w szczegó?ach]
helpa has quit [Remote host closed the connection]
carbone5 has joined #ruby
helpa has joined #ruby
carbone5 has quit [Quit: carbone5]
AndyC has joined #ruby
TCZ has joined #ruby
TCZ has quit [Read error: Connection reset by peer]
nowhere_man has quit [Ping timeout: 272 seconds]
jmcgnh has quit [Ping timeout: 256 seconds]
weaksauce has joined #ruby
weaksauce has quit [Client Quit]
<rapha> anyone up for a round of golf? https://codegolf.stackexchange.com/q/216024/87347
weaksauce has joined #ruby
riceandbeans has quit [Quit: rebooting]
execat[m] has quit [Ping timeout: 240 seconds]
danielk43[m] has quit [Ping timeout: 244 seconds]
hsiktas[m] has quit [Ping timeout: 244 seconds]
r34lp0w3r[m] has quit [Ping timeout: 246 seconds]
MeVegan[m] has quit [Ping timeout: 246 seconds]
stan has quit [Ping timeout: 246 seconds]
leni1[m] has quit [Ping timeout: 246 seconds]
jo-so has quit [Ping timeout: 244 seconds]
Hanma[m] has quit [Ping timeout: 260 seconds]
linuus[m] has quit [Ping timeout: 272 seconds]
otagi[m] has quit [Ping timeout: 268 seconds]
turt2live has quit [Ping timeout: 244 seconds]
glimpse[m] has quit [Ping timeout: 268 seconds]
gypsy5[m] has quit [Ping timeout: 244 seconds]
<rapha> leah2: woah there!
<leah2> (not mine)
TCZ has joined #ruby
<rapha> nice thread tho
<leah2> yes
<leah2> i do it in J if you're interested in golfing
<leah2> but not golfing super hard, i'm still learning
orbyt_ has joined #ruby
TCZ is now known as toxic_worm
jmcgnh has joined #ruby
linuus[m] has joined #ruby
execat[m] has joined #ruby
hsiktas[m] has joined #ruby
jmcgnh has quit [Ping timeout: 246 seconds]
r34lp0w3r[m] has joined #ruby
jo-so has joined #ruby
MeVegan[m] has joined #ruby
gypsy5[m] has joined #ruby
Hanma[m] has joined #ruby
turt2live has joined #ruby
glimpse[m] has joined #ruby
AndyC has quit [Ping timeout: 272 seconds]
otagi[m] has joined #ruby
stan has joined #ruby
<rapha> interested in golfing every once in a while, yes (it was fun creating that challenge linked to above), but only in ruby. life's already too short as it is...
danielk43[m] has joined #ruby
jmcgnh has joined #ruby
jmcgnh has quit [Ping timeout: 246 seconds]
crankharder has quit [Ping timeout: 272 seconds]
Technodrome has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
crankharder has joined #ruby
crankharder has quit [Ping timeout: 272 seconds]
roshanavand has joined #ruby
crankharder has joined #ruby
crankharder has quit [Ping timeout: 246 seconds]
Rudd0 has joined #ruby
drincruz_ has joined #ruby
crankharder has joined #ruby
Swyper has quit [Remote host closed the connection]
Swyper has joined #ruby
Swyper has quit [Ping timeout: 260 seconds]
crankharder has quit [Ping timeout: 256 seconds]
toxic_worm has quit [Remote host closed the connection]
nowhere_man has joined #ruby
nowhere_man has quit [Client Quit]
roshanavand has quit [Quit: Quitting...]
crankharder has joined #ruby
jmcgnh has joined #ruby
fredolinhares has joined #ruby
crankharder has quit [Ping timeout: 272 seconds]
nowhere_man has joined #ruby
crankharder has joined #ruby
aremaref has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
AndyC has joined #ruby
crankharder has quit [Ping timeout: 272 seconds]
edwardly has quit [Quit: ??????????]
edwardly has joined #ruby
edwardly has joined #ruby
crankharder has joined #ruby
ruby[bot] has joined #ruby
crankharder has quit [Ping timeout: 264 seconds]
crankharder has joined #ruby
TCZ has joined #ruby
crankharder has quit [Ping timeout: 272 seconds]
crankharder has joined #ruby
aremaref has quit [Ping timeout: 272 seconds]
crankharder has quit [Ping timeout: 246 seconds]
BTRE has quit [Remote host closed the connection]
TCZ is now known as toxic_worm
crankharder has joined #ruby
drincruz_ has quit [Ping timeout: 256 seconds]
crankharder has quit [Ping timeout: 240 seconds]
jmcgnh has quit [Ping timeout: 256 seconds]
crankharder has joined #ruby
aremaref has joined #ruby
dfucci has joined #ruby
dfucci has left #ruby [#ruby]
crankharder has quit [Ping timeout: 256 seconds]