<yfeldblum>
zenspider, indeed, but none of those examples shows the root node being namespaced explicitly, and i'm getting exceptions trying it
marco has joined #ruby-lang
<zenspider>
yfeldblum: yes, it does. look at "Namespaces" section
Technodrome has joined #ruby-lang
Technodrome has quit [Changing host]
Technodrome has joined #ruby-lang
<drbrain>
zenspider: I think yfeldblum means <namespace:root>
<zenspider>
and the next section as well
<yfeldblum>
drbrain, that's right
<yfeldblum>
zenspider, i want to generate: <?xml?><ns:root xmlns:ns="uri:ns">...</ns:root>
methods has quit [Quit: Leaving.]
Muz has quit [Ping timeout: 260 seconds]
<yfeldblum>
zenspider, there are some examples of explicitly namespaced child elements (when the parent has declared the namespace already) and implicitly namespaced root elements, but no explicitly namespaced root elements
Averna has joined #ruby-lang
dreamfactory has joined #ruby-lang
srbaker has quit [Quit: Computer has gone to sleep.]
Austin__ has joined #ruby-lang
Austin__ has left #ruby-lang [#ruby-lang]
S3kx has joined #ruby-lang
asdfqwer has joined #ruby-lang
asdfqwer has quit []
setmeaway2 has joined #ruby-lang
kain has joined #ruby-lang
<zenspider>
I'm trying to manually register a namespace before creating the root node. I'm not sure it even makes sense since it is the root node that declares the namespaces it uses...
headius has joined #ruby-lang
nick_h_ has joined #ruby-lang
darix- has joined #ruby-lang
darix- has quit [Changing host]
darix- has joined #ruby-lang
matti_ has joined #ruby-lang
wmoxam_ has joined #ruby-lang
telemachus_ has joined #ruby-lang
telemachus has quit [Ping timeout: 264 seconds]
abuiles has quit [Ping timeout: 264 seconds]
thejspr_ has quit [Ping timeout: 264 seconds]
nick_h has quit [Ping timeout: 264 seconds]
matti has quit [Ping timeout: 264 seconds]
wmoxam has quit [Ping timeout: 264 seconds]
listrophy has quit [Ping timeout: 264 seconds]
mrb_bk_ has quit [Ping timeout: 264 seconds]
setmeaway has quit [Ping timeout: 264 seconds]
S2kx has quit [Ping timeout: 264 seconds]
darix has quit [Ping timeout: 264 seconds]
matti_ is now known as matti
darix- is now known as darix
marco has quit [Quit: WeeChat 0.3.8]
listrophy has joined #ruby-lang
<yfeldblum>
zenspider, the document <ns:root xmlns:ns="uri:ns"/> is a valid document ... but it doesn't look like nokogiri xml builder wants to generate it
agarie has quit [Remote host closed the connection]
faces has joined #ruby-lang
robbyoconnor has joined #ruby-lang
<pototo>
Is there a way I can interact with the Wordpress user database via a Ruby webapp? I want a user to log in with the same credentials they use on Wordpress.
methods has left #ruby-lang [#ruby-lang]
burgestrand has quit [Quit: Leaving.]
<sent-hil>
pototo: it'll be very complicated
<sent-hil>
you're better off building your own blog
rohit has joined #ruby-lang
uuair has quit [Quit: uuair]
<pototo>
I really just want to verify a user exists and not make them create 2 different accounts.
gregmoreno has quit [Remote host closed the connection]
<pototo>
And I have access to the WP database, so it possible for me to log them in the Ruby web app and do the normal password unhashing that wordpress does when it logs someone in?
sush24 has joined #ruby-lang
<sent-hil>
pototo: i've no idea how wordpress stores the password, prob. diff from the way rails stores pass., so you'll need to modify one of them to use the same method as the other
<pototo>
I'm not using rails, but I figured that maybe someone's implemented Wordpress' hashing algo in Ruby and I could use that.
<sent-hil>
i highly doubt it, but you can easily look for it
JohnBat26 has joined #ruby-lang
wyhaines has joined #ruby-lang
<shachaf>
Looking at the WordPress code is probably the simplest way to figure out the format.
<sent-hil>
isn't it a whole lot easier to just build a blog?
ryanf has quit [Quit: leaving]
<pototo>
I already have a large website based on Wordpress with a blog, and I want to create a Sinatra app that has the same user database.
mjio has quit []
<shachaf>
Looks like they use phpass
rohit has quit [Quit: Leaving]
<pototo>
Basically, I want to stay away from writing this new thing in PHP.
<shachaf>
Well, being able to figure out how the WP database works on your own is a test you have to be pass for people to let you do something like that. :-)
<shachaf>
Fortunately it's not very hard, and I already gave it away, really.
<sent-hil>
pototo: i guess there's more of you going around :)
<pototo>
I know enough about how Wordpress does DBs that I can get to the user, email, and hash
imajes has quit [Excess Flood]
imajes has joined #ruby-lang
pototo has quit [Quit: pototo]
Z_Mass has quit [Quit: WeeChat 0.3.9.2]
wyhaines has quit [Remote host closed the connection]
Darkspiel_ has quit [Remote host closed the connection]
pototo has joined #ruby-lang
rohit has joined #ruby-lang
ryanf has joined #ruby-lang
sent-hil has quit [Remote host closed the connection]
kurko_ has quit [Ping timeout: 256 seconds]
mercwithamouth has quit [Ping timeout: 260 seconds]
rohit has quit [Quit: Leaving]
kitallis has joined #ruby-lang
pototo has quit [Quit: pototo]
burgestrand has joined #ruby-lang
rippa has quit [Ping timeout: 244 seconds]
rippa has joined #ruby-lang
charliesome has joined #ruby-lang
gaveen has joined #ruby-lang
ryanf has quit [Quit: leaving]
imajes has quit [Excess Flood]
burgestrand has left #ruby-lang [#ruby-lang]
burgestrand has joined #ruby-lang
gregmoreno has joined #ruby-lang
imajes has joined #ruby-lang
Mon_Ouie has joined #ruby-lang
rippa has quit [Ping timeout: 248 seconds]
gregmoreno has quit [Ping timeout: 260 seconds]
ryanf has joined #ruby-lang
vlad_starkov has joined #ruby-lang
vlad_starkov has quit [Read error: Operation timed out]
dzhulk has quit [Quit: Leaving.]
Averna has quit [Quit: Leaving.]
_malte has joined #ruby-lang
wallerdev has joined #ruby-lang
apeiros_ has quit [Remote host closed the connection]
wallerdev has quit [Quit: wallerdev]
wallerdev has joined #ruby-lang
jsilver has quit [Remote host closed the connection]
heftig has quit [Quit: leaving]
solars has joined #ruby-lang
_malte has quit [Remote host closed the connection]
wallerdev has quit [Quit: wallerdev]
<yorickpeterse>
Morning
dc5ala has joined #ruby-lang
LanceHaig has joined #ruby-lang
sush24 has quit [Quit: This computer has gone to sleep]
bottles has joined #ruby-lang
imajes has quit [Excess Flood]
imajes has joined #ruby-lang
wallerdev has joined #ruby-lang
guns has quit [Quit: guns]
schaerli has joined #ruby-lang
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
MrWibbles has joined #ruby-lang
mpfundstein has joined #ruby-lang
banisterfiend has quit [Read error: Connection reset by peer]
mpfundstein has quit [Client Quit]
robotmay has joined #ruby-lang
lmfao has joined #ruby-lang
zmack has joined #ruby-lang
MrWibbles has quit [Client Quit]
lmfao has quit [Client Quit]
waaataaaw has joined #ruby-lang
waaataaaw has quit [Client Quit]
crazyhorse has joined #ruby-lang
<crazyhorse>
hey what's an easy way of forwarding a method .. i.e. from within my class i have lots of calls to bla .. but i want those to execute all of those on @hello.bla instead
<crazyhorse>
would it just be something like on the class def bla(*args); @hello.bla(args); end
banisterfiend has joined #ruby-lang
<injekt>
crazyhorse: yes
<crazyhorse>
yay
<injekt>
crazyhorse: if you have a lot of methods like that, some would probably use the delegate class
<crazyhorse>
what's happening is i'm using capistrano
<crazyhorse>
and i can't work out how to get access to it's run / sudo and capture methods inside my classes
kith_ is now known as kith
<crazyhorse>
so i'm just doing ServerSetup.new(self)
banisterfiend has quit [Read error: Connection reset by peer]
swav has quit [Remote host closed the connection]
s1n4 has joined #ruby-lang
Technodrome has joined #ruby-lang
Technodrome has joined #ruby-lang
Technodrome has quit [Changing host]
mindbender1 has quit [Ping timeout: 264 seconds]
wallerdev has quit [Quit: wallerdev]
swav has joined #ruby-lang
judofyr has joined #ruby-lang
<judofyr>
RUBY RUBY RUBY
<Technodrome>
good day judofyr
<judofyr>
hey Technodrome
<judofyr>
what's up?
workmad3 has joined #ruby-lang
<Technodrome>
seems like you've been a ruby enthusiast for a while
znowi has joined #ruby-lang
<yorickpeterse>
Nah, he writes Perl for a living
<yorickpeterse>
he quite dislikes Ruby
<Technodrome>
oh?
thone_ has joined #ruby-lang
solars has quit [Ping timeout: 265 seconds]
GarethAdams has joined #ruby-lang
imajes has quit [Excess Flood]
adambeynon has joined #ruby-lang
thone has quit [Ping timeout: 276 seconds]
<judofyr>
Technodrome: don't listen to yorickpeterse. but yes, I have written a lot of Perl for a living in the last year
<judofyr>
Technodrome: but my brain still thinks in Ruby
<yorickpeterse>
ha
<yorickpeterse>
That was just a random guess
imajes has joined #ruby-lang
<crazyhorse>
hey i need to stick this string in yaml "ssh://#{git_user}@#{git_server}:#{git_port}/projects/#{app_name}" and later i'm going to want to do string replacement on it with variable names
<crazyhorse>
can anyone recommend a good way of doing this
<judofyr>
yorickpeterse: not bad
<crazyhorse>
i know there is "ssh://%s@#%s:#%s/projects/%s" but i'd prefer if the string in yaml was readable
<yorickpeterse>
crazyhorse: %user, %server, etc
<yorickpeterse>
then just gsub it
<crazyhorse>
oh yeah.. iterate through multiple times?
<Technodrome>
so a guy i know who started a company a few years ago, just sold it for 90 million dollars
<Technodrome>
talk about a success story
<yorickpeterse>
I reckon the national tax agency is happy too
<Technodrome>
I'm sure
drbrain has quit [Read error: Connection reset by peer]
drbrain has joined #ruby-lang
s1n4 has quit [Quit: leaving]
<Technodrome>
yorickpeterse: you do anything cool these days?
<yorickpeterse>
I'm currently fighting with Rails and Angular JS
<judofyr>
yorickpeterse: what do you think about Angular JS?
<yorickpeterse>
meh
<yorickpeterse>
I don't like the idea of moving everything to the browser
<yorickpeterse>
With backends you can more easily scale and benchmark things
<yorickpeterse>
With JS you're much more left at the mercy of browsers
<yorickpeterse>
it's also slow as shit
<yorickpeterse>
Backbone might be nice, haven't tried it yet, but it seems fairly lightweight
<yorickpeterse>
What I dislike of Angular so far is that it mixes logic and presentation up to an insane level
<yorickpeterse>
In a way it's nice that you can do stuff like `ng-show="foo == true"` but it mixes things up to a point where it becomes a giant clusterfuck
io_syl has quit [Quit: Computer has gone to sleep.]
<Technodrome>
the whole, browser for everything is the wrong solution as well
<Technodrome>
i like rails because it solves problems
<yorickpeterse>
meh, not a fan of Rails
<Technodrome>
and at the end thats the desired result
schaerli has quit [Remote host closed the connection]
<yorickpeterse>
I don't like the "Do it our way or gtfo" mentality of it
<Technodrome>
some ramaze or that other one?
<Technodrome>
rails is flexible enough i think
<yorickpeterse>
I'm a Ramaze person
<yorickpeterse>
Having said that, there are interesting parts in Rails and I can see why people like it
<whitequark>
yorickpeterse: "do it our way or gtfo" on the other end of the spectrum you have EJB
<whitequark>
thousands of factory factories definitely allow for quite some flexibility.
<yorickpeterse>
EJB?
<Technodrome>
I don't get to religious or biased when it comes to frameworks or languages, it's all about that end result, solving a problem, not writing my controllers in the most perfect way, which might mean super minimalism
<whitequark>
yorickpeterse: enterprise java beans
<yorickpeterse>
heh
<Technodrome>
good old ejb's
<yorickpeterse>
So here's a current issue I have with Angular: I'm outputting a Liquid template but dumb-ass Angular thinks it needs to process the {{template}} tags
<yorickpeterse>
Apparently there's this module that you can use to "sanitize" it but it seems there's no "one tag" way of doing it
<yorickpeterse>
Instead it seems I have to create a damn controller, model and perform some Ajax call to actually get the data
<yorickpeterse>
ffs I just want `ng-gtfo-tags="true"` or whatever
<yorickpeterse>
Also their website randomly breaking is another fine example of why "Everything in the browser" is a stupid idea
<Technodrome>
yeah I wouldn't mess with it, nothing wrong with server side logic
<yorickpeterse>
At least we're moving away from it as much as possible with this app
<pangel>
I have a question about blocking and non-blocking I/O. If I use blocking I/O, I must use threads to keep part of my application running. If I use non-blocking, I consume a lot of CPU. Is there a way to just subscribe to I/O events and designate a function to be run on each of those events?
<yorickpeterse>
First off, if you're using MRI there's no proper threading going on
gnufied has quit [Quit: Leaving.]
<yorickpeterse>
Second, non-blocking shouldn't use a lot of CPU, at least not by design
<yorickpeterse>
(i.e. it's not a "feature")
gnufied has joined #ruby-lang
<yorickpeterse>
But, you can use ionotify for example to act when a file changes
<pangel>
yorickpeterse: Then I'm doing it wrong. I have a loop akin to: while true do recvfrom_nonblock; other_stuff; end
gnufied has quit [Client Quit]
<yorickpeterse>
Yeah, that's the issue: `while true` is more or less a way of saing "Do this thing really really really fast and often"
<yorickpeterse>
CPUs don't like that
gnufied has joined #ruby-lang
<yorickpeterse>
A very easy way to get around that (assuming you can't use something else than a loop) is to just insert a sleep statement
<yorickpeterse>
e.g. `loop { do_some_work; sleep(0.1); }`
rue|w has joined #ruby-lang
<pangel>
Yes, seems much better. I'll look into ionotify though. Also, would fibers help me here?
<pangel>
(This is probably a confused question, though. I just read about fibers a while ago and I wonder if they're related to what I am doing)
zarubin has quit []
<yorickpeterse>
errr, depends on what you're doing
zarubin has joined #ruby-lang
<yorickpeterse>
What exactly are you trying to achieve?
beiter has quit [Ping timeout: 244 seconds]
<Technodrome>
I got offered a ruby job a few days ago, hence why I'm here :P
imajes has quit [Excess Flood]
<Technodrome>
I've used ruby for years, but haven't used it in a few years
imajes has joined #ruby-lang
<pangel>
listen/send on udp to multiple peers and display stats in real time about these peers
<yorickpeterse>
pangel: Did you look into ZeroMQ?
<pangel>
yorickpeterse: no!
<yorickpeterse>
Either way, you're better off using a pub/sub model instead of polling like a mofo
<yorickpeterse>
The latter is not only CPU intensive but also network intensive (of course depending on the size of the packets)
<judofyr>
pangel: you can use IO.select. it will block until the IOs are ready for reading/writing
<yorickpeterse>
pangel: http://www.zeromq.org/ There's a lot to read but it takes a lot of cruft from dealing with TCP/UDP
<pangel>
yorickpeterse: how does ZeroMQ does it?
<pangel>
judofyr: Well, how do I do other things in the meantime without threads?
<crazyhorse>
so if you had "one is %s, two is %s", % [1,2] gives you "one is 1, two is 2"
<judofyr>
you can add padding, convert to hex
<crazyhorse>
judofry: i found ruby a little bit overwhelming compared to php at first
<crazyhorse>
just because there were so many methods
<judofyr>
socialcoder: "foo" % bar is just a shortcut for sprintf("foo", bar)
<crazyhorse>
lol, after you know most of them.. seems nice :)
<socialcoder>
one question guys
<judofyr>
crazyhorse: yeah, and it's often easier to search for PHP functions (because they are all in one namespace)
<judofyr>
crazyhorse: but yeah, it's kinda annoying that they're all in the same namespace ;)
<whitequark>
judofyr: it's not like php has significantly less functions
<whitequark>
after you account all the extensions and stuff
<socialcoder>
I know this is subjective, but currently I am committing 2 hours per day to learning. Think in about 3 months, I will know the language to build something simple, or move to advanced level?
<crazyhorse>
it's funny i'd just written my first MVC framework in php (which was pretty basic and crap).. and i found rails.. so i just swtiched instead
<judofyr>
whitequark: nope. (I didn't say so either?)
<crazyhorse>
socialcoder: should be able to build something pretty good after 3 months
<crazyhorse>
socialcoder: get a copy of "The Ruby Programming Language" by david flannigan
rue|w has quit [Ping timeout: 264 seconds]
<socialcoder>
i was thinking after learn hard way, will move to beginning ruby, perter cooper. Bad idea?
<crazyhorse>
if you go through that, it's unlikley you'll have any basic questions for anyone
rue|w has joined #ruby-lang
<crazyhorse>
i don't know.. just recommend books i love :)
<socialcoder>
wow, its that good a book?
<socialcoder>
haha ok
<judofyr>
socialcoder: I've heard good things about it (Beginning Ruby)
rue|w has quit [Read error: Connection reset by peer]
rue|w has joined #ruby-lang
<socialcoder>
judofyr: me too
<socialcoder>
if I am not irritating you guys, is there a place where I can find ruby tutorials/project to practice? so I can get good at the codes?
<whitequark>
what you actually need is a fast way to compare two abstract identifiers or search in a hash with an abstract identifier as a key
<judofyr>
calling *any* method segfaults
<charliesome>
that rocks
<whitequark>
the fact that symbols are defined as character sequences is an implementation detail arising from the fact that program code is a character sequence, not the need to represent symbols as character sequences.
<charliesome>
breaking ruby is fun
<whitequark>
so, the rare case when you actually need a character sequence out of a symbol is metaprogramming
<whitequark>
in every other case just use strings
<whitequark>
/rant.
gnufied has joined #ruby-lang
<whitequark>
as a more concrete example, foundry doesn't have strings corresponding to symbols at runtime at all.
<whitequark>
which doesn't hurt even a single task related to metaprogramming, of course, because you don't do metaprogramming at runtime
<whitequark>
I'm insanely grateful to matz that he decided to keep Symbols in the language and not just make Strings python-alike.
gaveen has quit [Remote host closed the connection]
madish has joined #ruby-lang
<charliesome>
whitequark: i'm insanely grateful to matz that he didn't make ruby python-alike
<whitequark>
btw, do $ readelf -S `which ruby`
<whitequark>
see that .hash? it's a hash where the keys are symbols (readelf -s) and values are method bodies
<charliesome>
whitequark: just because symbols are little more than numbers with names traditionally doesn't mean ruby can't have something a little higher level
<whitequark>
charliesome: my point is, if you need something higher level than that bad enough, that often means that you are simply doing the wrong thing
<whitequark>
I'd instead like to see more identifier-specific methods on Symbol, notably methods adding ?!= suffixes and stripping them
<whitequark>
those would be quite relevant and useful
<charliesome>
open a feature request
<charliesome>
Symbol#{ivar, cvar, gvar} would also be handy
<charliesome>
that sticks @, @@ or $ in front
<whitequark>
charliesome: I will, when I'd get an idea of how the API should look like
<charliesome>
yorickpeterse: if you comment out a ?> it closes anyway
<whitequark>
yorickpeterse: C raises the parse error at the first character of ';
<whitequark>
which is correct actually
<yorickpeterse>
whitequark: it makes sense as to why it happens, I just think it should not happen at all
<whitequark>
yorickpeterse: so, the language should parse comment body and assume that you have syntactically correct code inside?
<yorickpeterse>
I found out because I had a regex that ended with */
<whitequark>
or at least matched string delimiters?
<charliesome>
maybe i'm looking at the world through ruby coloured glasses, but you'd think this sort of thing would not cause a fatal error on compilation: http://eval.in/4533
<whitequark>
that'd be a wtf as of itself
<yorickpeterse>
whitequark: interesting enough Ruby itself handles it fine
<whitequark>
So now you just have to create your own XSLT stylesheet to perform any operations you want (code optimization, code obfuscation, whatever...).
<whitequark>
ROFL.
sailias has quit [Quit: Leaving.]
<yorickpeterse>
Nothing wrong with XSLT
<whitequark>
yorickpeterse: try to write an optimizer with XSLT which works on ASTs
<charliesome>
that's pretty tame as far as some startup times go
<andrewvos>
charliesome: Yeah I'm estimating here. I've normally opened up facebook or twitter by that time because I'm so irritated at how slowly it starts - so I'm not sure how long it takes.
<judofyr>
andrewvos: but yeah, in this case, Open3 probably does the heavy work for you
<judofyr>
sorry yorickpeterse
solars has quit [Ping timeout: 250 seconds]
<judofyr>
open3("irb") do |i, o, e| i << "1+1\n"; o.read end
<yorickpeterse>
:>
sent-hil has joined #ruby-lang
solars has joined #ruby-lang
<andrewvos>
judofyr: What's the "e"?
<ddd>
error
beiter has quit [Quit: beiter]
methods has left #ruby-lang [#ruby-lang]
<ddd>
input output error
<ddd>
(forgot to prefix each of those with std)
<andrewvos>
Erm, where do I require open3 from :/
FiXato|VPS has joined #ruby-lang
<andrewvos>
Oh wait got it
apeiros_ has quit [Remote host closed the connection]
<andrewvos>
this? Open3.popen3
<injekt>
yes
<jtoy>
excuse the silly question, how do i escape this properly, I am trying to run this: id=1081; file = 'foo.txt'; cmd = "grep -m 1 \"\\\"id\\\":#{id},\" #{file} " but the end keeps getting cut off
solars has quit [Quit: WeeChat 0.3.7]
<tockitj_>
how to debug ruby app that has freezed on remote server ?
rue|w has joined #ruby-lang
<yorickpeterse>
tockitj_: kill it
<tockitj_>
oook?
<yorickpeterse>
You can't really debug something that has frozen
<tockitj_>
why not ?
<yorickpeterse>
..because it's frozen?
<andrewvos>
injekt: Thanks
<yorickpeterse>
Therefor it does, most likely, not respond to anything
<tockitj_>
i don't know what is reason it does not respond
<yorickpeterse>
What have you tried/
<jtoy>
nm, my silly mistake
wmoxam_ is now known as wmoxam
<tockitj_>
maybe some kind of remote pry debugging thingie ?
wmoxam has quit [Changing host]
wmoxam has joined #ruby-lang
<tockitj_>
i don't know if ruby vm is stuck really
vlad_starkov has quit [Read error: Connection reset by peer]
lucas82 has joined #ruby-lang
lucas82 has left #ruby-lang [#ruby-lang]
vlad_starkov has joined #ruby-lang
<andrewvos>
judofyr: Why would stdout.read be blocking?
<judofyr>
andrewvos: it should be blocking until the process exists
<judofyr>
exits*
dr_bob has quit [Quit: Leaving.]
<andrewvos>
judofyr: Oh :(
<andrewvos>
judofyr: I need to get access to stdin for a while
<judofyr>
andrewvos: use while chunk = out.readpartial(4092)
<andrewvos>
judofyr: I need this to be open a while
<andrewvos>
yay thanks judofyr
chimkan has quit [Quit: chimkan]
BigO_ has joined #ruby-lang
rue|w has quit [Remote host closed the connection]
davidbalber|away is now known as davidbalbert
R_Macy has joined #ruby-lang
chimkan_ has joined #ruby-lang
shtirlic_ has quit [Read error: Connection reset by peer]
sush24 has joined #ruby-lang
shtirlic has joined #ruby-lang
esad has quit [Quit: Computer has gone to sleep.]
dr_bob has joined #ruby-lang
esad has joined #ruby-lang
sush24_ has joined #ruby-lang
sush24 has quit [Ping timeout: 265 seconds]
rue|w has joined #ruby-lang
richardjapenga has quit [Quit: Leaving]
<mfn>
I'm using pry-debugger; any idea how can I access the variable "cat" without renaming it? Pry maps it to the shell command cat ...
banister_ has left #ruby-lang [#ruby-lang]
<andrewvos>
mfn: self.cat ?
banisterfiend has joined #ruby-lang
<mfn>
O_O
jtoy has quit [Quit: jtoy]
<banisterfiend>
mfn: just indent
schaerli has quit [Remote host closed the connection]
<banisterfiend>
mfn: commands are only looked up if they're hard against the margin
<mfn>
banisterfiend: works, thank you!
<mfn>
(self didn't)
<banisterfiend>
mfn: alternatively prepend a ; (semicolon)
<banisterfiend>
mfn: because cat is a local?
<banisterfiend>
self.x can only be used if x is a method
<judofyr>
yeah
<judofyr>
"any idea how can I access the variable "cat" without renaming it"
<banisterfiend>
mfn: alternatively if you hate that pry commands get precedence over ruby code in general, then set a: Pry.config.command_prefix = "%"
<judofyr>
mfn: working on a social network for cats?
<mfn>
judofyr: sounds ridiculous without context :)
<injekt>
who isn't?
<banisterfiend>
that enforces u to use a %cat instead of just 'cat', and so on for all commands
<andrewvos>
mfn: Yeah dude. Terrible variable name -.-
dr_bob has quit [Quit: Leaving.]
<mfn>
it's the short for "category" actually ...
<injekt>
not if it's an instance of Cat..
<injekt>
ow
burgestrand has quit [Quit: Leaving.]
<judofyr>
mfn: I'm working with categories in a project now. so many of many loops look like: categories.each { |cat| … }
<judofyr>
hahaha
<judofyr>
:D
<andrewvos>
mfn: Then I suggest you type "egory"
<injekt>
egory, makes no sense as a variable name
<injekt>
c'mon
<judofyr>
many of the*
<andrewvos>
injekt: shut uuuuppp
<injekt>
andrewvos: <3
<andrewvos>
:)
dr_bob has joined #ruby-lang
apeiros_ has joined #ruby-lang
gnufied has joined #ruby-lang
agarcia has quit [Quit: Konversation terminated!]
<judofyr>
andrewvos: I'll add this line to my code: egory = "andrewvos says this make sense"
zhul_mechanos has joined #ruby-lang
banisterfiend has quit [Remote host closed the connection]
krohrbaugh has quit [Quit: Leaving.]
FiXato|VPS has quit [Ping timeout: 252 seconds]
headius has joined #ruby-lang
chimkan_ has quit [Quit: chimkan_]
<andrewvos>
:)
<andrewvos>
EGORY
gaveen has joined #ruby-lang
<judofyr>
egory: maybe I just should start to call you that
digitalbane has joined #ruby-lang
<judofyr>
egory: I really need to write that nick-mutation plugin to LimeChat.
<judofyr>
so I can tab-complete both you and apieros
briantrust has quit [Remote host closed the connection]
Fretta has joined #ruby-lang
io_syl has joined #ruby-lang
<injekt>
heh
levicole has left #ruby-lang ["["Textual IRC Client: www.textualapp.com"]"]
chimkan has joined #ruby-lang
coliflor has joined #ruby-lang
dr_bob has quit [Quit: Leaving.]
dr_bob has joined #ruby-lang
havenn has quit [Remote host closed the connection]
krohrbaugh has joined #ruby-lang
havenn has joined #ruby-lang
workmad3 has quit [Ping timeout: 265 seconds]
joevandyk has quit [Quit: joevandyk]
gaveen has quit [Ping timeout: 245 seconds]
intellitech has joined #ruby-lang
davidbalbert is now known as davidbalber|away
gaveen has joined #ruby-lang
davidbalber|away is now known as davidbalbert
wyhaines_ has quit [Remote host closed the connection]
ejholmes has quit [Quit: ejholmes]
wyhaines has joined #ruby-lang
MaddinXx has quit [Remote host closed the connection]
gregmoreno has joined #ruby-lang
esad has quit [Quit: Computer has gone to sleep.]
jbwiv has joined #ruby-lang
MaddinXx_ has joined #ruby-lang
blazes816 has joined #ruby-lang
esad has joined #ruby-lang
Uranio has joined #ruby-lang
thekungfuman1 has left #ruby-lang [#ruby-lang]
thekungfuman1 has joined #ruby-lang
digitalbane has left #ruby-lang [#ruby-lang]
alvaro_o has joined #ruby-lang
wallerdev has joined #ruby-lang
GarethAdams has quit [Quit: Leaving...]
thekungfuman1 has left #ruby-lang [#ruby-lang]
thekungfuman1 has joined #ruby-lang
davidbalbert is now known as davidbalber|away
sent-hil has quit [Remote host closed the connection]
thekungfuman1 has left #ruby-lang [#ruby-lang]
__butch__ has joined #ruby-lang
jtoy has joined #ruby-lang
Technodrome has quit [Quit: Leaving.]
faustman has joined #ruby-lang
joevandyk has joined #ruby-lang
nick_h_ has quit [Ping timeout: 265 seconds]
gnufied has quit [Quit: Leaving.]
nick_h has joined #ruby-lang
__butch__ has quit [Remote host closed the connection]
vesan has quit [Read error: Connection reset by peer]
jtoy has quit [Quit: jtoy]
<Spaceghost|cloud>
andrewvos: Not very classy making fun of him when he's not here.
<Spaceghost|cloud>
As much as I'm not one of his fans, he's a great contributor.
<Spaceghost|cloud>
But you know, fuck dhh. :p
stoic_squirrel has joined #ruby-lang
rippa has joined #ruby-lang
datanoise has joined #ruby-lang
zmack has quit [Remote host closed the connection]
vesan has joined #ruby-lang
briantrust has joined #ruby-lang
__butch__ has joined #ruby-lang
sent-hil has joined #ruby-lang
heftig has joined #ruby-lang
esad has quit [Ping timeout: 276 seconds]
brianpWins has joined #ruby-lang
esad has joined #ruby-lang
davidbalber|away is now known as davidbalbert
enebo has quit [Quit: enebo]
<Uranio>
could somebody please, subscribe my email address to rubytalk mailing list
<Uranio>
I apply for it a lot of times but don't get any email
thekungfuman has joined #ruby-lang
chimkan has quit [Quit: chimkan]
<thekungfuman>
I have a scope question: I have a script that makes a few SOAP connections and a MySQL connection. Several parts of the script need access to those SOAP and MySQL objects after they're created which is easy when everything is a constant or a global but they're inaccessible if I refactor parts out into methods unless I pass all of them into basically every method. What is the right way to make those objects accessible? Consta
<thekungfuman>
ethods?
apod has quit [Quit: Leaving]
sush24_ has quit [Ping timeout: 265 seconds]
Technodrome has joined #ruby-lang
Technodrome has joined #ruby-lang
Technodrome has quit [Changing host]
imajes has quit [Excess Flood]
imajes has joined #ruby-lang
sush24_ has joined #ruby-lang
mrsolo has joined #ruby-lang
shoe has joined #ruby-lang
heftig has quit [Ping timeout: 264 seconds]
jtoy has joined #ruby-lang
heftig has joined #ruby-lang
<thekungfuman>
If that's too obvious of a question and someone wants to just point me to a good resource that's fine too. ^_^
<banisterfiend>
TTilus: 6,9 is the quirky european way of saying 6.9 right?
<banisterfiend>
TTilus: to what i'm used to in new zealand
<rue>
banisterfiend: Uu, dutchlands. You there long?
unsymbol has joined #ruby-lang
<rue>
Also, yes, the SI used to mandate a decimal comma. Now a dot is accepted, too…which I prefer.
<banisterfiend>
rue: i've moved here, so i'll be here for the forseeble future
<rue>
(Because 100,000.00 is better than 100 000,00
<rue>
banisterfiend: Ah! Cool, didn’t hear about that. We’re bound to meet at one of the EU conferences, then ;)
headius has quit [Read error: Connection reset by peer]
<banisterfiend>
rue: are you going to ams.rb on the 19th of dec?
headius has joined #ruby-lang
<rue>
No, I don’t think I can make that :P
<banisterfiend>
me either probably (i think i missed signing up hehe)
thekungfuman has quit [Quit: Page closed]
benanne has joined #ruby-lang
* TTilus
likes 100 000,00
<TTilus>
banisterfiend: temperatures between -5 and -10 °C are pretty much optimal for winter :)
scampbell_ has quit [Quit: Leaving]
momo__ has joined #ruby-lang
chimkan has left #ruby-lang [#ruby-lang]
<TTilus>
banisterfiend: u dont need bit uncomfy extra gear to ride a bike, not too slippery, no slush
<rue>
I’ve been riding to work without a jacket the last couple days. Had < -10 earlier so now it feels warm
ebouchut has quit [Quit: This computer has gone to sleep]
bottles has quit [Remote host closed the connection]
<banisterfiend>
TTilus: but dont you still skid on the ice?
jwollert- has joined #ruby-lang
havenn has joined #ruby-lang
<TTilus>
banisterfiend: only if i want to ;)
scampbell has quit [Disconnected by services]
<TTilus>
which happens every now and then
scampbell has joined #ruby-lang
_malte has joined #ruby-lang
wasnotrice_ has joined #ruby-lang
chrismcgh has joined #ruby-lang
wang_ has joined #ruby-lang
<banisterfiend>
TTilus: do you wear thermals?
znouza_ has joined #ruby-lang
<TTilus>
rue: its always surprinsing how body tunes itself for winter, first +5 feels terrible, after first < -20 it feels like summer when you're back to -10
scampbell has quit [Disconnected by services]
<TTilus>
banisterfiend: "thermals"?
<TTilus>
banisterfiend: sorry, not _that_ native english speaker
scampbell_ has joined #ruby-lang
<TTilus>
banisterfiend: ok, google image search helped =D
<TTilus>
banisterfiend: no i dont
scampbell has joined #ruby-lang
kurko_ has joined #ruby-lang
<banisterfiend>
TTilus: do you guys have santa claus?
<banisterfiend>
TTilus: living in holland they have two santa clauses, one is called "sintaklaas" and he wears a popes hat and has black slaves, but they also have the standard "santa claus", too
foca_ has joined #ruby-lang
_sillymarkets has quit [Ping timeout: 245 seconds]
momo_ has quit [*.net *.split]
sepp2k has quit [*.net *.split]
jbwiv has quit [*.net *.split]
reactormonk has quit [*.net *.split]
foca has quit [*.net *.split]
meizaps has quit [*.net *.split]
wasnotrice has quit [*.net *.split]
jwollert has quit [*.net *.split]
yugui_zzz has quit [*.net *.split]
wang has quit [*.net *.split]
zz_chrismcg has quit [*.net *.split]
znouza has quit [*.net *.split]
<TTilus>
banisterfiend: we now have the standard ho-ho-ho-santa
sent-hil has quit [Remote host closed the connection]
swav has joined #ruby-lang
scampbell_ has quit [Quit: Leaving]
<TTilus>
banisterfiend: used to have "nuuttipukki" too, (you might try to squeeze that http://fi.wikipedia.org/wiki/Nuuttipukki thru google translate and have your brain hurt)
<tockitj_>
where to configure list of directories that ri will search ?
<banisterfiend>
TTilus: was he banned for being racist? :)
<TTilus>
tockitj_: it doesnt use loadpath?
<TTilus>
banisterfiend: so 201X =D
sent-hil has joined #ruby-lang
<tockitj_>
TTilus, no
<tockitj_>
might have something to do with rvm though
ammar_ has joined #ruby-lang
reactormonk has joined #ruby-lang
babinho_ has joined #ruby-lang
sepp2k has joined #ruby-lang
jbwiv has joined #ruby-lang
swav has quit [Ping timeout: 265 seconds]
wang has joined #ruby-lang
ReinH_ has joined #ruby-lang
xsdg_ has joined #ruby-lang
yugui_zzz has joined #ruby-lang
znz_v0 has joined #ruby-lang
jds__ has joined #ruby-lang
__butch__1 has joined #ruby-lang
Mch1 has joined #ruby-lang
hackeron_ has joined #ruby-lang
rins_ has joined #ruby-lang
Swimmin__ has joined #ruby-lang
bstrie_ has joined #ruby-lang
s4muel_ has joined #ruby-lang
wang_ has quit [*.net *.split]
agarie has quit [*.net *.split]
ReinH has quit [*.net *.split]
__butch__ has quit [*.net *.split]
Swimming_Bird has quit [*.net *.split]
Weems has quit [*.net *.split]
ddfreyne has quit [*.net *.split]
dabradley has quit [*.net *.split]
chaosis has quit [*.net *.split]
znz_v has quit [*.net *.split]
vbatts has quit [*.net *.split]
jds has quit [*.net *.split]
xsdg has quit [*.net *.split]
babinho has quit [*.net *.split]
rins has quit [*.net *.split]
hackeron has quit [*.net *.split]
anekos has quit [*.net *.split]
ammar has quit [*.net *.split]
dumfries has quit [*.net *.split]
s4muel has quit [*.net *.split]
msch has quit [*.net *.split]
Mchl has quit [*.net *.split]
bstrie has quit [*.net *.split]
kvs has quit [*.net *.split]
Agr has joined #ruby-lang
anekos has joined #ruby-lang
agarie has joined #ruby-lang
chaosis has joined #ruby-lang
vbatts has joined #ruby-lang
meizaps has joined #ruby-lang
dumfries has joined #ruby-lang
dreamfactory has joined #ruby-lang
Mon_Ouie has quit [Ping timeout: 260 seconds]
dabradley has joined #ruby-lang
ddfreyne has joined #ruby-lang
kvs has joined #ruby-lang
<freedrull>
cant really understand the difference between "string".to_sym and "string".intern ...... :|
nXqd has joined #ruby-lang
<ddfreyne>
freedrull: they are the same
<TTilus>
freedrull: who says they differ?
Agr has quit [Quit: Page closed]
_malte has quit [Remote host closed the connection]
_malte has joined #ruby-lang
wallerdev has quit [Quit: wallerdev]
<rue>
Interning is an inherited term
<freedrull>
so they are the same after all ?
<freedrull>
just assumed there would be a difference i guess
_malte has quit [Ping timeout: 244 seconds]
drbrain has joined #ruby-lang
<TTilus>
freedrull: if you check the source using your favorite ruby core documentation browser you see that in MRI they both are implemented by the same rb_str_intern() C-function
jstemmer has quit [Quit: leaving]
sepp2k1 has joined #ruby-lang
schaerli has joined #ruby-lang
<banisterfiend>
TTilus: just use: show-source String#intern and show-source String#to_sym :P
sepp2k has quit [Ping timeout: 260 seconds]
momo_ has joined #ruby-lang
<TTilus>
\o/
<TTilus>
banisterfiend: how could i forget!
<banisterfiend>
esp. with me spamming #ruby-lang all the time ;)
<apeiros_>
yorickpeterse: for yard, I still have to write the docs myself :(
srbaker has quit [Client Quit]
intellitech has joined #ruby-lang
scampbell has quit [Quit: Leaving]
Mon_Ouie has joined #ruby-lang
<yorickpeterse>
whitequark: personally I would like to see a more central organization (think the Python Foundation) but I'm not sure if much more than that will work out well for Ruby
tenderlove has joined #ruby-lang
BigO_ has joined #ruby-lang
TTilus has joined #ruby-lang
_malte has quit [Remote host closed the connection]
_malte has joined #ruby-lang
alvaro_o has quit [Read error: Connection reset by peer]
_malte has quit [Read error: Connection reset by peer]
_malte has joined #ruby-lang
_malte has quit [Remote host closed the connection]
_malte has joined #ruby-lang
_malte has quit [Ping timeout: 255 seconds]
schaerli has quit [Read error: Connection reset by peer]
<drbrain>
whitequark: I'm concerned that Brian didn't remove the matz veto bit after the developer meeting
t0h has quit [Ping timeout: 245 seconds]
robotmay has joined #ruby-lang
<drbrain>
the lack of compromise on anything after the developers meeting makes me feel insulted
<whitequark>
yorickpeterse, drbrain: I'm sad to see so much desire for control in the proposal
<yorickpeterse>
hmm
<whitequark>
basically he says to ruby-core folks that they are no more designing Ruby in any way. regardless of how it would be actually good or not, I don't see how such a proposal will get accepted
<drbrain>
also, "Once all Council members have implemented the feature, the feature can be discussed in concrete terms"
<drbrain>
so everybody has to implement something before it can become part of ruby
srbaker has joined #ruby-lang
klebervi_ has quit [Remote host closed the connection]
sailias1 has quit [Ping timeout: 264 seconds]
<ddd>
drbrain: he didn't remove it from what I read. in fact matz specifically said it would be over his dead body (the mortal grounds comment) before he gave up that right, but he would exercise control in its use
klebervirgilio has joined #ruby-lang
<drbrain>
ddd: yup
<havenn>
I, for one, support our benevolent dictator for life. (At least Brixen hasn't supported murdering him, yet.)
<ddd>
stress the yet :)
<drbrain>
havenn: your parenthetical is quite a ways over the top
My_Hearing has joined #ruby-lang
<yorickpeterse>
tbh I find it somewhat arrogant to try and take away control of Ruby from matz
<havenn>
drbrain: Sorry, I jest.
<yorickpeterse>
after all he does still "own" the language (for as much as that is possible with a language)
<ddd>
he might, if he doesn't get more help on writing the rubyspecs for features as was mentioned in the meeting
<havenn>
drbrain: I thought Matz's corporeal form comment was funny.
<drbrain>
havenn: I know, just because I disagree with brixen's proposal doesn't mean we have to stuff words in his mouth
<havenn>
drbrain: Very true.
dorkrawk has joined #ruby-lang
MaddinXx has quit [Remote host closed the connection]
<ddd>
i think that was more cracking a joke than anything
<ddd>
bad one maybe, but a joke none the less :)
<havenn>
ddd: I've never been good with telling jokes. Runs in my family. :(
t0h has joined #ruby-lang
<drbrain>
ddd: yeah, I just don't want to derail reasonable discussion with perceived personal slights :D
<ddd>
hehe my 12yo daughter says I am 'devoid of any sense of humor' nor do I own a funny bone as she puts it
<havenn>
<3 MRI, <3 RBX, etc. etc.!
<ddd>
drbrain: totally understandable and correct standing
Mon_Ouie has quit [Ping timeout: 260 seconds]
klebervirgilio has quit [Ping timeout: 255 seconds]
<whitequark>
ha, got blocked by Brian on twitter. nice.
<banisterfiend>
whitequark: waht did u say to him?
<ddd>
anyways, back to ripping out activerecord, replacing with sequel, and moving off mri to jruby. later all (and now to find a suitable replacement for standalone-migrations that supports sequel as well)
<ddd>
yorickpeterse: similar to standalone-migrations g model MyModel name:text etc? (rather than having to code them all by hand though I suppose I should probably just do that and quit relying on generators)
<yorickpeterse>
There are no generators for Sequel but migrations are quite trivial to write
<headius>
whitequark: he blocked you?
<ddd>
oh yeah I did that already. i manually wrote my migration tables
<whitequark>
headius: yes
<yorickpeterse>
Sequel also doesn't set the field definitions in the model, it retrieves it automatically
<headius>
if anyone should get that treatment I'd think it would be me
<yorickpeterse>
At least he didn't tell you to go fuck yourself, unlike a certain other Rubyist
<yorickpeterse>
correction: Rails-ist
<ddd>
right, with s-m it created the model migration for me, i can do that by hand. i should stop relying on generators to do all my stuff for me anyways hehe
havenn has quit [Remote host closed the connection]
srbaker has quit [Quit: Computer has gone to sleep.]
<wmoxam>
whitequark: it seems he didn't like that you suggested that he may be trolling
<wmoxam>
:p
<yorickpeterse>
ddd: s-m?
<ddd>
standalone-migrations gem
<banisterfiend>
whitequark: i dont get it either..i guess he's a bit sensitive
<yorickpeterse>
ddd: Ah, never heard of it
<drbrain>
yorickpeterse: what was personally amusing about that one is that the certain Rails-ist spouted off after 90 minutes of reasonable conversation with between his coworker and the targeted party
<ddd>
basically the rails generator for migrations+models made standalone
<drbrain>
-with
<whitequark>
wmoxam: I've said that it _looks like_ he is trolling. as in, his proposal is _not productive_.
<whitequark>
but he doesn't seem to understand that no matter how I tried to explain.
<ddd>
but, i've been bitching because everything auto-assumes rails stuff (like ActiveRecord and RAILS_ENV) and I don't like it so might as well do the dirty myself.
t0h has quit [Ping timeout: 255 seconds]
<drbrain>
yorickpeterse: yeah, Ryan Biggs and Sam Stephenson were discussing how Sam didn't have enough time and couldn't find a suitable new maintainer
<banisterfiend>
drbrain: bigg's comment was still a little bit snarky ;)
<whitequark>
yorickpeterse: at least dhh doesn't try to force everyone to work like he does it.
<banisterfiend>
biggs'
<yorickpeterse>
drbrain: ah
t0h has joined #ruby-lang
<yorickpeterse>
whitequark: sadly his code says otherwise
<drbrain>
banisterfiend: sure, but Sam and Ryan were still able to discuss it civilly
Oloryn_lt2 has joined #ruby-lang
<whitequark>
yorickpeterse: you mean the whole "convention over configuration" concept?
<yorickpeterse>
or at least his ideoligies, he doesn't write that much code himself these days I believe
<yorickpeterse>
Yes
<yorickpeterse>
* ideologies
<whitequark>
yorickpeterse: the programming style and the programming process are different things
<ddd>
he's passive-agressive. when i was working RVM with wayne and michal he got all bitchy because we passed on information one of *his* team members told us, and he jumped all in my crap because we didn't ask *him* first,and then proceeded to have wayne called on the carpet at his *job* to try to get me kicked off the RVM project, and then did it *again* over the same issue until wayne basically told him and his job this is an opensour
srbaker has joined #ruby-lang
_Mon_Ouie_ has joined #ruby-lang
<whitequark>
yorickpeterse: dhh's projects force a certain style, which is a valid thing as of itself, but you might use any process you want
<yorickpeterse>
ddd: wat
<ddd>
but never said a word to *me* other than i 'should know who he is' (in the best dhh-mimicry style)
<ddd>
yorickpeterse: oh yeah. ask wayne
<ddd>
and michal
<whitequark>
yorickpeterse: he doesn't say you _must_ use waterfall or agile or whatever, for example.
<drbrain>
ddd: O_O_O
<yorickpeterse>
whitequark: true dat
<drbrain>
I don't have enough eyes
<ddd>
hehe
<yorickpeterse>
drbrain: you'd be an alien
<drbrain>
or a mutant
<apeiros_>
does twitter forget that you follow some people?
<yorickpeterse>
or just weird
<ddd>
Mars boy
<drbrain>
apeiros_: yup
<ddd>
apeiros_: yes
<apeiros_>
wow
<drbrain>
it's probably a scaling technique
<yorickpeterse>
It's a feature
<apeiros_>
so this wasn't just me getting old…
<bluepojo>
rarr webscale
My_Hearing has quit [Ping timeout: 260 seconds]
<apeiros_>
repeatedly had the "hu? didn't I follow that guy already?"
<apeiros_>
annoying "feature"
<apeiros_>
microsoftian type of feature…
<yorickpeterse>
headius: something totally unrelated, who do I have to bribe in order to get Ripper support in jruby?
havenn has joined #ruby-lang
<ddd>
apeiros_: backscale my tweets a few months and you'll see i've bitched about that little 'feature' a few times
_malte has joined #ruby-lang
<whitequark>
yorickpeterse: iirc it's already there
<yorickpeterse>
whitequark: nope, it throws an error if you require it
<ddd>
whitequark: no. ripper library is not supported under jruby
tenderlove has quit [Remote host closed the connection]
<enebo>
yorickpeterse: I plan on hacking no my start of ripper next week again
<enebo>
yorickpeterse: I have the grammar ported and I need to incorporate lexer next
<yorickpeterse>
That would be wonderful as it would save me the hassle of having to convert jruby-parser's AST to what I need
s1n4 has joined #ruby-lang
<enebo>
yorickpeterse: The real challenge is we have a single lexer for 1.8/1.9 and I also want those ripper changes to work as well
TTilus has quit [Ping timeout: 252 seconds]
<whitequark>
yorickpeterse: I've probably asked this before, but: Y U NO RUBY_PARSER?
<enebo>
but I can probably subclass our lexer :)
<yorickpeterse>
whitequark: column numbers
<yorickpeterse>
and my experience with mr zenspider hasn't exactly been stellar. I don't like to write code that depends on people that somehow don't get along with me
<whitequark>
yorickpeterse: ah. right. I'm going to hack that in _someday_, but it's quite hard.
havenn has quit [Remote host closed the connection]
TTilus has joined #ruby-lang
<yorickpeterse>
I don't like Ripper but comparing it to the rest it's the best for my specific use case
<drbrain>
yorickpeterse: how do you use ripper? I have a hard time trusting it because it returns invalid results for syntax errors:
<enebo>
jruby used to have it in our ordinary AST but it was a lot of extra object creation and we put our AST on a diet
<yorickpeterse>
drbrain: I'm using it for my linter atm, though I at some point (if needed) want to either switch to something generic or support the various platform specific parsers
llaskin1 has quit [Changing host]
llaskin1 has joined #ruby-lang
<llaskin1>
any suggestions how to rescue an error that says "/var/lib/jenkins/.rvm/rubies/ruby-1.8.7-p371/lib/ruby/1.8/net/http.rb:560:in `initialize': Connection refused - connect(2) (Errno::ECONNREFUSED) " I tried rescue Errno::ECONREFUSED
t0h has joined #ruby-lang
<drbrain>
llaskin1: you need more Ns
<yorickpeterse>
llaskin1: by using the right connection details
<yorickpeterse>
enebo: so I've read
<whitequark>
yorickpeterse: I'm going to fork ruby_parser and convert it to Ragel, adding column numbers along with cleaning the code overall
* yorickpeterse
has to start buying lots of beer
<whitequark>
yorickpeterse: wanna participate in that?
<whitequark>
next week if nothing crtitical happens
<yorickpeterse>
drbrain: Ripper does have an on_parse_error callback method but I haven't looked into it that much
<drbrain>
yorickpeterse: I'll put that in the back of my head for when I drop 1.8 support in RDoc
<yorickpeterse>
whitequark: Yes, although I'm not entirely sure how much time I can fit in it
<llaskin1>
yorickpeterse: funny, this uses the same connection details as a myriad of a number of files
<llaskin1>
they work fine
<yorickpeterse>
drbrain: eh?
<llaskin1>
and drbrain its rescued as " rescue Errno::ECONNREFUSED" in the code...
<drbrain>
yorickpeterse: rdoc uses a modified irb parser since Ripper isn't available on ruby 1.8
Xzyx987X has quit [Ping timeout: 244 seconds]
<drbrain>
I don't have the time to fix parse bugs in two different parsers
<drbrain>
also, by that point, maybe enebo will finish JRuby support of it
<yorickpeterse>
drbrain: aah
* enebo
knocks on wood
<llaskin1>
yorickpeterse: any other suggestions?
<yorickpeterse>
llaskin1: Not without a pastie of the code
<whitequark>
yorickpeterse: I'm going to backport the Ragel itself and probably some code cleaning to the upstream, but also I'm going to change AST to be more sane and less parsetree'y, which probably won't get upstreamed any time soon.
<whitequark>
*Ragel lexer itself
<drbrain>
enebo: I'm not exactly excited about switching parsers, so I'm sure there's plenty of time :D
<enebo>
drbrain: It does give me more motivation though beyond yorickpeterse and a couple of other people asking for ripper support
lewrker_ has quit [Remote host closed the connection]
<whitequark>
yorickpeterse: eg why the flying f does RP substitute 0 for empty (arglist) node if there's no arguments in a block?! I've no idea
<yorickpeterse>
eh?
<whitequark>
yorickpeterse: sec
<llaskin1>
i literally ran the same code twice in a row, and it works the 2nd time
<llaskin1>
wierd
<llaskin1>
so how can I rescue that error?
<llaskin1>
is there any way?
<llaskin1>
it seems to happen when I have 10 different connections trying at once(jenkins running a bunch of selenium tests)
<yorickpeterse>
Rescuing the specific error should work in theory
<llaskin1>
right so I put rescue's as I described above...
<whitequark>
note that I don't think that this is a good API at all in this case
<ReinH>
whitequark: that's not the problem
<whitequark>
but it does not violate LSP
<whitequark>
that's all I am saying
<ReinH>
the problem is `Object.new.inspect verbose: true`
<whitequark>
ReinH: LSP does not require that to work.
<ReinH>
whitequark: that's true
mercwithamouth has joined #ruby-lang
Elico1 has joined #ruby-lang
<ReinH>
it's still a smel
<ReinH>
l
<whitequark>
ReinH: I agree
<whitequark>
so let's ditch that and move on, pls?
<ReinH>
ok
<whitequark>
yorickpeterse: what about #diffable_inspect?
<whitequark>
I like it most
<yorickpeterse>
too long, implies it contains diff formatting
<whitequark>
er
<whitequark>
it contains formatting which is supposed to be fed to diff
<whitequark>
which is the case
<yorickpeterse>
I mean stuff like the line prefixes (+, -, @@, etc)
<whitequark>
and yes it's long, but that's a feature. I do not expect for that to be called often
<whitequark>
yorickpeterse: yeah, but "diffable" does not imply that, does it?
<whitequark>
it's like "making binary file diffable" which means converting it to some text form
<yorickpeterse>
Not directly, but I personally would think it would contain some kind of "markup
<yorickpeterse>
* related to it
<whitequark>
strange
<yorickpeterse>
I should probably go to bed though, can't think very clearly atm
jcr has joined #ruby-lang
<whitequark>
3:30AM here...
<yorickpeterse>
heh
postmodern has joined #ruby-lang
<yorickpeterse>
right, I'm off. laters
<jcr>
i am trying to finish a python wrapper around octopress which needs rvm to initialize for the rakefile
<jcr>
if I use the python script from inside the octopress dir it works but not outside of the dir
<jcr>
how can i get python to initilaize rvm and/or the rakefile
<ddd>
see rvm.io under the scripting section and figure out how to make python launch a shell session. its written in bash, so however python manages to create shell sessions is what you'll have to do.
jtoy has quit [Quit: jtoy]
Elico1 has quit [Quit: Elico1]
<jcr>
ddd: thanks
charliesome has joined #ruby-lang
Mon_Ouie has joined #ruby-lang
davidbalber|away is now known as davidbalbert
_Mon_Ouie_ has quit [Ping timeout: 244 seconds]
sent-hil has quit [Remote host closed the connection]
oddmunds has quit [Quit: WeeChat 0.3.9]
chimkan_ has joined #ruby-lang
davidbalbert is now known as davidbalber|away
Averna has joined #ruby-lang
sulo has quit [Remote host closed the connection]
mercwithamouth has quit [Ping timeout: 246 seconds]