ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby-lang
|jemc| has quit [Ping timeout: 265 seconds]
mattyohe has quit [Quit: Connection closed for inactivity]
emmesswhy has quit [Quit: This computer has gone to sleep]
symm- has joined #ruby-lang
AKASkip has joined #ruby-lang
wallerdev has joined #ruby-lang
jo__ has quit [Quit: Connection closed for inactivity]
|jemc| has joined #ruby-lang
[spoiler] has joined #ruby-lang
wallerdev has quit [Ping timeout: 240 seconds]
koderok has joined #ruby-lang
brianpWins has joined #ruby-lang
symm- has quit [Ping timeout: 240 seconds]
rippa has joined #ruby-lang
Blaguvest has joined #ruby-lang
jxie has quit [Remote host closed the connection]
mkaesz has joined #ruby-lang
|jemc| has quit [Ping timeout: 272 seconds]
q_leonetti has joined #ruby-lang
JoshuaPaling has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
migbar has joined #ruby-lang
kaczmar has joined #ruby-lang
jdecuirm has quit [Remote host closed the connection]
jdecuirm has joined #ruby-lang
diegoviola has quit [Quit: WeeChat 1.0.1]
kaczmar has quit [Client Quit]
mistym has quit [Remote host closed the connection]
mkaesz has quit [Ping timeout: 250 seconds]
solars has joined #ruby-lang
migbar has quit [Ping timeout: 265 seconds]
fusillicode has joined #ruby-lang
allomov has joined #ruby-lang
workmad3 has joined #ruby-lang
[spoiler] has quit [Quit: Leaving]
yfeldblum has quit [Ping timeout: 265 seconds]
mkaesz has joined #ruby-lang
RitterJack has joined #ruby-lang
wallerdev has joined #ruby-lang
JoshuaPaling has joined #ruby-lang
tbuehlmann has joined #ruby-lang
jmrepetti has joined #ruby-lang
jxie has joined #ruby-lang
wallerdev has quit [Ping timeout: 265 seconds]
existensil has quit [Ping timeout: 256 seconds]
kaczmar has joined #ruby-lang
allomov_ has joined #ruby-lang
rahul_j has quit [Quit: rahul_j]
allomov has quit [Ping timeout: 244 seconds]
nofxx has quit [Ping timeout: 250 seconds]
hackingoff has joined #ruby-lang
existensil has joined #ruby-lang
futilegames has joined #ruby-lang
workmad3 has quit [Ping timeout: 244 seconds]
jk_scowling has joined #ruby-lang
jk_scowling has quit [Remote host closed the connection]
jk_scowling has joined #ruby-lang
[spoiler] has joined #ruby-lang
rahul_j has joined #ruby-lang
<zenspider>
anyone know how to make a new git repo out of the commits from a subdir in a different repo? I'd prefer if everything else (timestamps etc) stayed the same
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
existensil has quit [Ping timeout: 245 seconds]
robbyoconnor has joined #ruby-lang
qba73 has joined #ruby-lang
hagabaka has quit [Read error: Connection reset by peer]
jmrepetti has quit [Remote host closed the connection]
theotherstupidgu has quit [Ping timeout: 240 seconds]
theotherstupidgu has joined #ruby-lang
ldnunes has joined #ruby-lang
stamina has joined #ruby-lang
hagabaka has quit [Read error: Connection reset by peer]
hagabaka has joined #ruby-lang
allomov has quit [Remote host closed the connection]
godd2 has quit [Ping timeout: 264 seconds]
jmrepetti has quit [Remote host closed the connection]
allomov has joined #ruby-lang
<yusuf>
what is < sign in class definition?
<yusuf>
extend?
<tbuehlmann>
that's inheritance
<whitequark>
essentially
<yusuf>
ohhh, i see, thanks , :D
jmrepetti has joined #ruby-lang
skade has joined #ruby-lang
migbar has quit [Remote host closed the connection]
migbar has joined #ruby-lang
wallerdev has joined #ruby-lang
jk_scowling has quit []
<maloik>
So liberating to work on a pure ruby project for once, even though I've already had a couple mindfucks by falling back to the default relational db mindset
migbar has quit [Ping timeout: 264 seconds]
theotherstupidgu has quit [Ping timeout: 245 seconds]
theotherstupidgu has joined #ruby-lang
wallerdev has quit [Ping timeout: 244 seconds]
RitterJack has quit [Remote host closed the connection]
ledestin has quit [Read error: Connection reset by peer]
sarkyniin has joined #ruby-lang
ledestin has joined #ruby-lang
theotherstupidgu has quit [Ping timeout: 255 seconds]
jxie has quit [Quit: leaving]
theotherstupidgu has joined #ruby-lang
_whitelogger has quit [Ping timeout: 256 seconds]
_whitelogger has joined #ruby-lang
henrikhodne has joined #ruby-lang
allomov has quit [Remote host closed the connection]
charliesome has joined #ruby-lang
francisfish has joined #ruby-lang
allomov has joined #ruby-lang
jxie has joined #ruby-lang
migbar has joined #ruby-lang
allomov has quit [Read error: Connection reset by peer]
allomov has joined #ruby-lang
tkuchiki has quit [Remote host closed the connection]
tkuchiki has joined #ruby-lang
michd is now known as MichD
charliesome has quit [Quit: zzz]
rahul_j has quit [Quit: rahul_j]
theotherstupidgu has quit [Ping timeout: 250 seconds]
theotherstupidgu has joined #ruby-lang
charliesome has joined #ruby-lang
tkuchiki has quit [Ping timeout: 265 seconds]
jmrepetti has quit [Remote host closed the connection]
lcdhoffman has joined #ruby-lang
banister_ has quit [Read error: Connection reset by peer]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
emmesswhy has quit [Quit: This computer has gone to sleep]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
kaczmar has quit [Quit: kaczmar]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
mkaesz has joined #ruby-lang
arBmind has joined #ruby-lang
workmad3 has joined #ruby-lang
banister has joined #ruby-lang
lcdhoffman has quit [Quit: lcdhoffman]
fusillicode has quit [Ping timeout: 255 seconds]
spastorino has joined #ruby-lang
wallerdev has joined #ruby-lang
banister has quit [Ping timeout: 264 seconds]
lcdhoffman has joined #ruby-lang
koderok has quit [Quit: koderok]
wallerdev has quit [Ping timeout: 250 seconds]
lifeng has joined #ruby-lang
symm- has joined #ruby-lang
workmad3 has quit [Ping timeout: 255 seconds]
fusillicode has joined #ruby-lang
banister has joined #ruby-lang
lifeng has left #ruby-lang [#ruby-lang]
JaReAx has joined #ruby-lang
charliesome has quit [Quit: zzz]
jmrepetti has joined #ruby-lang
bronky has joined #ruby-lang
bronky has quit [Client Quit]
michael_mbp has quit [Excess Flood]
teleporting_cat has joined #ruby-lang
michael_mbp has joined #ruby-lang
<yorickpeterse>
well, looks like MRI 2.1.3's GC is still crap
duderonomy has quit [Ping timeout: 244 seconds]
<yorickpeterse>
disabled our tweaks, the amount of minor GC runs exploded
<yorickpeterse>
something something bar charts would be better here
<yorickpeterse>
or maybe a pie chart
<whitequark>
seven invalidations don't sound so bad
RitterJack has joined #ruby-lang
<whitequark>
oh wait
<whitequark>
per transaction
<ljarvis>
per transaction
<ljarvis>
LOL
Forgetful_Lion has quit [Remote host closed the connection]
<oddmunds>
ruby heap size looks like arrows dipped in poison
<yorickpeterse>
32k in total
<ljarvis>
I think i know the problem
<yorickpeterse>
note that this is something that has ~40k transactions twice a day
<yorickpeterse>
something tells me this is mongoid
<ljarvis>
why does it only run twice a day?
gnufied has joined #ruby-lang
<yorickpeterse>
because we only need to run it twice a day
<ljarvis>
logic
<yorickpeterse>
(shocking eh?)
<ljarvis>
out logic'd
workmad3 has joined #ruby-lang
<yorickpeterse>
Hm, I wonder if I can somehow trace what's causing the invalidations
<yorickpeterse>
without first throwing out the usual suspect (mongo)
_whitelogger has joined #ruby-lang
<tbuehlmann>
there are always low hanging documentation fruits
<chris2>
sure
<chris2>
but i think t4nk674 wants to code
<t4nk674>
I did the CodeCademy guide, but tha's mostly all.
<yorickpeterse>
Right, so basically a complete beginner
henrikhodne has joined #ruby-lang
<yorickpeterse>
yeah in that case skip Rails and MRI (ruby/ruby on Github), those are probably too difficult
<tbuehlmann>
:P
<yorickpeterse>
(latter involves a lot of C)
<yorickpeterse>
actually jruby and rbx shouldn't be too much of a problem for the Ruby side of things, but it's a bit of a step for a total beginner
<ljarvis>
I would search for a smaller project, and look through the issues. See if you can fix something, or implement a feature
<darix>
openSUSE 13.2 is out. now with even more powerful ruby packaging. :)
<yorickpeterse>
t4nk674: is this for high school or university?
<t4nk674>
The first one.
<yorickpeterse>
Hm, proper open source would totally steal the show there
<darix>
yorickpeterse: naw. teach them the right way rihgt from the start
lcj has joined #ruby-lang
<yorickpeterse>
"rihgt"
* yorickpeterse
ducks
<yorickpeterse>
t4nk674: any particular topics that interest you when it comes to programming? Do you want to focus more on web related things or something more hardcore (e.g. compilers, virtual machines, etc)?
<t4nk674>
Web related would be nice. Otherwise, I'm more the math/physics nerd.
<yorickpeterse>
Hm, I wonder if sciruby is still a thing
<oddmunds>
t4nk674: sounds like media og kommunikasjon
<kalleth>
ive been rubbying for like 5 years and i'd cry
<kalleth>
that'd literally make me go become a police officer instead of a developer
<yorickpeterse>
kalleth: I've seen newbies pick it up pretty quickly, at least with Rbx
<kalleth>
really?
<yorickpeterse>
Note I'm not talking about the VM, that's adults only business
<kalleth>
oh
<kalleth>
okay
<kalleth>
phew
<maloik>
you basically have a good excuse to play with robots, there's no reason not to build something with that :D
* kalleth
definitely not an adul
<kalleth>
t
<yorickpeterse>
:P
<maloik>
and if lego nxt isn't a good option, look at drones or arduinos or something... plenty happening in that space (but obviously a bit more expensive)
miqui has joined #ruby-lang
<t4nk674>
oddmunds: More like studiespesialisering.
<yorickpeterse>
that's basically a note taking app with image uploads
<maloik>
if you want something with a database you're better off making one with photoshop shortcuts or tutorials or something like that, something relevant to your studies
lcj has quit [Quit: 离开]
<t4nk674>
If you just throw some simple, yet with a high learning factor, idas at me, I'm sure we can puzzle something together.
jo__ has joined #ruby-lang
Musashi007 has quit [Quit: Musashi007]
<yorickpeterse>
random idea: music library organizer
<yorickpeterse>
there's some Gem for pulling out mp3 tags, which you can then use to auto-create folders, correct file names, etc
mkaesz has quit [Remote host closed the connection]
jimbach has joined #ruby-lang
<t4nk674>
Aha! I found it! I'll make an app with Appinventor.
SuMo_D has joined #ruby-lang
<t4nk674>
yorickpeterse: But I'' defenetly look into the folder generator.
wallerdev has joined #ruby-lang
<t4nk674>
I'll probably never use it again, but It'll be a nice project.
rippa has joined #ruby-lang
kaczmar has joined #ruby-lang
wallerdev has quit [Ping timeout: 245 seconds]
melter has joined #ruby-lang
rsl has joined #ruby-lang
[spoiler] has quit [Quit: Leaving]
[spoiler] has joined #ruby-lang
[spoiler] has quit [Remote host closed the connection]
mdarby_ has joined #ruby-lang
mdarby_ is now known as mdarby
oleo has joined #ruby-lang
banister is now known as banisterfiend
|jemc| has joined #ruby-lang
ta has quit [Read error: Connection reset by peer]
SuMo_D has quit [Remote host closed the connection]
banisterfiend has quit [Read error: Connection reset by peer]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
hinbody has quit [Ping timeout: 265 seconds]
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
hinbody has joined #ruby-lang
t4nk674 has quit [Ping timeout: 246 seconds]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
banister has joined #ruby-lang
banister has quit [Max SendQ exceeded]
jonarrien has joined #ruby-lang
banister has joined #ruby-lang
AKASkip has quit [Ping timeout: 250 seconds]
jmrepetti has quit [Remote host closed the connection]
enebo has joined #ruby-lang
oleo__ has joined #ruby-lang
oleo is now known as Guest35719
jonarrien has left #ruby-lang ["Textual IRC Client: www.textualapp.com"]
arBmind1 has quit [Quit: Leaving.]
banister has quit [Read error: Connection reset by peer]
banister has joined #ruby-lang
Guest35719 has quit [Ping timeout: 244 seconds]
Novtopro has joined #ruby-lang
mkaesz has joined #ruby-lang
whippythellama has joined #ruby-lang
<yorickpeterse>
well, constant cache hack deployed, lets see what the graphs say in a bit
x0f has quit [Ping timeout: 264 seconds]
jonathan_alban has joined #ruby-lang
x0f has joined #ruby-lang
SuMo_D has joined #ruby-lang
Novtopro has left #ruby-lang [#ruby-lang]
jonathan_alban has quit [Client Quit]
jonathan_alban has joined #ruby-lang
nelsonsar has joined #ruby-lang
ta has joined #ruby-lang
nelsonsar has quit [Remote host closed the connection]
nelsonsa_ has joined #ruby-lang
<headius>
yorickpeterse: constant cache hack?
wallerdev has joined #ruby-lang
<ljarvis>
oh no
<ljarvis>
headius why did you ask
<maloik>
:D
jmrepetti has joined #ruby-lang
nelsonsa_ has quit [Remote host closed the connection]
tbuehlmann has quit [Remote host closed the connection]
wallerdev has quit [Ping timeout: 264 seconds]
<headius>
just curious what hack yorickpeterse is using to avoid constant cache flushing
<yorickpeterse>
headius: some patch for httpclient so it doesn't call Object#extend during runtime
<yorickpeterse>
if it works it will be a proper PR
SuMo_D has quit [Remote host closed the connection]
SuMo_D has joined #ruby-lang
francisfish has quit [Remote host closed the connection]
<oddmunds>
cacheflushing is fun
arBmind has joined #ruby-lang
imperator has joined #ruby-lang
<headius>
yorickpeterse: very good
srenatus has joined #ruby-lang
SuMo_D has quit [Ping timeout: 244 seconds]
mnngfltg has joined #ruby-lang
cored has joined #ruby-lang
cored has joined #ruby-lang
mdarby has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
dagda1 has joined #ruby-lang
SuMo_D has joined #ruby-lang
cmhobbs has joined #ruby-lang
cmhobbs has joined #ruby-lang
mattyohe has joined #ruby-lang
dm78_ has quit []
dm78 has joined #ruby-lang
dm78 has quit [Client Quit]
arooni-mobile has joined #ruby-lang
tenderlove has joined #ruby-lang
oleo__ has quit [Quit: Verlassend]
amjibaly has joined #ruby-lang
mistym has joined #ruby-lang
shinnya has quit [Ping timeout: 245 seconds]
oleo has joined #ruby-lang
|jemc| has quit [Ping timeout: 264 seconds]
mdarby has joined #ruby-lang
mistym has quit [Remote host closed the connection]
cored has quit [Ping timeout: 244 seconds]
mdarby has quit [Max SendQ exceeded]
mdarby has joined #ruby-lang
cored has joined #ruby-lang
sent1nel has joined #ruby-lang
diegoviola has joined #ruby-lang
emmesswhy has joined #ruby-lang
emmesswhy has quit [Client Quit]
nelsonsar has joined #ruby-lang
araujo has quit [Read error: Connection reset by peer]
araujo has joined #ruby-lang
solars has quit [Ping timeout: 250 seconds]
workmad3 has joined #ruby-lang
slawrence00 has joined #ruby-lang
futilegames has quit [Quit: futilegames]
q_leonetti has quit [Quit: q_leonetti]
futilegames has joined #ruby-lang
<ljarvis>
reading rust code makes my face bleed
SuMo_D has quit [Remote host closed the connection]
cored has quit [Ping timeout: 272 seconds]
cored has joined #ruby-lang
cored has joined #ruby-lang
wallerdev has joined #ruby-lang
srenatus has left #ruby-lang [#ruby-lang]
imperator has quit [Ping timeout: 265 seconds]
mdarby has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ta has quit [Read error: Connection reset by peer]
wallerdev has quit [Ping timeout: 256 seconds]
imperator has joined #ruby-lang
arooni-mobile has quit [Ping timeout: 244 seconds]
<ericwood>
keep tissues at your desk
skade has quit [Quit: Computer has gone to sleep.]
michael_mbp has quit [Excess Flood]
workmad3 has quit [Ping timeout: 258 seconds]
fusillicode has quit [Ping timeout: 250 seconds]
<whitequark>
ljarvis: please don't tell me it's about syntax
michael_mbp has joined #ruby-lang
<ljarvis>
whitequark: well it's certainly not all of the awesome that's painful to look at
cored_ has joined #ruby-lang
brianpWins has quit [Quit: brianpWins]
sarkyniin has quit [Remote host closed the connection]
cored has quit [Ping timeout: 264 seconds]
sarkyniin has joined #ruby-lang
migbar has quit [Read error: Connection reset by peer]
migbar has joined #ruby-lang
<yorickpeterse>
whitequark: rust syntax is meh
<yorickpeterse>
:>
<whitequark>
syntax is superficial
<ljarvis>
hmm, new feature? I know! sigils.shuffle.pop
<yorickpeterse>
whitequark: bullshit
<ljarvis>
(and yeah I know they're generally moving away with most of the weird sigils)
<yorickpeterse>
whitequark: you try looking at brainfuck all day
sarkyniin has quit [Client Quit]
<ljarvis>
way to go extreme
sarkyniin has joined #ruby-lang
<whitequark>
yorickpeterse: bzzt, wrong
<whitequark>
the problem with brainfuck is semantics and only it
arooni-mobile has joined #ruby-lang
sarkyniin has quit [Client Quit]
<ljarvis>
whitequark is 90% insane
sarkyniin has joined #ruby-lang
<whitequark>
in fact, the syntax of brainfuck is *perfect*, it represents the semantics in a simple and vivid way
<thegmanehack>
yeah from the "Ruby Association" I realize that most people think the cert is dumb.. but i'm being forced to take it.
<whitequark>
brainfuck implements a turing machine. it's good at the tasks at which a turing machine is good, and the syntax is concise for those, which is the only thing that matters about syntax
hramrach_ has quit [Ping timeout: 250 seconds]
<thegmanehack>
was wondering if anyone had taken it and could suggest some good study material. the suggested study material is out dated.
migbar has quit [Ping timeout: 260 seconds]
sarkyniin has quit [Ping timeout: 256 seconds]
<whitequark>
yorickpeterse: now, if you gave me APL (or, say, J) as a counterexample, that'd make some sense
nathanstitt has joined #ruby-lang
cored has quit [Ping timeout: 250 seconds]
cored has joined #ruby-lang
bruno- has joined #ruby-lang
bruno- has quit [Client Quit]
nelsonsar has quit [Remote host closed the connection]
amjibaly has quit [Ping timeout: 265 seconds]
hramrach_ has joined #ruby-lang
fusillicode has joined #ruby-lang
mikecmpb_ is now known as mikecmpbll
djbkd has joined #ruby-lang
whippythellama has quit [Quit: whippythellama]
whippythellama has joined #ruby-lang
AKASkip has joined #ruby-lang
djbkd_ has quit [Ping timeout: 265 seconds]
thagomizer has joined #ruby-lang
nelsonsar has joined #ruby-lang
amsi has joined #ruby-lang
amjibaly has joined #ruby-lang
_dabradley has quit [Ping timeout: 250 seconds]
imkmf has joined #ruby-lang
qba73 has quit []
wallerdev has joined #ruby-lang
cored has quit [Ping timeout: 245 seconds]
RobertBirnie has joined #ruby-lang
cored has joined #ruby-lang
cored has quit [Changing host]
cored has joined #ruby-lang
kaczmar has joined #ruby-lang
mistym has joined #ruby-lang
brianpWins has joined #ruby-lang
wallerdev has quit [Ping timeout: 264 seconds]
skade has joined #ruby-lang
dabradley has joined #ruby-lang
mikecmpbll has quit [Quit: i've nodded off.]
amjibaly has quit [Ping timeout: 265 seconds]
cored_ has joined #ruby-lang
arBmind has quit [Quit: Leaving.]
imperator has quit [Quit: Leaving]
mnngfltg has quit [Quit: Ex-Chat]
cored has quit [Ping timeout: 256 seconds]
apt-get_ is now known as sarkyniin
dbradbury has joined #ruby-lang
sent1nel has quit [Remote host closed the connection]
loincloth has joined #ruby-lang
Stephanyan has quit [Ping timeout: 250 seconds]
henrikhodne has quit [Ping timeout: 256 seconds]
skade has quit [Quit: Computer has gone to sleep.]
__butch__ has joined #ruby-lang
skade has joined #ruby-lang
henrikhodne has joined #ruby-lang
skade has quit [Ping timeout: 244 seconds]
M3M0CooL has joined #ruby-lang
RitterJack has quit [Remote host closed the connection]
apt-get_ has joined #ruby-lang
allomov has quit [Remote host closed the connection]
sarkyniin has quit [Ping timeout: 245 seconds]
apt-get_ is now known as sarkyniin
nathanstitt has quit [Quit: I growing sleepy]
tbuehlmann has joined #ruby-lang
ahmetkapikiran has joined #ruby-lang
wallerdev has joined #ruby-lang
jmrepetti has quit [Remote host closed the connection]
M3M0CooL has quit []
danijoo has quit [Quit: Leaving...]
danijoo has joined #ruby-lang
mikecmpbll has joined #ruby-lang
Musashi007 has joined #ruby-lang
arBmind has joined #ruby-lang
jmrepetti has joined #ruby-lang
sent1nel has joined #ruby-lang
thegmanehack has left #ruby-lang [#ruby-lang]
jonathan_alban has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
cored_ has quit [Ping timeout: 272 seconds]
michael_mbp has quit [Excess Flood]
cored has joined #ruby-lang
michael_mbp has joined #ruby-lang
skade has joined #ruby-lang
mikecmpbll has quit [Quit: i've nodded off.]
mikecmpbll has joined #ruby-lang
jmrepetti has quit [Remote host closed the connection]
nelsonsar has quit [Remote host closed the connection]
cornerma1 has joined #ruby-lang
michael_mbp has quit [Excess Flood]
michael_mbp has joined #ruby-lang
amjibaly has joined #ruby-lang
cornerman has quit [Ping timeout: 265 seconds]
cornerma1 is now known as cornerman
ascarter has joined #ruby-lang
nathanstitt has joined #ruby-lang
ascarter has quit [Client Quit]
nelsonsar has joined #ruby-lang
kurko__ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
arooni-mobile has quit [Ping timeout: 250 seconds]
shinnya has joined #ruby-lang
mistym has joined #ruby-lang
kaczmar has quit [Quit: kaczmar]
AKASkip has quit [Ping timeout: 258 seconds]
|jemc| has quit [Ping timeout: 260 seconds]
amsi has quit [Quit: Leaving]
jimbach has joined #ruby-lang
araujo has quit [Ping timeout: 250 seconds]
amsi has joined #ruby-lang
jimbach has quit [Remote host closed the connection]
fusillicode has quit [Ping timeout: 250 seconds]
cmhobbs has quit [Remote host closed the connection]
thagomizer has joined #ruby-lang
momomomomo has quit [Ping timeout: 250 seconds]
q_leonetti has quit [Quit: q_leonetti]
Musashi007 has quit [Quit: Musashi007]
migbar has quit []
nathanstitt has quit [Quit: I growing sleepy]
Authenticator has joined #ruby-lang
|jemc| has joined #ruby-lang
<Authenticator>
Is there a way to use catch/throw to terminate a multi-threaded process, and catch the throw? I can raise on errors, and rescue the ArgErr: uncaught throw :foo, but I lose the message that went along with the throw.
<|jemc|>
Authenticator: you can use "rescue MyExceptionType => e" instead of "rescue MyExceptionType" and then pull properties out of "e"
<|jemc|>
although I'm not sure throw is the right tool here
<Authenticator>
|jemc|: I did that, but the message from the throw isn't included in the exception that I can see...? Or I'd have just manually parsed and re-thrown from a handler loop in the main thread. But I use the throw message for user-visible errors and they need to be percolated up.
<|jemc|>
Authenticator: I misread your statement - I thought you were using a rescued exception to trigger a throw
<Authenticator>
No, watching a sub-thread throw to be caught properly (message and all) in the main thread.
<|jemc|>
not that I'm condoning using a throw or a raise to do this, but if you raised instead of threw then you would get the actual exception object in your rescue
<|jemc|>
You just need to have Thread.abort_on_exception = true
jo__ has quit [Quit: Connection closed for inactivity]
<jhass>
You should always set a stop flag in the thread and poll that
<jhass>
everything else is not guranteed to be thread safe as it can happen in the middle of some unfinished operation
kalehv has joined #ruby-lang
sent1nel has quit [Remote host closed the connection]
jmrepetti has quit [Remote host closed the connection]
thumpba has quit [Ping timeout: 256 seconds]
Musashi007 has joined #ruby-lang
<Authenticator>
What is catch without arguments for? Is there a wildcard? The problem is the threads are in the IO layer and the thrown signals are logic layer and it's not clear which signals may be thrown.
<jhass>
I yet have to see catch in production code. It probably should be removed from the language
* womble
has used it.
<womble>
Once.
<apeiros>
Authenticator: note that catch/throw in ruby is not the same as raise/rescue
<apeiros>
(i.e., you're using wrong terminology9
<|jemc|>
Authenticator: I would suggest using a Queue (which is threadsafe) - a thread that wishes to terminate can push a TerminationInfoObject onto the queue
<|jemc|>
and the main thread can just call pop on the queue to block until someone terminates
* apeiros
usually pushes nil
<|jemc|>
then it has the object with all of the info you passed into it
<apeiros>
while job = queue.shift
<Authenticator>
apeiros: Yeah, raise/rescue, catch/throw. One is being used for code-level errors, the other for domain logic.