apeiros changed the topic of #ruby-lang to: Nick registration required to talk || Ruby 2.0.0-p195: http://ruby-lang.org (Ruby 1.9.3-p429) || Paste >3 lines of text on http://gist.github.com
torrieri_ has quit [Quit: Leaving...]
rickruby has joined #ruby-lang
srji has joined #ruby-lang
Kabaka has quit [Excess Flood]
DomKM has quit [Ping timeout: 246 seconds]
DomKM1 has joined #ruby-lang
<jroes>
sweet
* jroes
is excited to get rid of rmagick
Kabaka has joined #ruby-lang
<jroes>
zenspider: I showed your refactor snippet to original author, he blames me of course because we were under time pressure :)
havenwood has joined #ruby-lang
brianpWins has joined #ruby-lang
srji has quit [Ping timeout: 248 seconds]
<zenspider>
jroes: haha
<zenspider>
um... PLT
<zenspider>
seriously. owning up on your shit is the first step to developer maturity
<zenspider>
image_science version 1.2.5 has been released! | software releases by ryan davis - http://t.co/dx1QQJymfV
<darix>
yorickpeterse: chrpath is the tool you want.
<darix>
whitequark: even that libv8 gem is silly
torrieri has quit [Ping timeout: 255 seconds]
jstorimer has joined #ruby-lang
<whitequark>
what if... someone discovers a vulnerability in libv8
<yorickpeterse>
WHY ARE THERE PDF FILES IN THIS TARBALL
<whitequark>
and some bright mind decides to feed user-specified data to it?
<yorickpeterse>
AND EPS FILES
<whitequark>
yorickpeterse: DOCS
<yorickpeterse>
AND GIFS
elia has joined #ruby-lang
<whitequark>
yorickpeterse: AND MEMES
<darix>
whitequark: many distros will ship an update for the system copy of libv8 then ... and suddenly all apps using libv8 have a secure copy without patching every intree copy. :)
<darix>
whitequark: as i said the last time we had this discussion if the code would actually prefer the system copy over intree copies
<darix>
i would be fine.
ffio_ has quit [Quit: WeeChat 0.4.1]
<whitequark>
yeah yeah.
MaddinXx_ has joined #ruby-lang
<yorickpeterse>
oh wow, our internet is actually decent today
<yorickpeterse>
a whopping 800kb/sec
<darix>
yorickpeterse: but be glad that they didnt use funny things like haskell or so to implement that stuff.
<yorickpeterse>
Oh I'd much rather have Haskell than this shit
<yorickpeterse>
I'd rather package just Haskell than Perl + Tcl/tk + god knows what else this shit uses
jstorimer has quit [Ping timeout: 240 seconds]
<darix>
i meant additionally to all the things you package already. ;)
<whitequark>
yorickpeterse: GHC's runtime is several hundred megabytes
<whitequark>
(I wonder why?)
<yorickpeterse>
For languages I can just say "install it yourself, get out"
<whitequark>
languages are libraries :p
umttumt has joined #ruby-lang
<yorickpeterse>
and nice, the version of Alpino for OS X is 3 years behind the Linux one by the looks of it
<yorickpeterse>
ughh
<darix>
doesnt ghc needs itself for building?
_elia has joined #ruby-lang
lsegal` has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
elia has quit [Ping timeout: 240 seconds]
vlad_starkov has joined #ruby-lang
ffio has joined #ruby-lang
hashkey has quit []
elia has joined #ruby-lang
srji has joined #ruby-lang
_elia has quit [Ping timeout: 240 seconds]
kgrz has quit [Remote host closed the connection]
poga has quit [Remote host closed the connection]
torrieri has joined #ruby-lang
tbuehlmann has quit [Remote host closed the connection]
postmodern has quit [Quit: Leaving]
injekt has joined #ruby-lang
Aaaarg has quit [Ping timeout: 260 seconds]
injekt has quit [Client Quit]
kgrz has joined #ruby-lang
torrieri has quit [Ping timeout: 246 seconds]
kgrz has quit [Remote host closed the connection]
_elia has joined #ruby-lang
Aaaarg has joined #ruby-lang
elia has quit [Ping timeout: 240 seconds]
Pupeno has joined #ruby-lang
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
elia has joined #ruby-lang
relix has joined #ruby-lang
_elia has quit [Ping timeout: 240 seconds]
_elia has joined #ruby-lang
atmosx has quit [Quit: And so the story goes…]
vlad_starkov has quit [Remote host closed the connection]
barttenbrinke has joined #ruby-lang
<yorickpeterse>
haha this Tcl stuff is so fucking retarded
<yorickpeterse>
HURRDURR IT'S ALWAYS IN /USR/SHARE/TCL RIGHT?
elia has quit [Ping timeout: 240 seconds]
umttumt has quit [Remote host closed the connection]
<rue>
Quick, switch to lua
<yorickpeterse>
Lua is actually an ok language
torrieri has joined #ruby-lang
torrieri has quit [Changing host]
torrieri has joined #ruby-lang
elia has joined #ruby-lang
hashkey has joined #ruby-lang
_elia has quit [Ping timeout: 240 seconds]
ffio has quit [Quit: WeeChat 0.4.1]
torrieri has quit [Ping timeout: 240 seconds]
doug_ has joined #ruby-lang
mikewintermute has joined #ruby-lang
doug_ has quit [Remote host closed the connection]
doug_ has joined #ruby-lang
doug_ has quit [Remote host closed the connection]
slipdigital has joined #ruby-lang
<PaulePanter>
Hi. When I use `load `some_file.rb`, is the source just taken and “pasted” into the file?
elia has quit [Quit: Computer has gone to sleep.]
slipdigital has left #ruby-lang [#ruby-lang]
slipdigital has joined #ruby-lang
<PaulePanter>
and can I use all variables in `some_file.rb` in the “main” fil?
<PaulePanter>
+e
<PaulePanter>
I always get an error: undefined local variable or method `as' for main:Object
mikewintermute has quit [Quit: mikewintermute]
umttumt has joined #ruby-lang
<PaulePanter>
echo "i = 1" > a.rb
<whitequark>
PaulePanter: no, it isn't; this is not PHP
<PaulePanter>
load 'a.rb'
<PaulePanter>
Then I cannot access i.
<PaulePanter>
whitequark: Is the work around using @ in front of the variables?
<whitequark>
do you actually understand how do variables work in ruby?
<PaulePanter>
Probably not.
<lupine>
in fairness, scope in ruby is not entirely obvious
<hashkey>
PaulePanter: there are 4 kinds of variables in Ruby, $globalvariables, @@classvariables, @instancevariables, and localvariables.
<PaulePanter>
hashkey: Ok. Thanks.
<PaulePanter>
Would be nice to have some command just pasting in file contents though in my opinion.
<whitequark>
no, it won't; this way you break encapsulation.
<whitequark>
normally, lexical scope allows you to reason about your code _locally_; that is, you need to look, at most, at several enclosing scopes of identifier to understand if it's a local variable or function.
<whitequark>
however, if you add as much as one such command, you broke the whole system. now, you have *no idea* if "foo" is a variable or method; you need to look through *all* code which can be loaded by such command to determine it
<whitequark>
even worse if it's dynamic (e.g. accepts filename from command line); then it is simply not possible.
pskosinski has joined #ruby-lang
MaddinXx_ has quit [Remote host closed the connection]
cirwin has joined #ruby-lang
torrieri has joined #ruby-lang
cirwin has quit [Ping timeout: 240 seconds]
torrieri has quit [Ping timeout: 248 seconds]
sepp2k has joined #ruby-lang
<yorickpeterse>
I gave up on the Alpino shit
philnyc has joined #ruby-lang
<yorickpeterse>
it doesn't even work with Tcl/tk 8.6 apparently
<yorickpeterse>
and I can't install 8.4 since that conflicts
<whitequark>
dat conflicts
verto has joined #ruby-lang
jstorimer has joined #ruby-lang
umttumt has quit [Remote host closed the connection]
slipdigital has quit [Remote host closed the connection]
jstorimer has quit [Ping timeout: 240 seconds]
slipdigital has joined #ruby-lang
Domon has quit [Remote host closed the connection]
vlad_starkov has joined #ruby-lang
ldnunes has joined #ruby-lang
Aaaarg has quit [Ping timeout: 264 seconds]
jxie has quit [Quit: leaving]
jstorimer has joined #ruby-lang
vlad_starkov has quit [Read error: Operation timed out]
tRAS has quit [Quit: Mother, did it need to be so high?]
enaqx has joined #ruby-lang
kvs has quit [Read error: Connection reset by peer]
Aaaarg has joined #ruby-lang
enaqx has quit [Client Quit]
enaqx has joined #ruby-lang
kvs has joined #ruby-lang
vlad_starkov has joined #ruby-lang
torrieri has joined #ruby-lang
vlad_starkov has quit [Remote host closed the connection]
vlad_starkov has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 248 seconds]
torrieri has quit [Ping timeout: 252 seconds]
jinie is now known as jinie_
jondot has joined #ruby-lang
barttenbrinke has quit [Remote host closed the connection]
elia has joined #ruby-lang
yalue has joined #ruby-lang
cirwin has joined #ruby-lang
torrieri has joined #ruby-lang
jondot has quit [Ping timeout: 268 seconds]
cirwin has quit [Ping timeout: 268 seconds]
mossplix has quit [Quit: mossplix]
TvL2386 has joined #ruby-lang
jondot has joined #ruby-lang
s0ber has quit [Ping timeout: 240 seconds]
torrieri has quit [Ping timeout: 240 seconds]
Criztian has quit [Remote host closed the connection]
slipdigital has quit [Remote host closed the connection]
<zzak_>
hi
carloslopes has joined #ruby-lang
jxpx777 has quit [Quit: Leaving...]
_elia has joined #ruby-lang
skyronic has joined #ruby-lang
elia has quit [Read error: Operation timed out]
krames has joined #ruby-lang
elia has joined #ruby-lang
vlad_starkov has quit [Write error: Broken pipe]
ebouchut has joined #ruby-lang
_elia has quit [Read error: Operation timed out]
torrieri has joined #ruby-lang
ffio has joined #ruby-lang
matthewd has quit [Ping timeout: 245 seconds]
_elia has joined #ruby-lang
thiagoborges has joined #ruby-lang
matthewd has joined #ruby-lang
torrieri has quit [Ping timeout: 256 seconds]
elia has quit [Read error: Operation timed out]
hashkey has quit [Ping timeout: 264 seconds]
hashkey has joined #ruby-lang
vlad_starkov has joined #ruby-lang
hashkey is now known as Guest82425
<yorickpeterse>
TIL HTTPClient basically converts {:foo => [10]
<yorickpeterse>
}
<yorickpeterse>
to
<yorickpeterse>
{:foo => "10"}
w00x has joined #ruby-lang
<yorickpeterse>
BECAUSE THAT MAKES TOTAL SENSE
breakingthings has joined #ruby-lang
Weems has quit [Ping timeout: 260 seconds]
slipdigital has joined #ruby-lang
elia has joined #ruby-lang
asellus1 has quit [Quit: WeeChat 0.4.0]
asellus has joined #ruby-lang
jstorimer has quit [Remote host closed the connection]
dhruvasagar has joined #ruby-lang
JpC0utur3 has quit [Ping timeout: 264 seconds]
asellus has quit [Client Quit]
JpC0utur3 has joined #ruby-lang
zavier has joined #ruby-lang
_elia has quit [Ping timeout: 252 seconds]
Daniel has joined #ruby-lang
wmoxam has joined #ruby-lang
Daniel has quit [Remote host closed the connection]
Daniel has joined #ruby-lang
Daniel is now known as Guest60506
bgant has joined #ruby-lang
Guest60506 has quit [Client Quit]
hogeo has quit [Remote host closed the connection]
<apeiros>
so you either have the wrong code loaded/edited
<apeiros>
or something overrides your initialize
<apeiros>
also, you're aware that you can simply do: `case model; when Post …` ?
mistym has joined #ruby-lang
torrieri has quit [Ping timeout: 248 seconds]
<cored>
apeiros: did not know that, will change it
elia has quit [Ping timeout: 252 seconds]
<cored>
the wrong code loaded, let me check
nathanstitt has joined #ruby-lang
enebo has joined #ruby-lang
io_syl has joined #ruby-lang
elia has joined #ruby-lang
<apeiros>
or your exception is about another piece of code :)
<cored>
apeiros: I set a pry binding before the PictureExhibit cal
<cored>
and whe I tried to initialize the object I get the same error
<cored>
on another note there is no other piece of code defining that class
<cored>
so there's just last explanation 'something is overriding my initialize'
<cored>
which really I don't get how that could happen
_elia has quit [Ping timeout: 252 seconds]
bin7me has joined #ruby-lang
vlad_starkov has joined #ruby-lang
cofin has quit [Quit: cofin]
smook4 has joined #ruby-lang
mytrile has quit [Remote host closed the connection]
robbyoconnor has joined #ruby-lang
vlad_starkov has quit [Remote host closed the connection]
_elia has joined #ruby-lang
cofin has joined #ruby-lang
ditto572 has quit [Remote host closed the connection]
elia has quit [Ping timeout: 252 seconds]
jondot has quit [Ping timeout: 252 seconds]
jondot has joined #ruby-lang
enaqxx has joined #ruby-lang
enaqx has quit [Read error: Connection reset by peer]
GarethAdams has quit [Read error: Connection reset by peer]
<cored>
apeiros: found the problem, it was my spec_helper I'm stubbing classes that doesn't exist and I was stubbing that two classes so they were already loaded when I get there so the constructor did not exist, thanks
elia has joined #ruby-lang
<yorickpeterse>
so....can anybody recommend a library for processing xslt files?
<yorickpeterse>
(I'm not doing drugs)
_elia has quit [Ping timeout: 252 seconds]
<whitequark>
libxslt
<whitequark>
also you do.
<yorickpeterse>
I'm not :<
<yorickpeterse>
I have tea
torrieri has joined #ruby-lang
_elia has joined #ruby-lang
torrieri has quit [Ping timeout: 252 seconds]
elia has quit [Read error: Operation timed out]
wallerdev has joined #ruby-lang
diddlybop has quit [Ping timeout: 268 seconds]
mikewintermute has joined #ruby-lang
jondot has quit [Ping timeout: 252 seconds]
pskosinski has quit [Ping timeout: 240 seconds]
jondot has joined #ruby-lang
pskosinski has joined #ruby-lang
elia has joined #ruby-lang
tomzx_mac has quit [Ping timeout: 248 seconds]
GarethAdams has joined #ruby-lang
_elia has quit [Ping timeout: 252 seconds]
<ericwood>
lol xslt
<ericwood>
who the fuck thought XSLT was a good idea?
<ericwood>
I want to know
<bgant>
probably people who thought Lotus Notes and XML databases were a good idea
TvL2386 has quit [Quit: Ex-Chat]
<whitequark>
ericwood: W3C?
cirenyc has joined #ruby-lang
<ericwood>
ugh
enaqx has joined #ruby-lang
io_syl has quit [Quit: Computer has gone to sleep.]
<ericwood>
if I ever write XSLT for any reason, I'm relying on y'all to put me out of my misery
<ericwood>
deal?
hhatch has quit [Read error: Operation timed out]
_elia has joined #ruby-lang
Guest82425 is now known as hashkey
elia has quit [Ping timeout: 264 seconds]
torrieri has joined #ruby-lang
torrieri has quit [Changing host]
torrieri has joined #ruby-lang
slipdigital has quit [Ping timeout: 248 seconds]
<whitequark>
yea
<ericwood>
you better not wimp out
elia has joined #ruby-lang
<yorickpeterse>
apparently nokogiri does it too
pipework has quit [Remote host closed the connection]
torrieri has quit [Ping timeout: 245 seconds]
Aaaarg has quit [Ping timeout: 260 seconds]
_elia has quit [Ping timeout: 264 seconds]
ffio has quit [Quit: WeeChat 0.4.1]
GeissT has quit [Quit: MillBroChat AdIRC User]
<ericwood>
yeah, libxml2 supports it
wallerdev has quit [Quit: wallerdev]
Squarepy has quit [Remote host closed the connection]
Aaaarg has joined #ruby-lang
_elia has joined #ruby-lang
elia has quit [Ping timeout: 264 seconds]
havenwood has joined #ruby-lang
gnufied has quit [Quit: Leaving.]
cirenyc has quit [Quit: Leaving...]
swav has quit [Ping timeout: 268 seconds]
jMCg has joined #ruby-lang
<jMCg>
hello happy people o/~
<darix>
ericwood: libxslt supports it. which is used by nokogiri.
<ericwood>
ah yeah
swav has joined #ruby-lang
marcostoledo has quit [Ping timeout: 255 seconds]
DomKM has joined #ruby-lang
mikewintermute has quit [Quit: mikewintermute]
elia has joined #ruby-lang
<cout>
jMCg: happy _shiny_ people
<ericwood>
yes
workmad3 has joined #ruby-lang
marcostoledo has joined #ruby-lang
gregmoreno has quit [Remote host closed the connection]
anonymuse has quit [Remote host closed the connection]
cofin has joined #ruby-lang
gregmoreno has joined #ruby-lang
jstorimer has joined #ruby-lang
andrewvos has quit [Ping timeout: 240 seconds]
towski has joined #ruby-lang
w00x has quit [Ping timeout: 255 seconds]
tkuchiki has joined #ruby-lang
jstorimer has quit [Remote host closed the connection]
krohrbaugh has quit [Quit: Leaving.]
justinmburrous has joined #ruby-lang
pbjorklund has quit [Read error: Operation timed out]
tkuchiki has quit [Ping timeout: 276 seconds]
dhruvasagar has joined #ruby-lang
tylergillies has joined #ruby-lang
barttenbrinke has quit [Remote host closed the connection]
pipework has quit [Remote host closed the connection]
<tylergillies>
im trying to catch an exception in a library. the library uses a foo(bar) do |biz| whatever; end paradigm. It's raising an exception but i can't catch it by wrapping that callback with begin/rescue
<tylergillies>
anyone have any ideas on how to solve that?
pipework has joined #ruby-lang
dan|el has left #ruby-lang [#ruby-lang]
pbjorklund has joined #ruby-lang
cofin has quit [Quit: cofin]
Pupeno has joined #ruby-lang
Pupeno has joined #ruby-lang
Pupeno has quit [Changing host]
krohrbaugh has joined #ruby-lang
krohrbaugh has quit [Client Quit]
krohrbaugh has joined #ruby-lang
cirenyc has joined #ruby-lang
cirenyc has left #ruby-lang [#ruby-lang]
Pupeno has quit [Ping timeout: 264 seconds]
justinram has joined #ruby-lang
mrsolo has joined #ruby-lang
cirwin has joined #ruby-lang
JpC0utur3 has quit [Ping timeout: 240 seconds]
JpC0utur3 has joined #ruby-lang
philnyc_ has quit [Remote host closed the connection]
elia has joined #ruby-lang
brianpWins has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 255 seconds]
<bgant>
tylergillies: where is the exception being raise? in the foo(bar) call or in the do / end block?
<drbrain>
jMCg: include only adds instance methods to the ancestors list
<drbrain>
so is_absolute? does not exist in the scope you're calling from (module function)
bzalasky has joined #ruby-lang
tkuchiki has joined #ruby-lang
<jMCg>
drbrain: what does "to the ancestors list" mean?
<drbrain>
jMCg: the ancestors list is what ruby walks when it is looking up methods
lcdhoffman has quit [Quit: lcdhoffman]
<drbrain>
so in my example when you call C#a it first looks in C, finds nothing, then in B, finds an implementation
tomzx_mac has joined #ruby-lang
<drbrain>
then B supers so it goes next to A and finds an implementation
<jMCg>
aah.. I think I remember this from nuklearsandwich's talk.
<jMCg>
He explained ruby for beginners by how its OOP works.
<jMCg>
Which was really enlightening, and it also reminded me a lot of Lua..
tkuchiki has quit [Ping timeout: 276 seconds]
lcdhoffman has joined #ruby-lang
<jMCg>
drbrain: let me see if I can simplify my example and retrace it
<drbrain>
jMCg: your problem is trying to call a method you added via include from a method that is "def self."
<drbrain>
you can use extend instead to make it work like you expect or you can call it directly
<jMCg>
drbrain: as in: Foo::Bar.method?
<drbrain>
yes
<drbrain>
I should have probably said something like "fully qualified" or "complete namespace"
<jMCg>
Such a novel concept! I even use it in File.join, I wonder why I didn't think of that..
<drbrain>
oh, I missed a detail
<drbrain>
you'll need to module_function :is_absolute? where you define it for the full name to work
<jMCg>
Do share, please!
lcdhoffman has quit [Client Quit]
<jMCg>
hmm?
joshuawscott has joined #ruby-lang
* jMCg
looks that up in the docs
<drbrain>
I'm guessing R10K::Util::Path is bundle of utility methods
<drbrain>
… methods that you send all the necessary arguments to
<drbrain>
so module_function makes the instance method private and makes a class method copy
<drbrain>
this allows you to use parts of the functionality from methods like R10K::Module::new without extending the …::Path atop R10K::Module (which I think is cleaner)
mbj has quit [Ping timeout: 268 seconds]
lcdhoffman has joined #ruby-lang
mrsolo has quit [Quit: Leaving]
<jMCg>
drbrain: R10K::Util::Path is, like you say, a utility module, I don't quite see how making the instance methods private helps that.
GarethAdams has quit [Read error: Connection reset by peer]
<drbrain>
it's the class method copy that is the important part
<drbrain>
being private is a side effect that shouldn't bother your use
dingus_khan has quit [Remote host closed the connection]
brianpWins has quit [Quit: brianpWins]
justinram has quit [Remote host closed the connection]