apeiros changed the topic of #ruby-lang to: Ruby 2.2.2; 2.1.6; 2.0.0-p645: https://ruby-lang.org || Paste code on https://gist.github.com
ledestin has joined #ruby-lang
|jemc| has quit [Ping timeout: 245 seconds]
nertzy has joined #ruby-lang
symm-_ is now known as symm-
hahuang65 has quit [Ping timeout: 248 seconds]
Lewix has joined #ruby-lang
<Lewix> seems like more businesses use more go than clojure
<Lewix> why is clojure losing ground?
<Lewix> (performance?)
<havenwood> Lewix: It's too nice.
<pipework> Is this the right place?
<pipework> havenwood: Because closures are hard on a VM that wasn't designed for that. :(
<Lewix> pipework: any experience with clojure?
<Lewix> havenwood: what's too nice?
<pipework> Minimal exploratory usage.
<Lewix> pipework: nope it's not ^^
<Lewix> pipework: if I remember correctly, you're playing with erlang these days aren't you
<pipework> Lewix: Well, I mean you might win points for asking a maybe unbiased group, but we're also less likely to be the most informed.
<pipework> Yeah. I've been thinking of also doing more elixir in this project too.
<havenwood> Lewix: It hasn't broken into the top 10, but Clojure has made it into the top 20 by Redmonk's rank: http://redmonk.com/sogrady/2015/01/14/language-rankings-1-15/
baweaver has quit [Remote host closed the connection]
<Lewix> havenwood: hehe\
baweaver has joined #ruby-lang
chouhoul_ has quit [Remote host closed the connection]
Lewix has quit [Changing host]
Lewix has joined #ruby-lang
SylarRuby has quit [Remote host closed the connection]
SylarRuby has joined #ruby-lang
SylarRuby has quit [Remote host closed the connection]
bruno-_ has quit [Ping timeout: 252 seconds]
havenwood has quit []
AlxAlt has quit [Ping timeout: 248 seconds]
fujimura has joined #ruby-lang
nertzy has quit [Quit: This computer has gone to sleep]
michael_mbp has quit [Excess Flood]
michael_mbp has joined #ruby-lang
cengizIO has quit [Quit: Textual IRC Client: www.textualapp.com]
fujimura has quit [Read error: No route to host]
fujimura has joined #ruby-lang
wallerdev has quit [Ping timeout: 252 seconds]
hendranata_ has joined #ruby-lang
lektrik has joined #ruby-lang
eban has joined #ruby-lang
tkuchiki has joined #ruby-lang
eban has quit [Client Quit]
eban has joined #ruby-lang
eban has quit [Client Quit]
slawrence00 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
purrkode has joined #ruby-lang
baweaver has quit [Remote host closed the connection]
baweaver has joined #ruby-lang
ascarter has joined #ruby-lang
baweaver has quit [Ping timeout: 264 seconds]
ascarter has quit [Max SendQ exceeded]
ascarter has joined #ruby-lang
workmad3 has joined #ruby-lang
workmad3 has quit [Ping timeout: 240 seconds]
hendranata_ has quit [Remote host closed the connection]
SylarRuby has joined #ruby-lang
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
joaomdmoura has joined #ruby-lang
ascarter has joined #ruby-lang
hendranata_ has joined #ruby-lang
charliesome has quit [Quit: zzz]
bungoman has joined #ruby-lang
SylarRuby has quit [Ping timeout: 250 seconds]
caseypatrickdris has joined #ruby-lang
caseypatrickdris is now known as caseydriscoll
purrkode has quit [Quit: Textual IRC Client: www.textualapp.com]
toretore has quit [Quit: This computer has gone to sleep]
tsou has joined #ruby-lang
Cloudzy has joined #ruby-lang
amclain has joined #ruby-lang
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ascarter has joined #ruby-lang
sankaber has joined #ruby-lang
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
hendranata_ has quit [Remote host closed the connection]
ascarter has joined #ruby-lang
hendranata_ has joined #ruby-lang
ascarter has quit [Client Quit]
crankharder has joined #ruby-lang
centrx has quit [Quit: Shutting down, Please wait...]
caseydriscoll has quit [Remote host closed the connection]
symm- has quit [Ping timeout: 250 seconds]
shinnya has quit [Ping timeout: 252 seconds]
symm- has joined #ruby-lang
caseydriscoll has joined #ruby-lang
charliesome has joined #ruby-lang
charliesome has quit [Client Quit]
joaomdmoura has quit [Remote host closed the connection]
caseydriscoll has quit [Ping timeout: 250 seconds]
hendranata_ has quit [Remote host closed the connection]
djbkd has quit [Quit: My people need me...]
hendranata_ has joined #ruby-lang
chouhoulis has joined #ruby-lang
bb010g has quit [Quit: Connection closed for inactivity]
havenwood has joined #ruby-lang
imperator has joined #ruby-lang
fujimura has quit [Remote host closed the connection]
gix has quit [Ping timeout: 245 seconds]
imperator has quit [Quit: Leaving]
gix has joined #ruby-lang
ascarter has joined #ruby-lang
ascarter has quit [Client Quit]
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
charliesome has joined #ruby-lang
workmad3 has joined #ruby-lang
workmad3 has quit [Ping timeout: 250 seconds]
joaomdmoura has joined #ruby-lang
yfeldblu_ has quit [Remote host closed the connection]
joaomdmoura has quit [Remote host closed the connection]
symm- has quit [Quit: Leaving...]
lektrik has quit [Ping timeout: 244 seconds]
joaomdmoura has joined #ruby-lang
yfeldblum has joined #ruby-lang
crankharder has quit [Quit: leaving]
crankharder has joined #ruby-lang
caseydriscoll has joined #ruby-lang
duderonomy has joined #ruby-lang
gix has quit [Ping timeout: 250 seconds]
gix has joined #ruby-lang
lytol has quit [Remote host closed the connection]
crankharder has quit [Ping timeout: 250 seconds]
charliesome has quit [Quit: zzz]
x44x45x41x4E has joined #ruby-lang
crankharder has joined #ruby-lang
crankharder has quit [Remote host closed the connection]
symm- has joined #ruby-lang
caseydriscoll has quit [Ping timeout: 264 seconds]
bungoman has quit [Remote host closed the connection]
bungoman has joined #ruby-lang
kwd has quit [Remote host closed the connection]
crankharder has joined #ruby-lang
happyp has joined #ruby-lang
<happyp> Are there any Ruby forums?
Asher has joined #ruby-lang
crankharder has quit [Quit: Lost terminal]
caseydriscoll has joined #ruby-lang
RobertBirnie has joined #ruby-lang
relix has joined #ruby-lang
robbyoconnor has joined #ruby-lang
crankharder has joined #ruby-lang
caseydriscoll has quit [Ping timeout: 245 seconds]
RobertBirnie has quit [Client Quit]
kerunaru has joined #ruby-lang
vulix has quit [Read error: Connection reset by peer]
vulix has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
revath has joined #ruby-lang
workmad3 has joined #ruby-lang
LMity has joined #ruby-lang
workmad3 has quit [Ping timeout: 246 seconds]
purrkode has joined #ruby-lang
purrkode has quit [Remote host closed the connection]
skade has joined #ruby-lang
arBmind has joined #ruby-lang
LMity has quit [Ping timeout: 252 seconds]
Contigi has quit [Quit: Leaving]
caseydriscoll has joined #ruby-lang
happyp has quit [Ping timeout: 246 seconds]
caseydriscoll has quit [Ping timeout: 244 seconds]
Lewix has quit [Remote host closed the connection]
lytol has joined #ruby-lang
AlxAlt has joined #ruby-lang
Contigi has joined #ruby-lang
bungoman has quit [Remote host closed the connection]
lytol has quit [Ping timeout: 264 seconds]
hendranata_ has quit [Read error: Connection reset by peer]
michaeldeol has joined #ruby-lang
hendranata_ has joined #ruby-lang
x44x45x41x4E has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
bb010g has joined #ruby-lang
Tungki has joined #ruby-lang
caseydriscoll has joined #ruby-lang
michaeldeol has quit [Quit: Textual IRC Client: www.textualapp.com]
revath has quit [Ping timeout: 265 seconds]
hahuang65 has joined #ruby-lang
hahuang61 has joined #ruby-lang
kerunaru has joined #ruby-lang
caseydriscoll has quit [Ping timeout: 250 seconds]
iamninja_ has quit [Read error: Connection reset by peer]
iamninja_ has joined #ruby-lang
revath has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
lytol has joined #ruby-lang
stan has joined #ruby-lang
SylarRuby has joined #ruby-lang
lytol has quit [Ping timeout: 245 seconds]
skade has joined #ruby-lang
amclain has quit [Quit: Leaving]
arBmind has quit [Quit: Leaving.]
vondruch has joined #ruby-lang
x44x45x41x4E has joined #ruby-lang
solars has joined #ruby-lang
nedp has joined #ruby-lang
workmad3 has joined #ruby-lang
arBmind has joined #ruby-lang
workmad3 has quit [Ping timeout: 245 seconds]
cornerma1 has joined #ruby-lang
x44x45x41x4E has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Miphix has quit [Quit: Leaving]
cornerman has quit [Ping timeout: 256 seconds]
cornerma1 is now known as cornerman
x44x45x41x4E has joined #ruby-lang
yfeldblum has quit [Remote host closed the connection]
fusillicode1 has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
fusillicode has quit [Ping timeout: 250 seconds]
caseydriscoll has joined #ruby-lang
skade has joined #ruby-lang
ta_ has joined #ruby-lang
solars has quit [Ping timeout: 265 seconds]
Cloudhand has joined #ruby-lang
ujji77 has joined #ruby-lang
Cloudzy has quit [Ping timeout: 240 seconds]
<ujji77> how to print the number of times a method? method should itslef print the count
<ujji77> how to print the number of times a method called? method should itslef print the count
<ujji77> Anyone out there?
ta_ has quit [Ping timeout: 256 seconds]
ujji77 has quit [Quit: Page closed]
<apeiros> patience was not strong in this one…
<ljarvis> heh
<tbuehlmann> tried to find an isitfridayyet webpage some minutes ago. the first one said NO, the second one wanted to use flash, the third one finally said YUP. now, the first one says YUP and wants to show some flash
<apeiros> tbuehlmann: just install the isitfridayyet gem
marr has joined #ruby-lang
<apeiros> hah, there actually is a "friday" gem, description: "Everybody's lookin' forward to the weekend."
ascarter has joined #ruby-lang
solars has joined #ruby-lang
nedp has quit [Ping timeout: 250 seconds]
skade has quit [Quit: Computer has gone to sleep.]
Guest20 has joined #ruby-lang
dhjondoh has joined #ruby-lang
havenwood has quit [Remote host closed the connection]
skade has joined #ruby-lang
caseydriscoll has quit [Ping timeout: 256 seconds]
dzejrou has joined #ruby-lang
chinmay_dd has quit [Remote host closed the connection]
elia has joined #ruby-lang
OnBrokenWings has joined #ruby-lang
nedp has joined #ruby-lang
k3asd` has joined #ruby-lang
hendranata_ has quit [Ping timeout: 276 seconds]
kwd has joined #ruby-lang
vondruch has quit [Ping timeout: 255 seconds]
benlovell has joined #ruby-lang
bruno- has joined #ruby-lang
SylarRuby has quit [Remote host closed the connection]
bruno- is now known as Guest80027
riotjones has quit [Ping timeout: 244 seconds]
fusillicode has joined #ruby-lang
Voker57 has quit [Ping timeout: 276 seconds]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Voker57 has joined #ruby-lang
fusillicode1 has quit [Ping timeout: 256 seconds]
<yorickpeterse> morning kids
riotjones has joined #ruby-lang
relix has joined #ruby-lang
lytol has joined #ruby-lang
intinig has joined #ruby-lang
michael_mbp has quit [Excess Flood]
skade has quit [Quit: Computer has gone to sleep.]
Guest80027 has quit [Ping timeout: 245 seconds]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
lytol has quit [Ping timeout: 255 seconds]
michael_mbp has joined #ruby-lang
fusillicode1 has joined #ruby-lang
fusillicode has quit [Ping timeout: 272 seconds]
intinig has quit [Ping timeout: 244 seconds]
yfeldblum has joined #ruby-lang
x44x45x41x4E has quit [Quit: Textual IRC Client: www.textualapp.com]
fusillicode1 has quit [Ping timeout: 252 seconds]
intinig has joined #ruby-lang
fusillicode has joined #ruby-lang
fusillicode1 has joined #ruby-lang
michael_mbp has quit [Excess Flood]
michael_mbp has joined #ruby-lang
benlovell has quit [Ping timeout: 276 seconds]
yfeldblum has quit [Read error: Connection reset by peer]
fusillicode has quit [Ping timeout: 250 seconds]
yfeldblum has joined #ruby-lang
caseydriscoll has joined #ruby-lang
benlovell has joined #ruby-lang
workmad3 has joined #ruby-lang
workmad3 has quit [Ping timeout: 256 seconds]
kerunaru has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<maloik> If you have an FQDN, what would be an easy way to map it into an array starting with the exact FQDN, and then each time removing the left-most part of the FQDN?
<maloik> as in, turn "foo.bar.baz.com" into %w(foo.bar.baz.com bar.baz.com baz.com)
<maloik> I'm blanking out... I blame friday
<apeiros> maloik: FQDN has a dot at the end
<maloik> yea it does but you get the point
<maloik> :-)
<apeiros> it changes the code
kerunaru has joined #ruby-lang
<apeiros> so do you have an FQDN or just a domain name?
<maloik> make it url's, easier to handle
<maloik> I'll deal with the dot if it becomes a problem
<apeiros> urls are an entirely different beast again :-p
<maloik> for some reason I thought there was a method on array that would do what I need but I can't find it... I guess I'm just imagining it
<maloik> zzz :P domain names then! I just wanted to save keystrokes :D
<ljarvis> items.map.with_index { |_, i| items[i..-1].join(".") }
Cloudhand has quit [Ping timeout: 244 seconds]
<ljarvis> probably better but its early
<ljarvis> better ways*
<apeiros> I'd probably split, iterate ary.size times and push/pop on each iteration
<apeiros> ljarvis method looks nicer than what I thought of
<maloik> yea doesn't look bad at all, let me give that a go
toretore has joined #ruby-lang
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
relix has joined #ruby-lang
caseydriscoll has quit [Ping timeout: 246 seconds]
stardiviner has quit [Quit: Weird in coding now, or make love, only two things push me away from IRC.]
bb010g has quit [Quit: Connection closed for inactivity]
<ljarvis> hmmmmmm
<ljarvis> i am tired
<maloik> makes two of us
iamninja_ has quit [Read error: Connection reset by peer]
<maloik> yay, the fry shop received our order
<maloik> nomnomnom
<maloik> the wait begins
<ljarvis> fry as in fried food?
iamninja_ has joined #ruby-lang
<maloik> belgian fries
<maloik> (fuck the french! :D)
<ljarvis> are they different from french fries?
<RickHull> are they delivering?
<maloik> nah, but they're pretty much nextdoor
<RickHull> good, because fried stuff delivered usually sucks
<ljarvis> thought that was a geographical answer then
<maloik> we built an app that takes our orders, sends them an email, the click a link to confirm they received it, and click another when the order is ready to be picked up
<maloik> we're pretty lazy if I do say so myself
<maloik> lazy and proud!
<RickHull> are you the only users?
<maloik> yea
<RickHull> lol
<ljarvis> that reminds me of a website I found that delivers pizza by drones. I found a hack where you could add/remove/edit drone orders directly
<maloik> hahahaha
<maloik> as in hijack them basically?
<ljarvis> yeah, send the pizzas anywhere
<RickHull> I prefer the term, redirect
<RickHull> 301 injection, if you must
<ljarvis> it was based in new york, i think entering a uk address may have been prohibitive
<maloik> you could steal a drone and they'd probably suspect the person it was delivering to in the first place
<ljarvis> and at the very best the pizza would be very very cold, and potentially wet
<maloik> although I suppose the pesky things have gps nowadays... sigh technology
<maloik> hah :-)
joaomdmoura has quit [Remote host closed the connection]
<RickHull> i guess there's a pretty major distinction between autonomous drones, and puppets with radio strings
<maloik> It's a shame drones are still so expensive, I'd love one to play around with using my gopro
<maloik> or one to do the whole POV racing thing, that looks pretty cool too
<maloik> hmm maybe I should sell my DSLR and buy a drone instead... go from one thing I never use to another
<ljarvis> hah
<RickHull> i thought you could get quadcopters for well under $100
<maloik> but shitty ones then I suppose?
<RickHull> and then it's just a SMOP
<ljarvis> paper ones maybe
<maloik> what's SMOP
<RickHull> small matter of programming ;)
<maloik> the gopro gimbal drones are always 1k or more
<ljarvis> small matter of pooping
<ljarvis> brb
<maloik> :D
<RickHull> large matter goes plop
<maloik> more like big matter IYKWIM hurr durr
tkuchiki_ has joined #ruby-lang
tkuchiki has quit [Ping timeout: 264 seconds]
tkuchiki has joined #ruby-lang
howdoicomputer has joined #ruby-lang
Miphix has joined #ruby-lang
tkuchiki_ has quit [Ping timeout: 245 seconds]
revath has quit [Ping timeout: 244 seconds]
dzejrou has quit [Ping timeout: 245 seconds]
shinnya has joined #ruby-lang
postmodern has quit [Quit: Leaving]
revath has joined #ruby-lang
zenspider has quit [Ping timeout: 240 seconds]
OnBrokenWings has quit [Ping timeout: 272 seconds]
OnBrokenWings has joined #ruby-lang
jds has joined #ruby-lang
Guest20 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<yorickpeterse> update some_table_with_a_few_million_rows set column = lower(column); # alas poor PostgreSQL, I knew it well
<yorickpeterse> also surprised how well Oga works when importing a few GB of XML into a DB
<yorickpeterse> pretty fast too on at least JRuby
<yorickpeterse> (about 100k DB rows imported per minute @ 5 threads (1 thread per file to import))
zenspider has joined #ruby-lang
Guest20 has joined #ruby-lang
arBmind has quit [Quit: Leaving.]
<bougyman> you doing that with inserts?
<yorickpeterse> 1000 rows per transaction
<bougyman> I was gonna suggest COPY, if you haven't tried it.
<bougyman> orderes of magnitude faster, for data loads in PG.
caseydriscoll has joined #ruby-lang
<yorickpeterse> The data doesn't come from something like STDIN though
arBmind has joined #ruby-lang
<yorickpeterse> basically the process is: parse XML files -> create a single row with some extra pre-processing -> stuff in an array -> run 1 transaction per 1000 rows
revath has quit [Ping timeout: 246 seconds]
tkuchiki_ has joined #ruby-lang
<yorickpeterse> (I'm aware this script never terminates)
lytol has joined #ruby-lang
tkuchiki has quit [Ping timeout: 245 seconds]
<darix> yorickpeterse: my "kill -9" says differently!
lytol has quit [Ping timeout: 256 seconds]
<yorickpeterse> well yeah
<yorickpeterse> kill -9 no more cpu time
revath has joined #ruby-lang
tkuchiki_ has quit [Remote host closed the connection]
workmad3 has joined #ruby-lang
caseydriscoll has quit [Ping timeout: 244 seconds]
workmad3 has quit [Ping timeout: 244 seconds]
mikecmpbll has joined #ruby-lang
Devoth has joined #ruby-lang
thelastinuit has joined #ruby-lang
Guest20 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Eising> *sigh*
<Eising> our internal templating system we use for the generation of configuration, is embedded vbscript
<Eising> I'm throwing up in my mouth a little every time I do something there
<rob_> ...!
<Eising> vbscript with .net bindings or however that stuff works, it's really bad
Guest20 has joined #ruby-lang
<rob_> you're a braver person than i
<Eising> It would have been bravery if I had a choice
<Eising> it's more like slavery, and that even rhymes
<Eising> It's actually like ERB, where <% %> has vbscript instead of ruby
* womble is imagining a giant Access database containing all sorts of rows for different configuration items, that then writes out configuration files to reports that you need to manually cut-and-paste to the machines.
<Eising> womble: you're not far off
<womble> I hate being right.
k3asd` has quit [Ping timeout: 255 seconds]
benlovell has quit [Ping timeout: 256 seconds]
Forgetful_Lion has joined #ruby-lang
LMity has joined #ruby-lang
fusillicode1 has quit [Quit: Leaving.]
fusillicode has joined #ruby-lang
symm- has quit [Ping timeout: 248 seconds]
chinmay_dd has joined #ruby-lang
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
LMity has quit [Ping timeout: 256 seconds]
caseydriscoll has joined #ruby-lang
piotrj has joined #ruby-lang
yfeldblum has quit [Ping timeout: 245 seconds]
piotrj has quit [Remote host closed the connection]
shinnya has quit [Ping timeout: 256 seconds]
ldnunes has joined #ruby-lang
piotrj has joined #ruby-lang
djellemah has quit [Quit: Leaving]
caseydriscoll has quit [Ping timeout: 256 seconds]
piotrj has quit [Remote host closed the connection]
banister has joined #ruby-lang
mkosaki has quit [Ping timeout: 245 seconds]
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
djellemah has joined #ruby-lang
tomaz_b has joined #ruby-lang
tomaz_b has quit [Client Quit]
tomaz_b has joined #ruby-lang
jsaak has joined #ruby-lang
yalue has joined #ruby-lang
iamninja_ has quit [Read error: Connection reset by peer]
iamninja_ has joined #ruby-lang
lytol has joined #ruby-lang
banister has joined #ruby-lang
ledestin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<headius> yorickpeterse: Oga working out pretty well for you?
<yorickpeterse> So far yes
Lewix has joined #ruby-lang
lytol has quit [Ping timeout: 245 seconds]
vondruch has joined #ruby-lang
benlovell has joined #ruby-lang
benlovell has quit [Ping timeout: 240 seconds]
Forgetful_Lion has quit [Remote host closed the connection]
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
vondruch has quit [Ping timeout: 246 seconds]
workmad3 has joined #ruby-lang
ryba has joined #ruby-lang
chouhoulis has quit [Remote host closed the connection]
ryba is now known as simi
Tungki has quit [Read error: Connection reset by peer]
banister has joined #ruby-lang
workmad3 has quit [Ping timeout: 244 seconds]
banister has quit [Max SendQ exceeded]
stef204 has joined #ruby-lang
caseydriscoll has joined #ruby-lang
skade has joined #ruby-lang
piotrj has joined #ruby-lang
k3asd` has joined #ruby-lang
benlovell has joined #ruby-lang
vondruch has joined #ruby-lang
malconis has joined #ruby-lang
victortyau has joined #ruby-lang
kerunaru has quit [Quit: Textual IRC Client: www.textualapp.com]
caseydriscoll has quit [Remote host closed the connection]
sgambino has joined #ruby-lang
crankhar1er has joined #ruby-lang
OnBrokenWings has quit [Quit: Leaving]
benlovell has quit [Ping timeout: 272 seconds]
piotrj has quit [Remote host closed the connection]
b_hoffman has joined #ruby-lang
piotrj has joined #ruby-lang
sankaber has joined #ruby-lang
b_hoffman has quit [Read error: Connection reset by peer]
b_hoffman has joined #ruby-lang
malconis has quit [Remote host closed the connection]
malconis has joined #ruby-lang
vondruch has quit [Quit: Ex-Chat]
allomov has joined #ruby-lang
revath has quit [Ping timeout: 245 seconds]
kstuart has quit [Quit: WeeChat 1.1.1]
shazaum has joined #ruby-lang
piotrj has quit [Remote host closed the connection]
funnel has quit [Ping timeout: 252 seconds]
piotrj has joined #ruby-lang
agarie has joined #ruby-lang
caseydriscoll has joined #ruby-lang
revath has joined #ruby-lang
piotrj has quit [Ping timeout: 244 seconds]
joaomdmoura has joined #ruby-lang
dhjondoh has quit [Remote host closed the connection]
houhoulis has joined #ruby-lang
piotrj has joined #ruby-lang
piotrj has quit [Remote host closed the connection]
piotrj has joined #ruby-lang
howdoicomputer has quit [Quit: howdoicomputer]
funnel has joined #ruby-lang
chouhoulis has joined #ruby-lang
crankhar1er has quit [Quit: leaving]
crankhar1er has joined #ruby-lang
crankharder has quit [Disconnected by services]
alestuber has joined #ruby-lang
crankhar1er has quit [Client Quit]
crankharder has joined #ruby-lang
bungoman has joined #ruby-lang
dzejrou has joined #ruby-lang
chouhoulis has quit [Ping timeout: 248 seconds]
caseydriscoll has quit [Remote host closed the connection]
nedp has quit [Ping timeout: 244 seconds]
lytol has joined #ruby-lang
lytol has quit [Ping timeout: 256 seconds]
benlovell has joined #ruby-lang
whippythellama has joined #ruby-lang
shazaum has quit [Quit: Leaving]
shinnya has joined #ruby-lang
malconis has quit [Read error: Connection reset by peer]
workmad3 has joined #ruby-lang
malconis has joined #ruby-lang
riotjones has quit [Remote host closed the connection]
tomaz_b has quit [Quit: Leaving]
workmad3 has quit [Ping timeout: 264 seconds]
shinnya has quit [Ping timeout: 276 seconds]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
benlovell has quit [Ping timeout: 256 seconds]
benlovell has joined #ruby-lang
dm78_ has quit []
piotrj has quit [Remote host closed the connection]
relix has joined #ruby-lang
enebo has joined #ruby-lang
chouhoulis has joined #ruby-lang
banister has joined #ruby-lang
chouhoulis has quit [Remote host closed the connection]
chouhoulis has joined #ruby-lang
alestuber has quit [Remote host closed the connection]
simi has quit [Ping timeout: 245 seconds]
alestuber has joined #ruby-lang
bb010g has joined #ruby-lang
revath has quit [Ping timeout: 264 seconds]
ascarter has joined #ruby-lang
|jemc| has joined #ruby-lang
ascarter has quit [Client Quit]
ascarter has joined #ruby-lang
slawrence00 has joined #ruby-lang
setanta_ has joined #ruby-lang
alestuber has quit [Ping timeout: 256 seconds]
momomomomo has joined #ruby-lang
alestuber has joined #ruby-lang
skade has quit [Quit: Computer has gone to sleep.]
slawrence00 has quit [Quit: Textual IRC Client: www.textualapp.com]
slawrence00 has joined #ruby-lang
alestuber has quit [Read error: Connection reset by peer]
slawrence00 has quit [Client Quit]
alestuber has joined #ruby-lang
havenwood has joined #ruby-lang
alestuber has quit [Ping timeout: 252 seconds]
slawrence00 has joined #ruby-lang
alestuber has joined #ruby-lang
chadwtaylor has joined #ruby-lang
Lewix has quit [Remote host closed the connection]
riotjones has joined #ruby-lang
SylarRuby has joined #ruby-lang
Iskarlar has joined #ruby-lang
benlovell has quit [Ping timeout: 248 seconds]
riotjones has quit [Ping timeout: 264 seconds]
Lewix has joined #ruby-lang
momomomomo has quit [Quit: momomomomo]
<crankharder> is "return @a if @a" practically different than "return @a if defined?(@a)" ?
<crankharder> scratch that, nvm
agarie has quit [Remote host closed the connection]
guillaume-rb has joined #ruby-lang
houhoulis has quit [Remote host closed the connection]
rcvalle has joined #ruby-lang
toretore has quit [Quit: Leaving]
michael_mbp has quit [Excess Flood]
lytol has joined #ruby-lang
michael_mbp has joined #ruby-lang
Guest20 has quit [Quit: Textual IRC Client: www.textualapp.com]
thelastinuit has quit [Quit: Textual IRC Client: www.textualapp.com]
jgpawletko has joined #ruby-lang
momomomomo has joined #ruby-lang
alestuber has quit [Ping timeout: 248 seconds]
__butch__ has joined #ruby-lang
lytol has quit [Ping timeout: 256 seconds]
jgpawletko has quit [Client Quit]
momomomomo has quit [Ping timeout: 245 seconds]
skade has joined #ruby-lang
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jgpawletko has joined #ruby-lang
SylarRuby has quit [Remote host closed the connection]
ascarter has joined #ruby-lang
ascarter has quit [Max SendQ exceeded]
ascarter has joined #ruby-lang
ascarter has quit [Client Quit]
ascarter has joined #ruby-lang
allomov has quit [Remote host closed the connection]
momomomomo has joined #ruby-lang
allomov has joined #ruby-lang
allomov has quit [Remote host closed the connection]
momomomomo has quit [Client Quit]
Cloudhand has joined #ruby-lang
faces has quit [Ping timeout: 276 seconds]
lytol has joined #ruby-lang
workmad3 has joined #ruby-lang
faces has joined #ruby-lang
yalue has quit [Read error: Connection reset by peer]
malconis has quit [Ping timeout: 250 seconds]
stan has quit [Ping timeout: 265 seconds]
momomomomo has joined #ruby-lang
guillaume-rb has quit [Quit: guillaume-rb]
malconis has joined #ruby-lang
mikecmpbll has quit [Ping timeout: 256 seconds]
workmad3 has quit [Ping timeout: 240 seconds]
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ascarter has joined #ruby-lang
ascarter has quit [Max SendQ exceeded]
unreal_ has quit [Ping timeout: 245 seconds]
ascarter has joined #ruby-lang
ascarter has quit [Max SendQ exceeded]
ascarter has joined #ruby-lang
ascarter has quit [Client Quit]
simi has joined #ruby-lang
DCameronMauch has joined #ruby-lang
ItSANg___ has joined #ruby-lang
ItSANgo__ has quit [Read error: Connection reset by peer]
<DCameronMauch> got a question
<DCameronMauch> if I define a base class, that has a module inside
chinmay_dd has quit [Quit: Leaving]
<DCameronMauch> and a class method that dynamically creates a class with Class.new, which includes that module
<DCameronMauch> everything works fine
<DCameronMauch> but when I extend that class, it is still trying to include the super class's module, not the current class
sankaber has quit [Read error: Connection reset by peer]
<DCameronMauch> shouldn't the include look at whatever my current class is?
sankaber has joined #ruby-lang
<havenwood> DCameronMauch: Gist the code?
agarie has joined #ruby-lang
ascarter has joined #ruby-lang
<DCameronMauch> just updated - had some test stuff there
RobertBirnie has joined #ruby-lang
joaomdmoura has quit [Remote host closed the connection]
<DCameronMauch> so now, when I call ReviewStateMachine.customize(:whatever), it raises an exception
ascarter has quit [Max SendQ exceeded]
<DCameronMauch> if I remove the Setup module from the BaseStateMachine, then the include fails complaining that it can't find BaseStateMachine::Setup
ascarter has joined #ruby-lang
momomomomo has quit [Quit: momomomomo]
<DCameronMauch> shouldn't it be looking for ReviewStateMachine::Setup?
momomomomo has joined #ruby-lang
lian is now known as lianj
Mon_Ouie has quit [Ping timeout: 245 seconds]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
relix has joined #ruby-lang
RobertBirnie has quit [Quit: Textual IRC Client: www.textualapp.com]
<DCameronMauch> still there?
<havenwood> DCameronMauch: Confusing structure. Doing your includes in an anonymous Class strikes me as odd. Are you familiar with `class << self` or can you explain your `Class.new do` thinking?
<DCameronMauch> I will need to further include different modules, based on the user
intinig has quit [Remote host closed the connection]
workmad3 has joined #ruby-lang
<DCameronMauch> since I can't have any of the class definition code run until after the user dependent stuff is included, I didn't know of any other way, other than to dynamically create a new clas
intinig has joined #ruby-lang
lytol has quit [Remote host closed the connection]
lytol has joined #ruby-lang
alestuber has joined #ruby-lang
mikecmpbll has joined #ruby-lang
<havenwood> DCameronMauch: Here's an article that's a bit dated but still relevant: http://yehudakatz.com/2009/11/15/metaprogramming-in-ruby-its-all-about-the-self/
intinig has quit [Ping timeout: 240 seconds]
crankhar1er has joined #ruby-lang
crankharder has quit [Read error: Connection reset by peer]
alestuber has quit [Ping timeout: 250 seconds]
alestuber has joined #ruby-lang
<DCameronMauch> Some good stuff in there, but I don't think it will help with my use case.
fusillicode has quit [Ping timeout: 264 seconds]
<DCameronMauch> See, if I add/modify stuff in the global class, based on a user, then I pollute that global class for the next user
<havenwood> DCameronMauch: Ah, so you want to include on an instance by instance basis?
<DCameronMauch> yep, that's the problem
<DCameronMauch> so it seemed like the Create.new anonymous class generator does that part nicely
bb010g has quit [Quit: Connection closed for inactivity]
<|jemc|> DCameronMauch: see Object#extend for an instance-only version of Module#include
alestuber has quit [Ping timeout: 255 seconds]
elia has quit [Quit: Computer has gone to sleep.]
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<DCameronMauch> I had thought about that
<DCameronMauch> but how do I get the extend, but I have a chick/egg problem
<DCameronMauch> eh
<havenwood> DCameronMauch: after instantiating your class
<DCameronMauch> but then it's too late
<DCameronMauch> the class definition code has already run
revath has joined #ruby-lang
<havenwood> DCameronMauch: So you need the include at the time it's instantiated?
Devoth has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<DCameronMauch> from the GIST, I need the states_map to have the right value BEFORE it is used
<havenwood> DCameronMauch: Pass the Modules you want included as arguments when you instantiate?
<DCameronMauch> by instantiate, you mean call .new on it?
tsipanov has joined #ruby-lang
<havenwood> DCameronMauch: I dunno, so convoluted I just scanned the gist. Looking closer.
alestuber has joined #ruby-lang
<havenwood> Multitasking here.
<havenwood> DCameronMauch: yeah, call new
<DCameronMauch> by the time I get to the .new, it's too late
<havenwood> DCameronMauch: What happens before new is called?
<DCameronMauch> a bunch of class level methods are called as part of the definition
<DCameronMauch> I need the new methods injected before that happens
<DCameronMauch> line 32
tsipanov has quit [Client Quit]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Iskarlar has joined #ruby-lang
<DCameronMauch> reload gist to see comment I added on line 30
<havenwood> Maybe I just need more coffee, but you're customizing an instance before instantiating it? Let me get coffee and look at this closer before I make any more comments.
<DCameronMauch> these are all class level methods, not instance methods
<havenwood> DCameronMauch: So you're changing the state of the whole class back and forth between instantiating? I don't get it.
<DCameronMauch> yeah, the gem I am using is based on class methods
<DCameronMauch> for the configuration
wallerdev has joined #ruby-lang
<DCameronMauch> and I need to configure it differently for each user request, based on that user
<DCameronMauch> without polluting a global class for every user
<DCameronMauch> I literally need a new class defined per request
<DCameronMauch> which this does
<DCameronMauch> my only issue, is why the include Setup on line 29, looks for BaseStateMachine::Setup when I call ReviewStateMachine.customize(:whatever)
agarie has quit [Remote host closed the connection]
arBmind has quit [Quit: Leaving.]
momomomomo has quit [Quit: momomomomo]
<DCameronMauch> it would expect it to look for ReviewStateMachine::Setup
bb010g has joined #ruby-lang
alestuber has quit [Ping timeout: 265 seconds]
ascarter has joined #ruby-lang
ascarter has quit [Client Quit]
alestuber has joined #ruby-lang
alestuber has quit [Remote host closed the connection]
alestuber has joined #ruby-lang
workmad3 has quit [Ping timeout: 256 seconds]
ascarter has joined #ruby-lang
ruby-lang124 has joined #ruby-lang
ascarter has quit [Max SendQ exceeded]
ascarter has joined #ruby-lang
ruby-lang124 has quit [Ping timeout: 246 seconds]
<headius> yorickpeterse: got a moment to look into that autoload thing?
hahuang65 has quit [Ping timeout: 240 seconds]
<headius> a bug in jruby is one possible explanation, but there's many others
revath has quit [Ping timeout: 264 seconds]
agarie has joined #ruby-lang
sarkyniin has joined #ruby-lang
fusillicode has joined #ruby-lang
nertzy has joined #ruby-lang
<DCameronMauch> Another way to look at the question is: if I do "include Foo", where does it look for Foo?
Lewix has quit [Remote host closed the connection]
<DCameronMauch> namespace wise
<yxhuvud> current namespace, and then upwards in the hierarchy towards the global.
<yxhuvud> you can force global by doing include ::Foo
revath has joined #ruby-lang
<DCameronMauch> so if a class inherits from another class, shouldn't the current namespace be the child class?
<DCameronMauch> not the superclass?
piotrj has joined #ruby-lang
<yxhuvud> if the method is defined in the superclass, it will start to look there.
<yxhuvud> you can get around that by doing self.class::Foo
Iskarlar has quit [Read error: Connection reset by peer]
Iskarlar has joined #ruby-lang
bungoman has quit [Remote host closed the connection]
<DCameronMauch> hmm. maybe onto something here
<DCameronMauch> but self is the class, not an instance, so self.class is "Class"
<DCameronMauch> no matter what the actually class name
revath has quit [Ping timeout: 245 seconds]
LMity has joined #ruby-lang
<DCameronMauch> is there a class method that gives the class name?
<yxhuvud> >> Time.name
<eval-in> yxhuvud => "Time" (https://eval.in/318407)
<yxhuvud> anonymous classes won't have a name unless assigned to a constant though.
<havenwood> >> Class.new.name
<eval-in> havenwood => nil (https://eval.in/318408)
<yxhuvud> >> x = Class.new; Bacon = x; x.name
<eval-in> yxhuvud => "Bacon" (https://eval.in/318409)
sankaber has joined #ruby-lang
<yxhuvud> learned that while playing around with anonymous activerecord classes that was in several different databases. turns out the rails connection pool looks up connection by class name...
alestuber has quit [Ping timeout: 246 seconds]
<DCameronMauch> I got the class from outside the Class.new, and used that inside
<DCameronMauch> and this works
<DCameronMauch> thanks!
shinnya has joined #ruby-lang
revath has joined #ruby-lang
<DCameronMauch> couldn't use self inside, because I am not in an anonymous class, and the name = ''
<DCameronMauch> oops, remove the "not" from previous sentence
<yorickpeterse> headius: Yeah just got home, looking into setting up a repro this evening
<yorickpeterse> It could be a mix of autoload + defined? as well, hadn't thought of that
DCameronMauch has quit [Quit: Leaving...]
<yorickpeterse> I wish people would just stop using autoload :/
alestuber has joined #ruby-lang
LMity has quit [Ping timeout: 265 seconds]
<havenwood> is autoload still on the chopping block for Ruby 3?
allomov has joined #ruby-lang
<headius> yorickpeterse: that's a possibility in other cases, but this one might actually be autoload bug
<headius> I'm trying to come up with a case that brutalizes autoload threading
<headius> there is a little use of defined? in aws-sdk but not much
<|jemc|> yorickpeterse: headius: maybe https://github.com/rubinius/rubinius/issues/2934#issuecomment-76595837 would be helpful in working on a repro
<|jemc|> I'm curious of robin850's repro fails on jruby as well
<|jemc|> s/of/if/
<headius> |jemc|: does not appear to
<headius> |jemc|: I'm not sure I see how this could fail
<headius> it seems to do everything in serial so there's no chance of concurrent autoload
<yorickpeterse> headius: already half way
<|jemc|> headius - I haven't run it on rbx myself or looked at it in depth and don't have time to at the moment, just mentioning it in case it helped
<headius> |jemc|: ok thanks...I don't think that script reproduces anything related to autoload, or I'm missing something
hahuang65 has joined #ruby-lang
<headius> yorickpeterse: I'm kinda just going on rough theory for my repro since it's not clear how to trigger this
b_hoffman has quit [Quit: b_hoffman]
allomov has quit [Remote host closed the connection]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<yorickpeterse> hmpf, my own script ofc doesn't trigger it
nertzy has quit [Quit: This computer has gone to sleep]
allomov_ has joined #ruby-lang
Voker57 has quit [Read error: Connection reset by peer]
relix has joined #ruby-lang
piotrj has quit [Remote host closed the connection]
agarie has quit [Remote host closed the connection]
<headius> yorickpeterse: here's mine: https://gist.github.com/headius/f22ac44bc23bd221e100
<headius> doesn't trigger anything on JRuby though
<headius> that's 100 threads trying to access an autoload constant more or less at the same time
<headius> this system is 4(+4) cores so it should have a little parallelism
piotrj has joined #ruby-lang
dzejrou has quit [Ping timeout: 252 seconds]
<yorickpeterse> There are a few jruby apps we've been running where we've also been seeing these problems with v1 of the SDK
<yorickpeterse> Which too autoloaded the shit out of things
<headius> well presence of autoload and presence of this error may be a coincidence
<yorickpeterse> both jruby and rbx run it fine :/
<yorickpeterse> headius: doubt it
<yorickpeterse> For v2 I can make it go away by pre-loading all constants in the Aws/AWS namespace
<yorickpeterse> err for v1 as wel
ecnalyr has joined #ruby-lang
<yorickpeterse> * well
<headius> that could also indicate problems with load order
<headius> autoload can cause files to load in peculiar order...very easily could produce accesses before initialization
ecnalyr_ has joined #ruby-lang
<headius> e.g. that Base class triggers autoload of code that also tries to access Base before it is defined
alestuber has quit [Ping timeout: 250 seconds]
ecnalyr has quit [Client Quit]
<headius> late loading of code in ANY way is inherently unsafe in Ruby, regardless of whether autoload works right or not
<yorickpeterse> well yeah, it's one of the reasons I really dislike autoload
<yorickpeterse> or any runtime code loading for that matter
<headius> indeed
<headius> I feel like my case should have triggered an issue if autoload itself is the problem
<headius> yorickpeterse: we could instrument JRuby to watch when constants are being defined, if you have a way to reproduce it with the sdk
Mon_Ouie has joined #ruby-lang
<headius> if you can reproduce it with jruby flag -Xdebug.loadService.timing=true you'll get a hierarchy of the loads happening
<headius> that may show something useful
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<yorickpeterse> https://gist.github.com/robin850/3eeaed2538f50a9887c2 hm, this reproduces on rbx at least
<yorickpeterse> although I had to change the autoload path for :B to "./b"
<yorickpeterse> although that script passes on jruby
<ecnalyr_> I'm having a hard time simplifying a method, anyone wanna have a look at it? I put notes in the gist: https://gist.github.com/ecnalyr/35d8d74352206c46c3b8 -- Basically it seems wasteful to create a hash that only ever references the first possible value, but I can't come up with a simpler way of doing it.
<yorickpeterse> I'll whip together an SDK script, lets see if that works
alestuber has joined #ruby-lang
baweaver has joined #ruby-lang
<headius> yorickpeterse: how does that script fail?
<headius> I still don't see how it would do a concurrent autoload
agarie has joined #ruby-lang
<headius> the autoload of b is useless because it's overwritten immediately, and the autoload of c only happens in one thread while main thread is paused
<headius> what does it do on rbx?
allomov_ has quit [Remote host closed the connection]
<headius> oh, I do have an install still
charliesome has joined #ruby-lang
<headius> ConstMissing, I'm surprised...I don't see how that would happen
allomov has joined #ruby-lang
relix has joined #ruby-lang
<apeiros> hey headius - is it just me or are you hanging out more on irc than before? :)
<headius> i'm active in here a bit more, but otherwise my activity always waxes and wanes
<headius> I haven't been traveling, so that helps :-)
<apeiros> well, good for us - but I hope you get as much traveling as you wish for ;-)
micmus has joined #ruby-lang
nertzy has joined #ruby-lang
elev has joined #ruby-lang
djbkd has joined #ruby-lang
<elev> what does < and > means?
<havenwood> elev: depends on the context
<elev> my_age = 35
<elev> if my_age <= 40 puts "You are to young!"
<elev> end
<elev> or is it the other way?
<apeiros> <= is a method, and assuming my_age is an integer, it means "less or equal than"
<havenwood> elev: That's a method on Fixnum. You can see it here in the docs: http://ruby-doc.org/core-2.2.0/Fixnum.html#method-i-3C-3D
<elev> thanks
<elev> are you guys working with irc?
<havenwood> elev: in what sense?
<elev> you get money for helping me?
<apeiros> no
<havenwood> elev: no
<apeiros> all people in here voluntarily provide help
bungoman has joined #ruby-lang
<elev> nice
<elev> thanks :)
piotrj has quit [Remote host closed the connection]
<elev> you guys work wth ruby?
<apeiros> some of us do, yes
<havenwood> elev: Yup. There are several times the number of Rubyists in #ruby as well.
piotrj has joined #ruby-lang
<havenwood> Compared to here.
<yorickpeterse> argh, of course I can't reproduce this thing outside of our production env
alestuber has quit [Ping timeout: 272 seconds]
<ecnalyr_> Given: [["unknown"], [], [], ["Level"], []] how would I return ["unknown", "level"] ?
<apeiros> ecnalyr_: reject + empty?
nertzy has quit [Quit: This computer has gone to sleep]
<apeiros> oh, + flatten(1)
bungoman has quit [Ping timeout: 245 seconds]
<apeiros> or actually just flatten(1)
<apeiros> >> [["unknown"], [], [], ["Level"], []].flatten(1)
<eval-in> apeiros => ["unknown", "Level"] (https://eval.in/318410)
<ecnalyr_> perfect, flatten works
<ecnalyr_> was losing my mind
<yorickpeterse> headius: well, at least I can repro my autoloading problem on rbx
<ecnalyr_> tip of the tongue thing
<headius> apeiros: I'm happy with my current level :-)
<headius> yorickpeterse: with the sdk?
piotrj has quit [Ping timeout: 265 seconds]
<yorickpeterse> Yeah
<yorickpeterse> lemme shoot that over to the right place, jruby at least so far runs along fine
<yorickpeterse> headius: https://gist.github.com/YorickPeterse/2efb97451fd27c34aec7 this fails at least on rbx
<yorickpeterse> can't get it to fail on jruby though
<headius> harumph
<headius> ok
<headius> I'm looking for other accesses of Base in the sdk
alestuber has joined #ruby-lang
<headius> to see if it might trigger some other way
baweaver has quit [Remote host closed the connection]
<headius> I wish the pattern of naming every base class "Base" hadn't caught on in Ruby
<yorickpeterse> heh
<yorickpeterse> blame Rails for that
<headius> it's impossible for tools OR humans to know which Base you're talking about
<elev> lol
<headius> well not impossible, but you know what I mean
<headius> 96 occurrences of "Base"
<wmoxam> Base means 'all your base; obvs.
<yorickpeterse> blegh, I'll do some production testing for this next week
postmodern has joined #ruby-lang
allomov has quit [Remote host closed the connection]
<yorickpeterse> probably highly dependant on the workload
<headius> module AbstractBase
<headius> srsly?
<yorickpeterse> e.g. this app that would fail actually did things
<wmoxam> we def need a BaseFactory
<headius> yorickpeterse: try that flag I mentioned...it shouldn't affect execution, but it will print out load hierarchy whenever there's a load or require
<headius> wmoxam: +1
<yorickpeterse> BaseBean
<headius> AbstractBaseBeanFactoryServiceLoader
<elev> clea
elev has quit [Quit: leaving]
<yorickpeterse> welp, back to HTML for now
<headius> yorickpeterse: sorry I couldn't be more help...let me know if you get more info
<yorickpeterse> np
<yorickpeterse> I mostly have myself to blame for not getting a repro up and running :P
arBmind has joined #ruby-lang
<djellemah> Abstract question for the day: let's pretend SizedQueue#max= accepted 0, and gave you rendezvous semantics (ie a producer would block until there was at least one consumer and vice-versa). Can anybody think of a real-world use case where it would make sense to go from a non-zero max value to zero, and back again? Best I can come up with is some kind of queue pause functionality.
havenwood has quit []
havenwood has joined #ruby-lang
<headius> djellemah: implementing max= efficiently and safely is very problematic, so I'd recommend not using it while the queue is live
<headius> you basically want an exchanger I suppose...look at the concurrent-ruby gem
<headius> it has all the one-off concurrency utilities you'd need
momomomomo has joined #ruby-lang
b_hoffman has joined #ruby-lang
workmad3 has joined #ruby-lang
alestuber has quit [Ping timeout: 255 seconds]
<headius> yorickpeterse: my script failed on rbx after about 1000 iterations
<headius> jruby doesn't seem to fail...passing 10000
<headius> woah, segfault
<headius> in GC
alestuber has joined #ruby-lang
symm- has joined #ruby-lang
wallerdev has quit [Quit: wallerdev]
workmad3 has quit [Ping timeout: 250 seconds]
<headius> failed quicker that time...I guess this is a good repro of somethign for rbx
micmus has quit [Ping timeout: 246 seconds]
Missphoenix has joined #ruby-lang
agarie has quit [Remote host closed the connection]
elia has joined #ruby-lang
cornerma1 has joined #ruby-lang
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Miphix has quit [Ping timeout: 244 seconds]
<djellemah> headius: Thanks, but that's not really what I was asking.
agarie has joined #ruby-lang
cornerman has quit [Ping timeout: 256 seconds]
cornerma1 is now known as cornerman
<headius> djellemah: no, it wasn't
<headius> djellemah: in answer to your actual question, you might reduce queue size if you want to choke off some resource
<headius> like if the queue is being used to feed a set of worker threads, but they can't keep up
<headius> you could drop queue size to slow the input from feeder threads
<headius> mostly to reduce memory in that case
<headius> it would be unusual though...usually you'd just pick a queue size sufficient to keep all worker threads busy and leave it at that
alestuber has quit [Ping timeout: 250 seconds]
lele is now known as Guest24
<yorickpeterse> headius: https://gist.github.com/YorickPeterse/7186655dbfa6c6f8565d managed to narrow it down to this
<yorickpeterse> at least on rbx that will at times fail
baweaver has joined #ruby-lang
alestuber has joined #ruby-lang
<headius> yorickpeterse: hmm
<yorickpeterse> hm, the load engine isn't even required
<yorickpeterse> a reference to just that path will already crash things
<yorickpeterse> though jruby runs it fine
<headius> :-\
allomov has joined #ruby-lang
<yorickpeterse> My theory is that in the time between finishing an autoload and putting the constant in place it tries to load things again
stef204 has quit [Read error: Connection reset by peer]
<yorickpeterse> but during that small time frame the constant nor the Autoload object is there, at least I think
<headius> there is one reference to that autoloaded Base via :: so I'm going to try to add that to my script
allomov has quit [Read error: Connection reset by peer]
<headius> that seems like a good theory
<headius> that needs to be done atomically
<yorickpeterse> ah, I see how our autoload works
<yorickpeterse> heh
<yorickpeterse> we store an Autoload instance under the constant
<yorickpeterse> when const_get is called it tries to load the corresponding file, overwriting the previous definition
<yorickpeterse> at least I think
<yorickpeterse> supposedly require() is thread-safe though
yfeldblum has joined #ruby-lang
kadoppe has quit [Ping timeout: 276 seconds]
joaomdmoura has joined #ruby-lang
<yorickpeterse> now it works
<yorickpeterse> good ol' Rubinius.synchronize
<yorickpeterse> can't solve it? lock it!
allomov has joined #ruby-lang
<headius> heh, can't solve it? deadlock it!
<yorickpeterse> well, Rubinius.synchronize guards against that
<headius> that's not possible
<yorickpeterse> That is, it relies on Rubinius.lock which doesn't re-lock if the calling thread already locked it
kadoppe has joined #ruby-lang
<yorickpeterse> so you prevent recursive locking
<headius> that's not a deadlock
sarkyniin has quit [Ping timeout: 244 seconds]
<yorickpeterse> not sure if a deadlock would be possible here
<headius> deadlock is when you have two separate threads with resources locked attempting to lock each other's resources
<yorickpeterse> hm, I need to think about this, back in a bit
<headius> if you are using a global lock it's fine
chinmay_dd has joined #ruby-lang
<headius> if it's a unique lock and locking logic can be reached more than once and in different orders for different autoloads, it can deadlock
* headius waves from 10000 feet
ItSANg___ has quit [Quit: Leaving...]
joaomdmoura has quit [Ping timeout: 245 seconds]
chadwtaylor has quit [Read error: Connection reset by peer]
<headius> yorickpeterse: bleh, I was really hoping we'd be able to reproduce this before 9k.pre2 release
<headius> that will happen early next week
sarkyniin has joined #ruby-lang
nertzy has joined #ruby-lang
bungoman has joined #ruby-lang
alestuber has quit [Ping timeout: 276 seconds]
alestuber has joined #ruby-lang
nofxx has joined #ruby-lang
micmus has joined #ruby-lang
guillaume-rb has joined #ruby-lang
jwaldrip has joined #ruby-lang
atomical has quit [Ping timeout: 245 seconds]
ItSANgo has joined #ruby-lang
chadwtaylor has joined #ruby-lang
Lewix has joined #ruby-lang
fusillicode has quit [Ping timeout: 265 seconds]
fusillicode has joined #ruby-lang
havenwood has quit [Remote host closed the connection]
<nofxx> How to deal with this multi extensions hell: DBF uses 3 files for geostuff: foo.dbf, foo.shp and foo.shx. A user opens that data with ShpFile.new('/some/file.shp'), no need to input all parameters, I'll just find the others. Now the problem: case sensitiveness. Without asking the user for the 3 files, should I try to find the others with case insensitiveness?
djbkd has quit [Remote host closed the connection]
piotrj has joined #ruby-lang
<nofxx> User opens 'foo.shp', and that'll match 'foo.dbf' || 'FOO.DBF'
<nofxx> actually /i , so there's more confusion: DBF, Dbf, dbf...
wallerdev has joined #ruby-lang
wallerdev has quit [Client Quit]
banister has joined #ruby-lang
fusillicode has quit [Ping timeout: 245 seconds]
wallerdev has joined #ruby-lang
Kache4 has joined #ruby-lang
alestuber has quit [Ping timeout: 276 seconds]
ta has quit [Remote host closed the connection]
stef204 has joined #ruby-lang
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ta has joined #ruby-lang
allomov has quit [Remote host closed the connection]
ascarter has joined #ruby-lang
joaomdmoura has joined #ruby-lang
charliesome has quit [Quit: zzz]
mikekellyio has joined #ruby-lang
alestuber has joined #ruby-lang
revath has quit [Ping timeout: 264 seconds]
allomov has joined #ruby-lang
momomomomo has quit [Quit: momomomomo]
atomical has joined #ruby-lang
jds has quit [Quit: Connection closed for inactivity]
SylarRuby has joined #ruby-lang
chadwtaylor has quit [Quit: Leaving...]
Lewix has quit [Remote host closed the connection]
b_hoffman has quit [Quit: b_hoffman]
ludico8 has joined #ruby-lang
<ludico8> Hi guys!
<ludico8> Could someone help me with this: I'm trying use the method respond_to do |format|
<ludico8> but when I did it I got it this response:
<ludico8> "error": "Internal Server Error: undefined method `respond_to' for #<Grape::Endpoint:0x007f5a5cb251c0>"
<ludico8> btw, I;m using Grape::API
<ludico8> but It should be, doesn't it?
<ludico8> but It should works, doesn't it?
duderonomy has quit [Quit: Textual IRC Client: www.textualapp.com]
skade has quit [Read error: Connection reset by peer]
skade has joined #ruby-lang
momomomomo has joined #ruby-lang
baweaver has quit [Remote host closed the connection]
joaomdmo_ has joined #ruby-lang
agarie has quit []
joaomdmoura has quit [Ping timeout: 245 seconds]
alestuber has quit [Ping timeout: 240 seconds]
<nofxx> ludico8, better luck on #rubyonrails , but check for respond_with
<nofxx> or grape api, it's suppose to return json & xml?
alestuber has joined #ruby-lang
guillaume-rb has quit [Quit: guillaume-rb]
jgpawletko has quit [Quit: jgpawletko]
slawrence00 has quit [Ping timeout: 256 seconds]
simi has quit [Ping timeout: 245 seconds]
b_hoffman has joined #ruby-lang
workmad3 has joined #ruby-lang
djbkd has joined #ruby-lang
yxhuvud has quit [Remote host closed the connection]
alestuber has quit [Ping timeout: 244 seconds]
<yorickpeterse> headius: found you a script that triggers autoloading issues
workmad3 has quit [Ping timeout: 250 seconds]
Musashi007 has joined #ruby-lang
<yorickpeterse> headius: that fails for me using jruby 1.7.18 with 'NameError: uninitialized constant RSpec::Matchers::BuiltIn"
momomomomo has quit [Ping timeout: 245 seconds]
symm- has quit [Ping timeout: 264 seconds]
alestuber has joined #ruby-lang
__butch__ has quit [Quit: Leaving.]
ludico8 has quit [Ping timeout: 246 seconds]
<headius> yorickpeterse: excellent!
baweaver has joined #ruby-lang
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<headius> that's really weird
<headius> it finishes a ton of threads before blowing up
<yorickpeterse> haha yeah, it's super wacky
<yorickpeterse> oh this is nice
<yorickpeterse> we have two autoload resolvers
<yorickpeterse> one in Ruby, one in C++
<headius> yorickpeterse: BuiltIn isn't even autoloaded
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
<yorickpeterse> oh?
<headius> not as far as I can see
<yorickpeterse> hm, seems our C++ resolver does some extra magic after my synchronization code
<yorickpeterse> headius: seems to be just a namespace
<headius> yep
<yorickpeterse> so my guess is that something higher up is autoloaded
<headius> it shouldn't get to ::BuiltIn failing if the others fail though
<headius> Matchers isn't either
<headius> and RSpec definitely isn't
<yorickpeterse> heh
baweaver has quit [Remote host closed the connection]
nertzy has quit [Quit: This computer has gone to sleep]
Musashi007 has quit [Quit: Musashi007]
sleepee has joined #ruby-lang
skade has quit [Quit: Textual IRC Client: www.textualapp.com]
momomomomo has joined #ruby-lang
sgambino has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
simi has joined #ruby-lang
shinnya has quit [Ping timeout: 246 seconds]
piotrj has quit [Remote host closed the connection]
sideshowcoder has quit [Ping timeout: 255 seconds]
ldnunes has quit [Quit: Leaving]
workmad3 has joined #ruby-lang
piotrj has joined #ruby-lang
alestuber has quit [Ping timeout: 252 seconds]
crankhar1er has quit [Ping timeout: 240 seconds]
allomov has quit [Remote host closed the connection]
alestuber has joined #ruby-lang
sideshowcoder has joined #ruby-lang
fusillicode has joined #ruby-lang
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
atomical has quit [Remote host closed the connection]
atomical has joined #ruby-lang
ascarter has joined #ruby-lang
relix has joined #ruby-lang
sleepee has quit [Quit: Leaving]
Lewix has joined #ruby-lang
<headius> yorickpeterse: this doesn't seem to have anything to do with autoload in JRuby
crankharder has joined #ruby-lang
k3asd` has quit [Quit: leaving]
Voker57 has joined #ruby-lang
Lewix has quit [Read error: Connection reset by peer]
Lewix has joined #ruby-lang
howdoicomputer has joined #ruby-lang
<yorickpeterse> oh?
baweaver has joined #ruby-lang
baweaver has quit [Remote host closed the connection]
workmad3 has quit [Ping timeout: 256 seconds]
whippythellama has quit [Quit: whippythellama]
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
malconis has joined #ruby-lang
malconis has quit [Client Quit]
Lewix has quit [Read error: Connection reset by peer]
baweaver has joined #ruby-lang
Lewix has joined #ruby-lang
SylarRuby has quit []
micmus has quit [Ping timeout: 256 seconds]
chouhoulis has quit [Ping timeout: 250 seconds]
piotrj has quit [Read error: Connection reset by peer]
piotrj has joined #ruby-lang
lytol has quit [Remote host closed the connection]
solars has quit [Ping timeout: 272 seconds]
baweaver has quit [Remote host closed the connection]
lytol has joined #ruby-lang
fusillicode1 has joined #ruby-lang
fusillicode has quit [Quit: Leaving.]
fusillicode has joined #ruby-lang
baweaver has joined #ruby-lang
delongG has joined #ruby-lang
rbowlby has joined #ruby-lang
fusillicode1 has quit [Ping timeout: 255 seconds]
cengizIO has joined #ruby-lang
cengizIO has left #ruby-lang [#ruby-lang]
yfeldblum has quit [Remote host closed the connection]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
crankharder has quit [Ping timeout: 264 seconds]
bungoman_ has joined #ruby-lang
<headius> yorickpeterse: yeah I even removed the last element and it still fails
<headius> that's the only one in the chain that appears to be autoloaded
crankharder has joined #ruby-lang
fusillicode has quit [Read error: Connection reset by peer]
fusillicode has joined #ruby-lang
bungoman has quit [Ping timeout: 256 seconds]
alestuber has quit [Ping timeout: 264 seconds]
alestuber has joined #ruby-lang
bungoman_ has quit [Ping timeout: 250 seconds]
yfeldblum has joined #ruby-lang
simi has quit [Ping timeout: 255 seconds]
k3asd` has joined #ruby-lang
k3asd` has quit [Changing host]
k3asd` has joined #ruby-lang
lele|w has quit [Remote host closed the connection]
pipework is now known as |work
michael_mbp has quit [Excess Flood]
b_hoffman has quit [Quit: b_hoffman]
|work is now known as pipework
michael_mbp has joined #ruby-lang
iamninja_ has quit [Read error: Connection reset by peer]
iamninja_ has joined #ruby-lang
piotrj has quit [Remote host closed the connection]
momomomomo has quit [Quit: momomomomo]
michael_mbp has quit [Excess Flood]
michael_mbp has joined #ruby-lang
alestuber has quit [Ping timeout: 256 seconds]
michael_mbp has quit [Excess Flood]
yfeldblum has quit [Remote host closed the connection]
michael_mbp has joined #ruby-lang
yfeldblum has joined #ruby-lang
piotrj has joined #ruby-lang
arBmind1 has joined #ruby-lang
djbkd has quit [Remote host closed the connection]
arBmind has quit [Ping timeout: 250 seconds]
k3asd` has quit [Read error: Connection reset by peer]
setanta_ has quit [Quit: Leaving]
duderonomy has joined #ruby-lang
crdpink2 has quit [Ping timeout: 245 seconds]
crdpink has joined #ruby-lang
k3asd` has joined #ruby-lang
victortyau has quit [Quit: Leaving]
crankharder has quit [Ping timeout: 240 seconds]
jwaldrip has quit [Quit: Be back later ...]
enebo has quit [Quit: enebo]
k3asd` has quit [Read error: Connection reset by peer]
mikecmpbll has quit [Quit: ciao.]
mkosaki has joined #ruby-lang
hellome has joined #ruby-lang
baweaver has quit [Remote host closed the connection]
b_hoffman has joined #ruby-lang
k3asd` has joined #ruby-lang
mkosaki has quit [Client Quit]
sarkyniin has quit [Ping timeout: 256 seconds]
Cloudhand has quit [Ping timeout: 256 seconds]
crankharder has joined #ruby-lang
baweaver has joined #ruby-lang
ItSANgo has quit [Quit: Leaving...]
rcvalle has quit [Quit: rcvalle]
baweaver has quit [Remote host closed the connection]
workmad3 has joined #ruby-lang
baweaver has joined #ruby-lang
Forgetful_Lion has joined #ruby-lang
djbkd has joined #ruby-lang
Voker57 has quit [Ping timeout: 256 seconds]
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ItSANgo has joined #ruby-lang
joaomdmo_ has quit [Remote host closed the connection]
joaomdmoura has joined #ruby-lang
joaomdmoura has quit [Ping timeout: 244 seconds]
k3asd` has quit [Quit: leaving]
Iskarlar has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bungoman has joined #ruby-lang
piotrj has quit [Remote host closed the connection]
wallerdev has quit [Quit: wallerdev]
dorei has joined #ruby-lang
slawrence00 has joined #ruby-lang
marr has quit [Read error: Connection reset by peer]
constantinexvi has quit [Quit: Exiting]
LMity has joined #ruby-lang
hahuang65 has quit [Ping timeout: 246 seconds]
workmad3 has quit [Ping timeout: 245 seconds]
ascarter has joined #ruby-lang
djbkd has quit [Quit: My people need me...]
LMity has quit [Ping timeout: 256 seconds]
banister has quit [Read error: Connection reset by peer]
fr1eza has joined #ruby-lang
delongG has quit [Remote host closed the connection]
delongG has joined #ruby-lang
wallerdev has joined #ruby-lang