Topic for #ruby-lang is now Ruby 1.9.3p0: http://ruby-lang.org | Paste >3 Lines of Text on http://pastie.org
d4mi3n has joined #ruby-lang
achiu has joined #ruby-lang
<zenspider> Stalkr_: apparenly not :P
flowerpot has joined #ruby-lang
<zenspider> anyone here a graphviz wiz?
Nisstyre has joined #ruby-lang
andkerosine has quit [#ruby-lang]
amerine has joined #ruby-lang
replore has joined #ruby-lang
twittard has joined #ruby-lang
looopy has joined #ruby-lang
oddmunds has joined #ruby-lang
<Stalkr_> zenspider: Didn't bother, the chat seemed rather dead :P
Fighterr has joined #ruby-lang
<zenspider> could be dead because nobody is asking any questions...
<Fighterr> hello..
<Fighterr> i got some errors . anybody help me~!
<Stalkr_> Oh well, I have one -- do you have any experience with .gif/image exporting?
dv310p3r has joined #ruby-lang
<zenspider> Fighterr: that's rather vague. fix the errors. they go away after that.
<zenspider> or ask a better question
<zenspider> Stalkr_: I don't know what that means. exporting how?
<Fighterr> zen: i installed couchrest by rubygem, but when i insert this statement that is "require 'couchrest'". i got this error
<Fighterr> ruby couch_connect.rb │ insert this statement that is "require │
<Fighterr> couch_connect.rb:1:in `require': no such file to load -- couchrest (LoadError) │ 'couchrest'". i got this error │ from couch_connect.rb:1
<Stalkr_> Fighterr: use http://pastie.org/
<Spooner> Fighterr: require 'rubygems' # before other gems, if on 1.8.7
<Fighterr> Spooner : It's working , thanQ
<Spooner> Fighterr: Perhaps an odd question, but why start using Ruby 1.8.7 rather than 1.9.2? I can understand why people stay on 1.8.7, because of legacy code.
<zenspider> because it works better
<Spooner> It does? Even after all this time?
<zenspider> what does time have to do with it?
<zenspider> Stalkr_: I'd prolly poke at something like imagemagick/rmagick or ffmpeg... prolly the latter first because imagemagick is such a bitch to deal with
<zenspider> omg... graphviz is STILL rendering :(
Nisstyre has joined #ruby-lang
<Spooner> Well, I wouldn't recommend 1.9.3 to anyone, because it is not mature, but 1.9.2 is hardly bleeding edge.
<Stalkr_> ffmpeg with Ruby or how? Not sure what it is
<Fighterr> Spooner : in my case , my ec2's instance provides 1.8.7 by yum installer...
<Spooner> Ah, I was wondering if it was the OSX having 1.8.7 bundled in. Yeah, I guess that makes sense.
<zenspider> I still use stock ruby on my mac... works great.
<Spooner> (That is, in making distribution to non-ruby people easier, rather than a boon for the developer directly).
<zenspider> I only use 1.9.x for compatibility testing
takaokouji has joined #ruby-lang
<Spooner> I must admit that 1.9.2 load times were a joke on Windows, so I am incredibly thankful for 1.9.3 and probably should have used 1.8.7 longer myself :)
<zenspider> or not used windows...
<Spooner> I did run tests in my Linux VM because even in a VM they were faster :)
rushed_ has joined #ruby-lang
havenn has joined #ruby-lang
ec2-user has joined #ruby-lang
jtoy has joined #ruby-lang
<WillMarshall> Anyone know where I can learn in more detail about the execution order of include, extend and the Class callbacks in Ruby?
<WillMarshall> I'm trying to learn how to be clever with dynamically loaded modules at runtime, I've got everything working fine but I'd like to solidify my understanding of exactly how it all works
jakko has joined #ruby-lang
tyfighter has joined #ruby-lang
neoesque has joined #ruby-lang
<zenspider> WillMarshall: execution order?
<WillMarshall> zenspider: What get included when where
srbaker has joined #ruby-lang
<WillMarshall> Which order the callbacks run, etc
<WillMarshall> e.g. if I'm dynamically creating classes and assigning them to constants, which callbacks will let me access the class_name and which won't?
<injekt> throw some statements in the hook methods?
<zenspider> include is just a method call. so it happens when it happens...
<zenspider> assignment (lhs = rhs) requires rhs to be defined, and the inherited callback happens when something is inherited, so assignment won't have happened yet
twittard has joined #ruby-lang
<zenspider> there's very little magic involved ... it should be pretty straight-forward top-to-bottom evaluation
<zenspider> minitest 2.11.2 released
<injekt> changes!
<zenspider> I love my release process
<zenspider> takes ~2 minutes to prep the history, bump, commit, package, push, push doco, announce to blog, and announce to email
<injekt> and announce to irc
<injekt> i'm boring and just rake release
<zenspider> that's all I'm doing
<zenspider> p4 changelog newversion today | pbcopy
<injekt> yeah, mine just doesn't do the announcements is what i mean
<injekt> ala boring
<zenspider> put that in the history file, update my VERSION const, commit, rake release VERSION=newversion
<andrewvos> oh hai
neoesque has joined #ruby-lang
<injekt> o/
srbaker has joined #ruby-lang
<andrewvos> \o
<andrewvos> injekt: Your idea for that songs site has resulted in more amazing music than I ever could have imagined, by the way.
<injekt> <3
<andrewvos> You have made my life a lot better. Well played Sir.
<schlecht> injekt is pure genius.
<andrewvos> Indeed
cored has joined #ruby-lang
cored has joined #ruby-lang
<cored> hello all
<cored> I have a question
<cored> how can I opening a class and over writting a method on that class
lightcap has joined #ruby-lang
<cored> call the old implementation the default one before my implementation?
<andrewvos> class Bla; def method; end;end;
<andrewvos> cored: ^^^^
<injekt> cored: use a method lias
<injekt> alias
<cored> yes
<cored> that's the anser
<cored> injekt: thanks
<injekt> sure
<injekt> andrewvos: so, lots and lots of toonz?
<andrewvos> injekt: YES
<injekt> :D
<andrewvos> Heard some weird new bands. Tomorrow I'm going to give a lot of my friends commit rights and see what happens. Mostly it will be lemonparty I think, but I'm sure some good songs will be added :)
<injekt> lol
<andrewvos> heh
<andrewvos> Ok night everyone
<cored> don't see the need of this
<cored> I'm starting to think to compose behaviour from a module is way better
<andrewvos> cored: The need of what?
<cored> I mean for my implementation sorry
<andrewvos> SOLID
<cored> it doesn't look right to open a class
<andrewvos> cored: ^^
<injekt> it's usually not
<andrewvos> Yeah what he said
<andrewvos> Ok not getting dragged into everything
<andrewvos> Night xx
<schlecht> andrewvos: code
<injekt> andrewvos: gn!
<andrewvos> schlecht: huh?
<injekt> he's saying dont sleep
<injekt> code
<schlecht> No I'm not
<injekt> no he's not
<andrewvos> he's not
<injekt> but i am
<injekt> !
<schlecht> 20:27 < andrewvos> You have made my life a lot better. Well played Sir.
<andrewvos> hehe
<schlecht> code to whatever that's referring to.
<andrewvos> schlecht: What's your point brohan sebastian bach
<andrewvos> schlecht: fuckingawesomesongs.com
<schlecht> Goodnight then.
<andrewvos> schlecht: Submit a cool song in a pull request = permanent commit rights
<schlecht> That's PG18.
<andrewvos> New rule
<schlecht> I hate git.
<andrewvos> Ok night
<injekt> git <3
<andrewvos> schlecht: AHHH NOOO GIT IS LOVELY
<injekt> andrewvos: you suck at sleep, might as well give up
<andrewvos> :(
<zenspider> schlecht: yay!
<injekt> I have!
Dreamer3 has joined #ruby-lang
<schlecht> Can I put Pimp C ?
<injekt> zenspider: nooo
<andrewvos> Have to do an interview tomorrow though
<schlecht> zenspider: Die, cvs user.
<ec2-user> Come down man~
<injekt> LOL
<injekt> andrewvos: ouch
<injekt> andrewvos: local?
<zenspider> bah. I use perforce
<andrewvos> injekt: Well, in the same company
<schlecht> I have to go to school tomorrow.
<injekt> andrewvos: ahh
<andrewvos> injekt: But More money
<andrewvos> So yay
<injekt> andrewvos: itv right?
<injekt> or bbc
<andrewvos> Nope BBC
<injekt> word
<andrewvos> Left ITV like 7 months ago
<andrewvos> How do you know all this :)
<schlecht> andrewvos: Dream Theater - Through Her Eyes: http://www.youtube.com/watch?v=SjINXbJ3vdo
<injekt> rival company, nice
<injekt> eh, i dunno
Indian has joined #ruby-lang
<injekt> I remember you working at itv
<injekt> i dont speak to many london based rubyists so usually remember when I do :)
looopy has joined #ruby-lang
<andrewvos> schlecht: I seem to remember denying that pull request :|
<andrewvos> injekt: You're in london
<andrewvos> ?
<schlecht> andrewvos: For Pimp C or Dream Theater?
<andrewvos> schlecht: Dream Theater
<injekt> andrewvos: not right now, but I come from london and spend most of my time there
<schlecht> andrewvos: Ah, not my sort of music anyway.
<injekt> andrewvos: I live in basingstoke right now, until I head to canada again (possible)
<deryl> thus the k for the c
* deryl runs
kurko_ has joined #ruby-lang
<andrewvos> injekt: Ok well if you're looking to do some ruby it would be nice to work with you (probably). Msg me :)
<andrewvos> Anyway, I'm really leaving now.. Night everyone x
<injekt> andrewvos: you do much ruby at bbc? oO
<injekt> psh
<epitron> hey, i'm trying to do somethign sneaky, and i'm too tired to figure it out. :) I wanted to make Proc#* repeatedly apply a proc to itself.... similar to object.method.method.method.method
<epitron> i feel like Proc#curry is involved
<injekt> epitron: 'apply a proc to itself'?
<epitron> yeah
<andrewvos> injekt: Yes, a lot of ruby
<epitron> like, say you have proc { |n| n + 1 }
<injekt> andrewvos: interesting
<andrewvos> injekt: And I've heard there are some rubyist needed
<epitron> that proc * 5 would be: proc.call ( proc.call ( proc.call ( proc.call ( ... ) ) ) )
<epitron> err.. 5 times :)
<epitron> i suppose it doesn't have to be recursive
<epitron> curry is neat though :)
<ec2-user> Hello ?
<ec2-user> Anyone ?
<injekt> epitron: how would you even pass args to it?
<epitron> well, proc*5 returns a proc
<epitron> (proc*5).call arg
<injekt> eh
<injekt> ec2-user: hello
<epitron> that works
lordofthedance has joined #ruby-lang
gix has joined #ruby-lang
<ec2-user> hello
<ec2-user> helllo
<ec2-user> ?
<ec2-user> anaybody here ?
<injekt> ec2-user: yes
<injekt> ec2-user: there are 362 other users here
<ec2-user> injekt : pretty funny ;)
<ec2-user> i got some warning messages when i execute ruby
<ec2-user> injekt : Warning: multi_json is using default ok_json engine. Suggested action: require and load an appropriate JSON│ quit [Ping timeout: 245 seconds] │01:54 < �ϴ���> 아.. 작년지진때 library.
Luxx_ has joined #ruby-lang
<ec2-user> inkekt : i wonder thatwhy this message is appeared ?
<schlecht> gem install json
chessguy has joined #ruby-lang
ahs3- has joined #ruby-lang
<ec2-user> schlencht : and then ?
<injekt> try try again
<schlecht> ec2-user: quit irc.
lordofth1dance has joined #ruby-lang
<ec2-user> schlecht : is that a joke ?
<schlecht> It requires you to install drivers this way.
<ec2-user> but the warning is about load library , not just installing
<schlecht> You need to install it to load it, silly.
<schlecht> The only way to install drivers is to reboot your machine.
<schlecht> So you need to quit irc.
<ec2-user> r u kidding me ?
<schlecht> Nope
<schlecht> It's all in the stuxnet headers.
<zenspider> schlecht: try not to be too much of an asshole
<ec2-user> to install by gem is not involved rebooting
<schlecht> ec2-user: Then stop asking silly questions, and install the gem.
BadQuanta has joined #ruby-lang
<ec2-user> schlecht : u r really man
<chessguy> ec2-user: that's what she said
<zenspider> ec2-user: installing the gem is the correct answer.
<injekt> +1 for installing the gem
dous has joined #ruby-lang
<chessguy> hey, why don't you try installing the gem? ( i have no idea what you guys are talkign about)
<ec2-user> but i don't need to reboot my machine
<injekt> what does this have to do with rebooting?
<injekt> did you install the gem?
<schlecht> Probably not.
<ec2-user> yes
<injekt> and did you run it again?
<ec2-user> no..
<ec2-user> yet installing
<injekt> so... run it again?
<ec2-user> my ec instance speed is suck
<schlecht> I managed to fully confuse this person beyond reasonable doubt.
<schlecht> I feel slightly guilty.
bglusman has joined #ruby-lang
<ec2-user> schlecht : hey , cheer up
<schlecht> Guilt gone.
<ec2-user> um.....
<ec2-user> i thinkt that the gem's server(") is pretty slow
<ec2-user> schlecht : may i get the reason from you ?
kurko_ has quit ["Saindo"]
<schlecht> Huh?
<schlecht> Wed Feb 15 04:17:30 EET 2012
Heimidal has joined #ruby-lang
<schlecht> Night.
<ec2-user> schlecht : you in germany ?
<schlecht> Yes, Germany is EET.
<ec2-user> schlecht : i'm sorry that here is in south korean
<ec2-user> schlecht : in the daytime
<ec2-user> installing still continue
havenn has joined #ruby-lang
achiu has joined #ruby-lang
SuperTaz_work has joined #ruby-lang
seanstickle has joined #ruby-lang
srbaker has joined #ruby-lang
MistyM_ has joined #ruby-lang
chimkan_ has joined #ruby-lang
oddmunds_ has joined #ruby-lang
srbaker has joined #ruby-lang
tomzx has joined #ruby-lang
hagabaka has joined #ruby-lang
hagabaka has joined #ruby-lang
hagabaka has joined #ruby-lang
hagabaka has joined #ruby-lang
Banistergalaxy has joined #ruby-lang
Banistergalaxy has joined #ruby-lang
hagabaka has joined #ruby-lang
hagabaka has joined #ruby-lang
hagabaka has joined #ruby-lang
fayimora_ has joined #ruby-lang
uniqanomaly has joined #ruby-lang
hagebake has joined #ruby-lang
hagebake has joined #ruby-lang
chimkan has joined #ruby-lang
<slyphon> soo sinatra, yeah?
<slyphon> '/foo/:bar/baz/:spam' doesn't seem to parse out like how i think it should
hagebake_ has joined #ruby-lang
havenn has joined #ruby-lang
HW42_ has joined #ruby-lang
havenn has joined #ruby-lang
chimkan has joined #ruby-lang
kp666 has joined #ruby-lang
<jtoy> is there a safe way to get the name of the current method I am in?
elux has joined #ruby-lang
erpuds has joined #ruby-lang
guns has joined #ruby-lang
sinuc has joined #ruby-lang
sinuc has joined #ruby-lang
rippa has joined #ruby-lang
hagebake has joined #ruby-lang
xjiujiu has joined #ruby-lang
Karmaon has joined #ruby-lang
scyrmion has joined #ruby-lang
kke has joined #ruby-lang
nacengineer has joined #ruby-lang
yfeldblum has joined #ruby-lang
TheMoonMaster has joined #ruby-lang
TheMoonMaster has joined #ruby-lang
dv310p3r has joined #ruby-lang
werwolf has joined #ruby-lang
Luxx_ has joined #ruby-lang
nofxx has joined #ruby-lang
nofxx has joined #ruby-lang
jorgenpt has joined #ruby-lang
corsican has joined #ruby-lang
havenn has joined #ruby-lang
gokul has joined #ruby-lang
twittard has joined #ruby-lang
sideshownz has joined #ruby-lang
anthony has joined #ruby-lang
hagebake has joined #ruby-lang
achamian has joined #ruby-lang
srbartlett has joined #ruby-lang
robbyoconnor has joined #ruby-lang
macmartine has joined #ruby-lang
<zenspider> jtoy: why would you want to do that?
<jtoy> zenspider: i am using your mintiest :) with vcr, so every single one of my tests consists of def test_long_name; VCR(same_name_as_test_name) do ….end; end
<jtoy> I'm getting sick of writing the name twice for every test
<zenspider> get a better editor?
<erikh> maaaaacrroooooooos
<zenspider> tho in the case like that, you can use minitest
<zenspider> __name__ is the name of your test
<erikh> oh that's hot
<zenspider> but really... get a better editor :P
wyhaines has joined #ruby-lang
<jtoy> zenspider: yeah, i could do completion too, I'm using vim, hard to beat that :) but i'll use __name__ for now
<jtoy> thx!
MistyM_ has joined #ruby-lang
<zenspider> emacs beats it :P
<rippa> functional programming in javascript is painfuk
<rippa> *l
<rippa> *ck
<zenspider> haha
<zenspider> both
<erikh> painfuck: purely functional bf
hagebake_ has joined #ruby-lang
brownies has joined #ruby-lang
<hagebake_> rippa: why do you say that? in javascript function programming doesn't make the syntax worse than it is usually, but in ruby, if you want to pass multiple functions or one not as the last paramter, you get ugly-looking code.
Heimidal has joined #ruby-lang
<rippa> in JS syntax is already ugly
<rippa> and passing functions requires even more of it
hagabaka has joined #ruby-lang
<hagabaka> but the ugliness doesn't result from functional programming
<hagabaka> in ruby if you wanted to pass two anonymous functions in a function call, you would have to either wrap do...end in parentheses, or enclose a multi-line block with { }, which is uglier than "normal" ruby code or javascript
<rippa> how is that uglier than javascript?
<rippa> it alreade uses {} for all blocks
gja has joined #ruby-lang
znz_jp has joined #ruby-lang
gja has joined #ruby-lang
<zenspider> hagabaka: in other words, if you want to bypass ruby's syntax for a single block pass, you have to make the code look like javascript?
tejas has joined #ruby-lang
sinuc has joined #ruby-lang
<hagabaka> worse than javascript
tejas has quit [#ruby-lang]
<hagabaka> since it's inconsistent with regular ruby syntax
<zenspider> saying lambda {} is basically the same as function () {}
gja has joined #ruby-lang
<rippa> puts(lambda {1}, lambda {2})
<rippa> looks fine to me
<zenspider> lambda {} is not inconsistant with ruby's syntax considering it IS ruby's syntax (well... api, really)
gja has joined #ruby-lang
gja has joined #ruby-lang
<hagabaka> I'm not talking about the use of {} itself, but the inconsistency
<rippa> where?
gja has joined #ruby-lang
gja has joined #ruby-lang
<rippa> you always pass anonymous function with lambda {} or Proc.new {}
<hagabaka> of course it's *valid* ruby, but it's ugly since usually multi-line blocks would be in do..end instead of {}
<rippa> hagabaka: that's your preference
<zenspider> I was just about to say that
<zenspider> I don't have that rule... you do
<zenspider> I use the weirich method... works much better for me
<hagabaka> well if you don't follow certain style guidelines, nothing stops ruby from being uglier than javascript, whether there's functional programming involved
<hagabaka> what I mean is basically that if you program in javascript in the first place, { } and ; are already a given. javascript with functional programming looks about the same as without it
<hagabaka> and other than syntax, I don't see what to complain about javascript regarding functional programming either
X99 has joined #ruby-lang
sinuc has joined #ruby-lang
<zenspider> hrm... doesn't work :( words.with_index.each_cons(2) do |(a, ia), (b, ib)|
<zenspider> what's a good way to do that?
<zenspider> rippa: fwiw... I totally agree
<rippa> zenspider: each_with_index
<rippa> with_index is for enumerators only
X99 has joined #ruby-lang
<WillMarshall> How can I get the child classes of a parent class?
<rippa> WillMarshall: using ObjectSpace
tekin has joined #ruby-lang
<rippa> WillMarshall: ObjectSpace.each_object(Class).select {|c| c.ancestors.include? String}
kitallis has joined #ruby-lang
achiu has joined #ruby-lang
<WillMarshall> rippa: Cheers dude
sinuc has joined #ruby-lang
banisterfiend has joined #ruby-lang
<banisterfiend> hey homies
don9z has joined #ruby-lang
<don9z> /join #java
dous has joined #ruby-lang
don9z has quit ["ERC Version 5.3 (IRC client for Emacs)"]
yxhuvud has joined #ruby-lang
thone has joined #ruby-lang
achamian has joined #ruby-lang
retro|cz has joined #ruby-lang
chimkan_ has joined #ruby-lang
achamian has joined #ruby-lang
looopy has joined #ruby-lang
|Vargas| has joined #ruby-lang
|Vargas| has joined #ruby-lang
sdeobald has joined #ruby-lang
kaiwren has joined #ruby-lang
banistergalaxy has joined #ruby-lang
segy has joined #ruby-lang
segy has joined #ruby-lang
headius has joined #ruby-lang
symm- has joined #ruby-lang
macmartine has joined #ruby-lang
srbaker has joined #ruby-lang
frangiz has joined #ruby-lang
mytrile has joined #ruby-lang
JohnBat26 has joined #ruby-lang
achamian_ has joined #ruby-lang
naz has joined #ruby-lang
achiu has joined #ruby-lang
fritzek has joined #ruby-lang
twittard has joined #ruby-lang
naz has joined #ruby-lang
sora_h has joined #ruby-lang
sora_h has joined #ruby-lang
achamian has joined #ruby-lang
solars has joined #ruby-lang
twittard has joined #ruby-lang
krz has joined #ruby-lang
dc5ala has joined #ruby-lang
banistergalaxy_ has joined #ruby-lang
ilyam has joined #ruby-lang
Taranis has joined #ruby-lang
jkprg has joined #ruby-lang
voker57 has joined #ruby-lang
voker57 has joined #ruby-lang
Oloryn_lt1 has joined #ruby-lang
EvilJStoker has joined #ruby-lang
zoot` has joined #ruby-lang
zoot` has quit ["ERC Version 5.3 (IRC client for Emacs)"]
kvs has joined #ruby-lang
stepnem has joined #ruby-lang
judofyr has joined #ruby-lang
roadkith has joined #ruby-lang
naz has joined #ruby-lang
<judofyr> RUBY RUBY
HW42 has joined #ruby-lang
cyri_ has joined #ruby-lang
<ddfreyne> aah aah ahahah aaaaaaaah
<yorickpeterse> Morning
<tobiasvl> do ya do ya do ya do ya
ilyam has joined #ruby-lang
gnufied has joined #ruby-lang
<judofyr> oh, Ilias is splendid: https://groups.google.com/forum/?fromgroups#!msg/comp.lang.lisp/3ExXYHxWRRQ/_IGbOEaAnWgJ
<erikh> rubbbbbby
<erikh> holy shit
<erikh> ilias and erik naggum face off
<erikh> OMFG.
<erikh> hot troll on troll action.
<zenspider> oh thank god... it's 10 years old... I thought he started up again
<tobiasvl> erik naggum is dead
<tobiasvl> so ...
<judofyr> tobiasvl: sorry I couldn't make it to the Ruby meetup btw :/
<zenspider> I was worried about ilias, not naggum
<tobiasvl> judofyr: your loss!
robotmay has joined #ruby-lang
<judofyr> tobiasvl: was it good?
<tobiasvl> it was okay
<tobiasvl> one presentation of a type of TDD in ruby and one that wasn't about ruby at all
<tobiasvl> cool people though
<judofyr> what was the non-Ruby thingie about?
<tobiasvl> PEOPLE
<zenspider> ew... people ruin everything
<judofyr> oh gosh
<tobiasvl> how people are an important asset in the software industry
<zenspider> justl look at the calendar system of any culture
<zenspider> except that french revolutionary decimal calendar... it was PERFECT
<chendo__> and swatch internet time
<zenspider> well... I invented swatch internet time in 1992... but having to scale timers to 86.4% was too hard to do
<judofyr> except they uses UTC+1…
zmack has joined #ruby-lang
<zenspider> I wanted to have no timezones
<zenspider> I learned an important lesson wrt that notebook of work... never let your GF do your laundry.
roha has joined #ruby-lang
<chendo__> so guys, i have a method that sends a call to a remote transport
<chendo__> and i want it to block and wait for a response
<chendo__> but i'd like the communication layer to be asynchronous/multithreaded
<chendo__> so the transport layer can send and receive other requests at the same time
<chendo__> would i want to use fibers or threads?
<chendo__> i can't use any middleware (AMQP, zeromq, etc)
<chendo__> i think at most i can use EM
QaDeS has joined #ruby-lang
<chendo__> ideas?
<chendo__> oh yeah, and if it's threads i should look into, what mechanism should i use to block?
<chendo__> create an IO object for each call and IO.select on that doesn't sound fantastic
Fullmoon has joined #ruby-lang
Oloryn_lt1 has joined #ruby-lang
futurechimp has joined #ruby-lang
sideshownz has joined #ruby-lang
HW42 has joined #ruby-lang
twelvechairs has joined #ruby-lang
charper has joined #ruby-lang
fayimora has joined #ruby-lang
S2kx has joined #ruby-lang
tbuehlmann has joined #ruby-lang
NARKOZ has joined #ruby-lang
lsegal has joined #ruby-lang
kke has joined #ruby-lang
theoros has joined #ruby-lang
deadbea7 has joined #ruby-lang
setmeaway2 has joined #ruby-lang
roha has joined #ruby-lang
Dreamer3 has joined #ruby-lang
basicxman has joined #ruby-lang
basicxman has joined #ruby-lang
zvrba has joined #ruby-lang
JoL1hAHN has joined #ruby-lang
dabradley has joined #ruby-lang
HW42 has joined #ruby-lang
jkprg has joined #ruby-lang
naz has joined #ruby-lang
S1kx has joined #ruby-lang
S1kx has joined #ruby-lang
sideshownz has joined #ruby-lang
ramonmaruko has joined #ruby-lang
lianj has joined #ruby-lang
lianj has joined #ruby-lang
brownies has joined #ruby-lang
My_Hearing has joined #ruby-lang
tla__ has joined #ruby-lang
<judofyr> very interesting to see tarcieri implementing Erlang on top of Ruby: https://github.com/tarcieri/celluloid
gjaldon has joined #ruby-lang
<shevy> cool
<shevy> oh that README has a cool quote too
<shevy> '"I thought of objects being like biological cells and/or individual computers on a network, only able to communicate with messages" --Alan Kay, creator of Smalltalk, on the meaning of "object oriented programming"'
<shevy> he is right!
<shevy> of course every cell needs to be organized like a mini-CPU too (with its "genome" and one needs to have the ability to modify this "genome" at run-time)
Asher1 has joined #ruby-lang
jakko has joined #ruby-lang
beiter has joined #ruby-lang
havenn has joined #ruby-lang
banistergalaxy_ has joined #ruby-lang
krz has joined #ruby-lang
krz has joined #ruby-lang
<banistergalaxy_> hey frens
<judofyr> hey banistergalaxy_
<judofyr> you're galaxy today?
fayimora has joined #ruby-lang
<banistergalaxy_> judofyr: fo shizzle, banisterfiend is banned
<banistergalaxy_> ;)
<judofyr> huh?
<shevy> still???
<banistergalaxy_> yeah
<shevy> one thing to have in common with RubyPanther!
<shevy> :>
<banistergalaxy_> haha yeah i guess
<banistergalaxy_> judofyr: wat up
bow777 has joined #ruby-lang
<bow777> 56421
<bow777> hi there
bow777 has quit [#ruby-lang]
<shevy> that's an odd way to count
achamian has joined #ruby-lang
krz has joined #ruby-lang
HW42 has joined #ruby-lang
roadkith has joined #ruby-lang
toretore has joined #ruby-lang
CodeBlock has joined #ruby-lang
chimkan__ has joined #ruby-lang
chimkan__ has joined #ruby-lang
Stalkr_ has joined #ruby-lang
Defusal_ has joined #ruby-lang
Karmaon has joined #ruby-lang
wyhaines has joined #ruby-lang
Stalkr_ has joined #ruby-lang
tekin has joined #ruby-lang
spuk has joined #ruby-lang
Fullmoon has joined #ruby-lang
roadkith has joined #ruby-lang
senthil has joined #ruby-lang
jakko_ has joined #ruby-lang
mark_locklear has joined #ruby-lang
tomzx has joined #ruby-lang
ryez has joined #ruby-lang
yalue has joined #ruby-lang
jxie has joined #ruby-lang
jxie has joined #ruby-lang
MistyM_ has joined #ruby-lang
havenn has joined #ruby-lang
Spooner has joined #ruby-lang
dmathieu has joined #ruby-lang
tekin has joined #ruby-lang
codewrangler has joined #ruby-lang
fritzek has joined #ruby-lang
judofyr has joined #ruby-lang
MistyM_ has joined #ruby-lang
fritzek_ has joined #ruby-lang
fayimora has joined #ruby-lang
fritzek_ has joined #ruby-lang
Sailias has joined #ruby-lang
yfeldblum has joined #ruby-lang
divoxx has joined #ruby-lang
dfr|mac has joined #ruby-lang
robbrit has joined #ruby-lang
Oloryn_lt1 has joined #ruby-lang
tekin has joined #ruby-lang
looopy has joined #ruby-lang
Xzyx987X has joined #ruby-lang
jtoy has joined #ruby-lang
malev has joined #ruby-lang
Indian has joined #ruby-lang
bglusman has joined #ruby-lang
malev has joined #ruby-lang
<ryez> so silent here today? because v-day was too exaustive?
<ryez> or people are still enjoying it?
<ryez> :-D
<robbrit> it's early still
niklasb has joined #ruby-lang
<ryez> right, esp. for usa
<judofyr> who cares about the u.s and the a?
<ryez> does that matter?
<ryez> here is something matters to ruby actually
* judofyr got it queued up
<judofyr> ryez: is it good?
<ryez> it's cool to see how the changing code affects the thing being created
amerine has joined #ruby-lang
fayimora has joined #ruby-lang
<ryez> yes, that's something myself never thought about
<ryez> kind of ahha moment
krz has joined #ruby-lang
sternicus has joined #ruby-lang
Jay_Levitt has joined #ruby-lang
Daerun has joined #ruby-lang
<robbrit> ryez: the shame is those tools aren't real
Austin__ has joined #ruby-lang
<ryez> probably true, anyway the idea is delivered clearly
<robbrit> yeah it'd be really sweet to have something like that
dcheung has joined #ruby-lang
fayimora has joined #ruby-lang
Asher has joined #ruby-lang
slyphon has joined #ruby-lang
spuk has joined #ruby-lang
<ryez> the idea almost perfectly explains why, in my current organization, people were still doing manual testing (for a long time) on some data transforming programs, because there's no tool for people to generate proper input data in an intuitive way,
outoftime has joined #ruby-lang
rippa has joined #ruby-lang
<ryez> we need to create a tool to generate emulative data, in a quick and intuitive way
<manveru> expand faker
<ryez> sorry?
<ddfreyne> or did manveru call you a faker (also possible)
<judofyr> manveru: I don't think it's quite that Bret is talking about… (although I haven't seen the video)
<ryez> because what i'm talking about is soon to be off topic?
<judofyr> oh, never mind off-topic or not
andkerosine has joined #ruby-lang
enebo has joined #ruby-lang
<robbrit> the talk was about immediate visual feedback of code changes
wyhaines has joined #ruby-lang
kaiwren has joined #ruby-lang
<ryez> thank you guys, that faker looks cool, meanwhile I'm thinking of having some tool/approach to get something quickly created as needed
JEG2 has joined #ruby-lang
_bryanp has joined #ruby-lang
<ryez> robbrit, you're right, that's exactly what Bret talked about
<robbrit> ryez: i think that would only work with certain types of programming
<robbrit> all the stuff he does is very visual, where it would work really well
pbjorklund has joined #ruby-lang
fayimora_ has joined #ruby-lang
chimkan has joined #ruby-lang
slyphon has joined #ruby-lang
futurechimp has joined #ruby-lang
jtoy has joined #ruby-lang
v0yager has joined #ruby-lang
wmoxam has joined #ruby-lang
kitallis has joined #ruby-lang
imajes has joined #ruby-lang
<manveru> robbrit: haven't seen it yet
<manveru> was just thinking about generating fake data
<robbrit> manveru: ahh ok. yeah that's useful too ;)
Fractality has joined #ruby-lang
<manveru> but yeah, everybody dreams of a way to use smalltalk :)
andrewhl has joined #ruby-lang
rshackleford has joined #ruby-lang
jakko has joined #ruby-lang
havenn has joined #ruby-lang
Telmo has joined #ruby-lang
codewrangler has joined #ruby-lang
eggman2001 has quit [#ruby-lang]
<andkerosine> Possible to declare classes inside of an iterator?
<judofyr> andkerosine: anonymous classes, yes
<judofyr> klass = Class.new { … }
virunga has joined #ruby-lang
macmartine has joined #ruby-lang
<oddmunds> judofyr: i gave your ethercode thing a try yesterday, but couldn't get it to work. it kept "waiting"
dv310p3r has joined #ruby-lang
<judofyr> oddmunds: did you start the other etherpad-window in the same session?
<judofyr> e.g. same browser with the same cookies
<oddmunds> yes, i think so
<judofyr> yeah, etherpad doesn't like that…
<oddmunds> i tried another browser too
<oddmunds> but, maybe i used the wrong etherpad
<andkerosine> 1267's an interesting number.
<andkerosine> Significance?
<judofyr> oddmunds: go into the web inspector and hide the iframe that ethercode adds. maybe there's an error behind.
<judofyr> andkerosine: I didn't realize my avatar was on IRC too :)
<oddmunds> judofyr: which etherpad do you prefer? ietherpad seems to have gone belly up
<judofyr> piratepad?
<oddmunds> i'll give it another shot
ironcamel has quit [#ruby-lang]
<oddmunds> i sort of went in another direction, though. i made dedicated user on my server for pairing.
<oddmunds> so two (or more) people can share a screen/tmux session
<judofyr> yeah, I'm not quite sure how useful Ethercode really is
<manveru> it's not horrible
<oddmunds> like you said on the screencast it could be useful to put on a projector
<manveru> you know hackpad?
<oddmunds> no
<manveru> not sure if they have code highlighting yet
<manveru> they took etherpad code and made it into a sweet wiki
<manveru> not really as useful as a shared tmux though :(
niklasb has joined #ruby-lang
<oddmunds> yeah, i think it serves different purposes
<oddmunds> one of the reason i want to pair in tmux is to learn vim tricks from people
achiu has joined #ruby-lang
<manveru> :)
<manveru> well, i'd be totally happy if there was a way to have multiple cursors
<oddmunds> :)
<manveru> or at least an indication who's driving
<manveru> actually... that could be made
<oddmunds> i've never tried it. might not be a problem at all.
<manveru> multiple cursors in a terminal is just impossible to get right
<whitequark> you perverts
<manveru> but you could check what session acted within the last N second and display that as the driving person
<oddmunds> i'm not so sure that it is impossible
<judofyr> oddmunds: it works fine in Chrome + incognito-mode
<oddmunds> judofyr: i'm testing it with my fresh pairing user, so i'm still compiling 1.9.3 :)
dinesh__ has joined #ruby-lang
<muzone> manveru!
<muzone> judofyr!
<muzone> oddmunds!
<muzone> greetings bros..
<judofyr> muzone: :)
<oddmunds> judofyr: now it sort of works :)
<manveru> oddmunds: you can, if you are willing to rewrite every app that uses (n)curses :)
<judofyr> oddmunds: just sort of?
malev_ has joined #ruby-lang
<judofyr> hm… it doesn't show the code…
<oddmunds> i can't bother trying to get it to work atm
slimfit has joined #ruby-lang
<judofyr> seems like a minor issue though. the code clearly gets sent to the server
erics has joined #ruby-lang
m742 has joined #ruby-lang
darkf has joined #ruby-lang
NARKOZ has joined #ruby-lang
Heimidal has joined #ruby-lang
malev has joined #ruby-lang
GiambalaGiambala has joined #ruby-lang
futurechimp has joined #ruby-lang
Sailias has joined #ruby-lang
loincloth has joined #ruby-lang
burgestrand has joined #ruby-lang
savage- has joined #ruby-lang
slyphon has joined #ruby-lang
burgestrand has joined #ruby-lang
nacengineer has joined #ruby-lang
listrophy has quit [#ruby-lang]
lightcap has joined #ruby-lang
optikalmouse has joined #ruby-lang
<optikalmouse> what's ^ do?
<optikalmouse> !a ^ !b
<tobiasvl> xor
<tobiasvl> bitwise
<optikalmouse> kk thanks
<manveru> >> [[true, true], [true, false], [false, true], [false, false]].map{|a,b| a ^ b }
<manveru> => [false, true, true, false]
<manveru> boolean xor
<manveru> that's what the ! are for
<optikalmouse> ok, so if I have a && (!b || !c) || !a && (!b ^ !c)
<optikalmouse> that's saying the same as !b || !c...
<manveru> that almost made my eyes pop out of their sockets
<tobiasvl> sure, they're logically equivalent
krz has joined #ruby-lang
headius has joined #ruby-lang
yeltzooo has joined #ruby-lang
SuperTaz_work has joined #ruby-lang
tbuehlmann has joined #ruby-lang
Jay_Levitt has joined #ruby-lang
<headius> drbrain: ping
lordofthedance has joined #ruby-lang
H2H has joined #ruby-lang
<andrewvos> umm, how do I put images in github comments?
<erikh> there's wiki syntax for it
<erikh> It's in the help
symm- has joined #ruby-lang
<andrewvos> erikh: Thanks dude
<rippa> markup syntax
<rippa> not wiki
yango has joined #ruby-lang
Skif has joined #ruby-lang
Fullmoon has joined #ruby-lang
JohnBat26 has joined #ruby-lang
chimkan has joined #ruby-lang
achiu has joined #ruby-lang
danielvdotcom has joined #ruby-lang
willdrew has joined #ruby-lang
danielvdotcom has quit [#ruby-lang]
hahuang65 has joined #ruby-lang
nebbie has joined #ruby-lang
Carnage\ has joined #ruby-lang
slimfit has joined #ruby-lang
<andkerosine> Is there no way to get an accurate preview of how a Github readme will look in Markdown?
<andrewvos> andkerosine: Build it!
<andrewvos> andkerosine: Or just click the preview button on github
<andrewvos> Whichever is easier
<manveru> 4
<manveru> damn, now i have to change my password again :(
<ReinH> wat
NARKOZ has joined #ruby-lang
mrsolo has joined #ruby-lang
<andkerosine> His password was the randomest number.
<andkerosine> But then he let us know, so he's gotta change it.
<Mon_Ouie> I guess it's the 5th time he has to change it
lightcap has joined #ruby-lang
jondot_ has joined #ruby-lang
Karmaon has joined #ruby-lang
Heimidal has joined #ruby-lang
danielvdotcom has joined #ruby-lang
csherin has joined #ruby-lang
qpingu has joined #ruby-lang
wwalker has quit [#ruby-lang]
lightcap has joined #ruby-lang
lele|w has joined #ruby-lang
burgestrand has joined #ruby-lang
Sailias has joined #ruby-lang
banderson623 has joined #ruby-lang
divoxx has joined #ruby-lang
urbanmonk has joined #ruby-lang
sideshownz has joined #ruby-lang
<TTilus> Mon_Ouie: so he started with -1?
<TTilus> NOOOO! *blush*
<rue> Man, I've been using Windows the last two days, and not even for programming. It's terrible
<TTilus> never let a mathematician do integer arithmetics
<TTilus> rue: may i ask why you torture yourself that way?
<rue> I played a few games and looked at the Skyrim Creation Kit a little
twittard has joined #ruby-lang
publicvoid has joined #ruby-lang
<darkf> rue: how is it?
burgestrand has joined #ruby-lang
<darkf> I want to mod skyrim and play with some shit
<darkf> maybe set up some challenge levels
<rue> It looks quite usable
<darkf> excellent
twittard has joined #ruby-lang
solars has joined #ruby-lang
Sailias has joined #ruby-lang
brian_anderson has joined #ruby-lang
<andkerosine> Criticisms would be much appreciated.
banderson623 has joined #ruby-lang
* jaimef looks for a way to compare changes to a json structure.
<andkerosine> Hm?
<andrewvos> jaimef: If you find a nice way, please msg me ;)
<jaimef> saving ohai.all_plugins in json to track state on servers, and was looking for a way to compare.
curtism has joined #ruby-lang
<jaimef> is there a structure more suitable? yaml?
brian_anderson has joined #ruby-lang
voker57 has joined #ruby-lang
nacengineer has joined #ruby-lang
cyri_ has joined #ruby-lang
jensen_ has joined #ruby-lang
<erikh> there's a structural diff util in activesupport
<erikh> I can't remember what the require/class name is though
<erikh> it's not hard to write your own though
MarkDBlackwell has joined #ruby-lang
rushed has joined #ruby-lang
lightcap has joined #ruby-lang
<MarkDBlackwell> A weird thing is happening, which I don't remember before (and it works fine without `print'): ruby -e"print ([1,2].each do end)" is giving me, `syntax error, unexpected keyword_do_block, expecting ')' '. BTW, this happens on two systems, on Ruby 1.8.6-p0, 1.8.7-p357, 1.9.2-p290 and 1.9.3-p0. Two sets of parentheses makes it work! print (([1,2].each do end)) But, why?
lake has joined #ruby-lang
Sailias has joined #ruby-lang
a1ph4g33k has joined #ruby-lang
andkerosine has quit [#ruby-lang]
nacengineer has joined #ruby-lang
dejongge has joined #ruby-lang
<manveru> MarkDBlackwell: because you got a space between print and (
<uniqanomaly> no
<uniqanomaly> print ([1,2].each{}) does work
<manveru> so does print([1,2].each do end)
<uniqanomaly> with space
<manveru> yeah, because {} has higher precedence
<uniqanomaly> ok
<manveru> if you say print (, then ruby will think that you pass only one argument
<MarkDBlackwell> manveru, you are *so* right! Thank you. :)
<manveru> compare p(1,2,3) to p (1,2,3)
patant has joined #ruby-lang
yxhvuud has joined #ruby-lang
<manveru> no idea why people like to put spaces around those parethesis
<manveru> writing 'foo ()' and 'foo { | bar | }' and the like...
leonL has joined #ruby-lang
* manveru hides from the flame war
<chris2> hehe
<rippa> I write "foo(" but "foo {"
<chris2> yeah
leonL_ has joined #ruby-lang
<rippa> probably for consistency
<MarkDBlackwell> manveru, I don't like to put spaces before parentheses, but I wrongly had print,p,puts as a special (syntax) case--wrongly not thinking of them as methods; thanks again.
<rippa> so both "foo {" and "foo do" have a space
Mchl has joined #ruby-lang
kyrylo has joined #ruby-lang
kyrylo has joined #ruby-lang
<erikh> i like it for if/while/until/etc
<erikh> nice for complex conditionals.
MarkDBlackwell has quit [#ruby-lang]
danielvdotcom has joined #ruby-lang
<andrewvos> Hmmm
<andrewvos> Is there any way to get around $SAFE ?
<erikh> no
<andrewvos> $SAFE=1 more like
<andrewvos> Damnit
<andrewvos> Net http is crapping out when I try to request a url
<andrewvos> And I can't disable safe
<erikh> well, I think there are a few techniques but you should avoid walking around it
<andrewvos> erikh: It's for a bot
<andrewvos> rbot to be exact
dejongge has joined #ruby-lang
<erikh> on both counts drbrain is probably your guy
<erikh> fwiw, $SAFE is designed to only increase and allow less and less operations per increment
<andrewvos> drbrain: Thoughts on getting around SAFE=1 when doing a net/http request. I'm getting "Insecure operation - initialize" :(
<erikh> iow, the whole point is that you can't step around it
<andrewvos> Yeah, true :(
Sailias has joined #ruby-lang
Axsuul has joined #ruby-lang
Axsuul has joined #ruby-lang
chimkan_ has joined #ruby-lang
<rue> foo 1, 2; foo(1, 2); foo {|y, k| y, k }
burgestrand has joined #ruby-lang
lordofthedance has joined #ruby-lang
fayimora has joined #ruby-lang
lsegal has joined #ruby-lang
dcheung has quit [#ruby-lang]
benanne has joined #ruby-lang
Sailias has joined #ruby-lang
Heimidal has joined #ruby-lang
slimfit has joined #ruby-lang
d4mi3n has joined #ruby-lang
andrewhl has joined #ruby-lang
benanne has joined #ruby-lang
andkerosine has joined #ruby-lang
darkf_ has joined #ruby-lang
<andkerosine> I'm passing an absolute path to a local file to require, and it's still loading the one from rvm/gems. How to prevent this?
Phlogistique has joined #ruby-lang
robbrit has quit [#ruby-lang]
<jaimef> hmm mash
<outoftime> andkerosine: paste in the require line?
dfr|mac has joined #ruby-lang
<andkerosine> It's an absolute path, I can assure you. : )
erpuds has joined #ruby-lang
<burgestrand> andkerosine: if it’s an absolute path it loads the file at the absolute path; it might be that that file loads something else however
<drbrain> andkerosine: ruby 1.9 will load both
<andkerosine> Well, I have my gem installed locally, but I'd now like to tinker with it, preferably without having to uninstall it.
<outoftime> andkerosine: are you using bundler?
<andkerosine> Emptying $: doesn't work, just breaks other stuff.
<drbrain> andkerosine: ruby -I lib
<drbrain> andkerosine: -I takes precedence over rubygems
Sailias has joined #ruby-lang
jamw has joined #ruby-lang
Fullmoon_ has joined #ruby-lang
srbartlett has joined #ruby-lang
<S1kx> i'm experiencing extremely high cpu utilization with rbenv + jruby 1.6.6 + celerity, is this a known problem? using 100% on both cores for 30 secs for just opening a site
mikeric has joined #ruby-lang
<headius> it's because jruby's so fast
<headius> USE ALL THE CORES
<headius> I have not heard such a report for jruby alone, so perhaps something in celerity is odd
<whitequark> Y U NO LEAVE SOME CPUS TO THE OS JRUBY?
<S1kx> i wish i didnt have to use jruby
<S1kx> then i wouldnt have had to change like 50% of my code either >:|
<S1kx> but its the only way to run htmlunit right now
<whitequark> S1kx: that most probably means you have bad code in the first place
<whitequark> good code doesn't break even with 1.8->1.9 transition, much less mri->jruby.
<headius> S1kx: I don't really know how celerity works
<S1kx> no it means I am using the new hash syntax for example, which even jruby 1.6.6 doesnt support yet
<whitequark> S1kx: jruby --1.9
<headius> I hope you didn't change a bunch of 1.9 code because you didn't know the --1.9 flag
<S1kx> ^
<S1kx> thanks, didn't know about that
<whitequark> have you tried, like, reading documentation?
<S1kx> last time I used jruby there was no 1.9 support at all, so no in this case, no.
<headius> it will be nice when we're just 1.9 mode by default
<S1kx> i suppoes it must be something with the general java settings on my vm
<a1ph4g33k> headius: isn't that coming with 1.7 ?
<a1ph4g33k> ( btw ... thank you for jruby ... it's good stuff )
looopy has joined #ruby-lang
Jay_Levitt has joined #ruby-lang
<headius> a1ph4g33k: yeah...master is already 1.9 by default
<headius> I keep forgetting when I'm fixing 1.6 bugs
srbartle_ has joined #ruby-lang
havenn has joined #ruby-lang
razu_ has joined #ruby-lang
razu_ has quit [#ruby-lang]
razumasu has joined #ruby-lang
loincloth has quit [#ruby-lang]
eggman2001 has joined #ruby-lang
<mrb_bk> anyone here know anything about compiling kgio/unicorn on centos6?
<eggman2001> I have two strings that appear to be identical but str1 == str2 #=> false and I don't know why
<mrb_bk> getting a conflict with double definition of RUBY_UBF_IO
<a1ph4g33k> eggman2001: whitespace differences?
<eggman2001> both have the same size
<eggman2001> and I don't see any differences in whitespace
<a1ph4g33k> which version of ruby?
<eggman2001> they both have just one space
<eggman2001> 1.9.2
<drbrain> eggman2001: encoding
<eggman2001> same encoding. str1.encoding == str2.encoding #=> true
<drbrain> eggman2001: str1.bytes.to_a == str2.bytes.to_a?
<eggman2001> drbrain: ah, it's returning false. thanks!
razumasu has quit [#ruby-lang]
robbyoconnor has joined #ruby-lang
jensen- has joined #ruby-lang
<mrb_bk> hmm it's all about HAVE_RB_THREAD_BLOCKING_REGION
<drbrain> mrb_bk: what version of ruby are you compiling on?
<mrb_bk> drbrain: ruby 1.9.2p290 (2011-07-09 revision 32553) [x86_64-linux]
<mrb_bk> drbrain: tryopen.c in kgio redefines some stuff in intern.h
<drbrain> 1.9.2p290 definitely has that
<drbrain> (as extconf.rb determined)
<drbrain> mrb_bk: :(
<mrb_bk> drbrain: if you have a second, if not, thanks anyways :)
<drbrain> mrb_bk: I think you're only recourse is to remove the redeclaration and submit a patch back
<drbrain> err, your
<mrb_bk> drbrain: yeah that's what i'm thinking. so you think this is something particular to the package we used to install ruby?
<mrb_bk> rb_unblock_function_t, rb_blocking_function_t, and rb_thread_blocking_region should all be available in 1.9.2
<drbrain> mrb_bk: I think unicorn/kgio is written for ruby 1.9.1
<mrb_bk> drbrain: oh weird, it shouldn't need kgio in 1.9.2?
<mrb_bk> maybe i should try to build unicorn from source and not gem install it
<S1kx> headius: i also see jruby is eating 2.4gb virtual mem from the start, do any global java settings affect that?
<whitequark> S1kx: virtual mem doesn't matter
<whitequark> don't look at VSZ in `top', look at RSS. that's what you really need.
<headius> it's virtual, baby
<headius> as far as you know I'm virtual too
<whitequark> virtual mem includes funky stuff like shared libraries and so on
<S1kx> 1375M res
<whitequark> oh, now that's bad
<headius> sounds like a big app
<S1kx> 2 classes, 1 opening a celerity browser that opens a site
<S1kx> single threaded too
thegeekinside has joined #ruby-lang
<S1kx> i suppose ill do some profiling
<whitequark> jvisualvm!
<erikh> yeah
<headius> yeah, jruby shouldn't use that much for one thing
<erikh> a web browser?
<headius> like I say, I have no idea what celerity might be doing
<headius> maybe it spins up virtualbox
<S1kx> celerity is a wrapper for htmlunit, a headless browser
<S1kx> should be using less resources than an actual browser
<headius> jruby shouldn't even use that much with default settings
<headius> but I don't know how you're running it
leonL has joined #ruby-lang
<S1kx> maybe i changed some settings like xmx once before for rubymine
<headius> that's a possibility
<S1kx> using jruby just with rbenv install jruby-1.6.6; rbenv local jruby-1.6.6; jruby app.rb
<headius> yeah, that should be tiny
<headius> drbrain: how can I help get rdoc+rdoc data gems updated?
<drbrain> headius: ah, crap
<drbrain> I keep getting distracted
<drbrain> so keep bugging me?
<headius> that I can do
<headius> zenspider: pinging about minitest-excludes release with those fixes
<drbrain> headius: after I finish hoe-travis I'll work on it again
<headius> it's not critical since we're using patched local copy, but it would be nice to dump that
<drbrain> I think I was > < close before being distracted last time
<headius> drbrain: ok, no problem
<andkerosine> How to make that DRYer?
<andkerosine> Instead of bothering with closing some methods off, I'm just trusting that the user won't call nonsense methods and including all of the actions for each object. Looks cleaner, feels nicer, but I hate how redundant that looks.
<andkerosine> Can classes like those be declared inside of an iterator?
<drbrain> andkerosine: I think this look great
<andkerosine> Fuck yes!
<andkerosine> Thank you, kind sir.
<andkerosine> Really does mean more than that exclamation might imply.
<drbrain> andkerosine: you can add metaprogramming to create initialize, but I don't think it's worth it
<drbrain> this is straightforward and easy to read
<drbrain> adding metaprogramming would save three lines per class at the cost of 5-10 lines that are harder to read
<andkerosine> As should perhaps be expected given that it's built on your library. : )
<andkerosine> Fair enough.
<drbrain> nice: uri = URI(Paths[:"#{@kind}_about"] % @name)
<drbrain> andkerosine: do you know about unless?
<drbrain> if ! is the same as unless
<andkerosine> Mm-hmm. It's just the first language I've used to have that keyword, so it hasn't stuck yet.
<andkerosine> Definitely an improvement in terms of readability.
slaytanic has joined #ruby-lang
<drbrain> IMO, consistency is more important, especially if you're learning
<eggman2001> if I pull a string for a external source, how does something like "foo" with encoding of UTF-8 end up with a bytesize of 4?
<drbrain> eggman2001: what are the bytes?
<drbrain> eggman2001: there's multiple "o" and "f" code points and a non-breaking space
SuperTaz_work has joined #ruby-lang
<eggman2001> drbrain: to be more exact, the str = "Q4 2011" and str.bytes.to_a = [81, 52, 194, 160, 50, 48, 49, 49]
<drbrain> (although I think the byte size would be > 4 if a non-breaking space were present)
h4y4shi_ has joined #ruby-lang
<drbrain> eggman2001: it's the space
<shevy> I hate shell scripts :(
<eggman2001> drbrain: I'm trying to understand how this happens? I got the string using nokogiri
<drbrain> eggman2001: [194, 160] is the UTF-8 code point C2 A0 and the unicode NO-BREAK SPACE
<drbrain> eggman2001: then it's a no-break space in the source document
<drbrain> possibly &nbsp;
<drbrain> for UTF-8 output, &nbsp; matches \u00A0
<drbrain> so that's the character you get
<drbrain> eggman2001: you can transcode to ISO-8859-1
<drbrain> str.encode Encoding::ISO_8859_1
<eggman2001> ahh I see. and \u00A0 is the UTF-8 code point C2 A0, hence the 2 bytes?
<drbrain> yes
<drbrain> if you're on a Mac the Character Viewer can let you browse unicode codepoints
<eggman2001> it's generally preferable to work in utf8 as opposed to ISO-8859-1 though right?
<eggman2001> i'm using a pc and ubuntu
<drbrain> I'd say yes to that
<eggman2001> very helpful. thanks!
<drbrain> if you're trying to perform string matching there are unicode extensions to regexp
<drbrain> see ri Regexp
<S1kx> 9.11 9.09 0.02 1 Java::ComGargoylesoftwareHtmlunit::WebClient#getPage
<drbrain> \s will match an ASCII space, but not a no-break space
<S1kx> seems like its nothing in ruby then
<drbrain> [[:space:]] will match any unicode Whitespace character
<drbrain> or \p{Space}
bglusman has joined #ruby-lang
rasmus_ has joined #ruby-lang
postmodern has joined #ruby-lang
<postmodern> memos
<eggman2001> I see that the source code is "Q4&nbsp;2011" as suspected. But how would I get the &nbsp; to be replaced with a single space?
razumasu has joined #ruby-lang
<drbrain> a regular space?
<eggman2001> yes
<drbrain> str.gsub(/\p{Blank}/, ' ')
<drbrain> or if you want to collapse multiple spaces
<drbrain> str.gsub(/\p{Blank}+/, ' ')
<drbrain> if you want to include newlines, carriage returns, etc. use \p{Space}
H2H has joined #ruby-lang
<eggman2001> gotcha. thanks!
Cherrum has joined #ruby-lang
petercooper has joined #ruby-lang
Sailias has joined #ruby-lang
hhatch has joined #ruby-lang
<razumasu> Just started testing out Ruby and finding it great fun, but i have a (noob) question. When doing stuff in the irb console, is it possible to somehow save the sessions work you've done in a file?
<andkerosine> razumasu: No, but get yourself a proper editor that can execute code directly and you're set. : )
<razumasu> I've picked up Rubymine, but i was just wondering if it was possible through the irb console (because it's so fun to use!). But thanks for the answer! :-)
<erikh> you could always wrap irb, but it's probably more trouble than it's worth.
<injekt> hmm
<razumasu> Yeah :-) I am just testing out the language, coming from C# and .net. Just got pretty hooked by the irb way of testing things out :-)
<injekt> I would personally recommend against using an IDE for writing ruby
dfr|mac has joined #ruby-lang
Carnage\ has joined #ruby-lang
fayimora has joined #ruby-lang
yfeldblum has joined #ruby-lang
<zenspider> meh. IDEs are fine for newbs
<erikh> I don't always wrap irb, but when I do I do it with eventmachine
<erikh> true story
<zenspider> razumasu: you can turn on irb history tho... that way you can search through it / reuse lines etc... but irb doesn't have a persistent state like smalltalk or lisp does
kyrylo has joined #ruby-lang
burgestrand has joined #ruby-lang
tedwing has joined #ruby-lang
<tedwing> Does anyone have experience compiling Ruby 1.9.3p0 on Mac OS X 10.4 Tiger?
<tedwing> I'm getting an error
<tedwing> Or perhaps is there a preferred version of gcc that I should be using?
<drbrain> tedwing: what error?
leonL has joined #ruby-lang
<drbrain> I can make guesses
<tedwing> process.c:4110: error: implicit declaration of function 'ruby_setreuid'
towski has joined #ruby-lang
leonL has joined #ruby-lang
slimfit has joined #ruby-lang
<drbrain> tedwing: looks like you're hitting BROKEN_SETREUID, but ruby_setreuid doesn't exist anywhere
<drbrain> tedwing: I think you'll need to file a bug on http://bugs.ruby-lang.org
<tedwing> drbrain: Ok I can try that
<drbrain> tedwing: the only reference to it I see is on line 112 of process.c
<drbrain> I would expect it to also be in missing/ or somewhere
Stalkr_ has joined #ruby-lang
<Phlogistique> is there a canonical name for lambda {|a| a.compact.length > 1 } ?
<drbrain> tedwing: looking at the commit this came in on, I think it may have been accidental
<tedwing> drbrain: you found the associated commit?
shevy has joined #ruby-lang
<erikh> svn blame ftw
<drbrain> tedwing: you could try commenting out the lines at the top of process.c added in r11769 and running `make test-all`
Oloryn_lt1 has joined #ruby-lang
<tedwing> drbrain: Just ran `make` again and it worked! … Except now I'm getting another error:
<tedwing> thread_pthread.c:511: error: implicit declaration of function 'pthread_get_stackaddr_np'
jtoy has joined #ruby-lang
<drbrain> tedwing: not so sure about that one
<tedwing> drbrain: ok, well thanks a lot for the help!
<tedwing> drbrain: should I go ahead and submit a bug report?
<drbrain> tedwing: filing a ticket on bugs.ruby-lang.org is your best bet, but you may get a "sorry, 10.4 is not supported" :/
<drbrain> yes, since I can't find ruby_setreuid anywhere
<tedwing> drbrain: haha, I was worried about that
<drbrain> perhaps it existed when 11769 was committed and was since removed
<tedwing> drbrain: hm, ok
<drbrain> I would include `uname -a` and note that you failed in process.c, removed some code, then failed in pthread