yfeldblu_ has quit [Read error: Connection reset by peer]
afreidah4 has quit [Ping timeout: 252 seconds]
yfeldblum has joined #ruby-lang
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
benlovell has quit [Ping timeout: 252 seconds]
<whitequark>
yorickpeterse: have you read my comments?
ikrima has joined #ruby-lang
<yorickpeterse>
whitequark: Yes, StringIO won't help
<yorickpeterse>
It will only help if the input is handed to you as an actual stream
<yorickpeterse>
e.g. local files, chunked HTTP responses
<yorickpeterse>
If you get the input as a single, 10 MB blob then StringIO won't help
<whitequark>
it will allow you to distribute parser slowness through the entire input document
elia has joined #ruby-lang
<whitequark>
unpack included.
<yorickpeterse>
Yes, that's part of what the buffer I'm hacking does too
<yorickpeterse>
If that doesn't work I might still use StringIO internally
<whitequark>
but if you use stringio, *if* you get passed a stream, you also consume it incrementally
<whitequark>
and your buffer is dumb as a brick
<whitequark>
it always eats it entirely
yatish27 has quit [Ping timeout: 276 seconds]
_elia has joined #ruby-lang
<yorickpeterse>
The point is not to not consume the entire input, but to consume it in steps of a managable size
rahul_j has joined #ruby-lang
<whitequark>
yeah
<yorickpeterse>
My current theory is that there's a certain startup overhead to String#unpack. If that's the case then actually doing things incrementally will be a lot slower
<whitequark>
... theory? seriously?
michd is now known as MichD
elia has quit [Ping timeout: 265 seconds]
c0d3_k1ra has quit []
<yorickpeterse>
Yes, because I haven't actually proven it?
<yorickpeterse>
I'm not going around saying "LOL STRING#UNPACK HAS A SLOW BOOTUP" until I can actually show that
<yorickpeterse>
Even though I'm fairly sure that's the case
<whitequark>
have you looked at its source?
<yorickpeterse>
You mean that streaming pile of crap C? Yeah, looking at it atm
<yorickpeterse>
at least it uses goto, has to be webscale
t4nk891 has joined #ruby-lang
<yorickpeterse>
This would be so much easier if Strings were not mutable in Ruby
<yorickpeterse>
No, I'm profiling the bigger picture atm
chouhoulis has joined #ruby-lang
<whitequark>
well, it's not certain at all that it spends all that time in the allocator
yfeldblum has joined #ruby-lang
tkuchiki has quit [Ping timeout: 252 seconds]
emaxi has joined #ruby-lang
stardiviner has quit [Ping timeout: 240 seconds]
<yorickpeterse>
As an example, if I take out String#codepoints / unpack and just use String#[] the runtime is about the same
<yorickpeterse>
so indeed it seems String#[] is slower than a snail
<yorickpeterse>
which is not surprising, but extremely annoying
stardiviner has joined #ruby-lang
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
chouhoulis has quit [Ping timeout: 240 seconds]
Squarepy has joined #ruby-lang
rahul_j has quit [Quit: rahul_j]
banister has joined #ruby-lang
mechanicles has quit [Read error: Connection reset by peer]
banister is now known as banisterfiend
mechanicles has joined #ruby-lang
yfeldblum has quit [Ping timeout: 265 seconds]
rahul_j has joined #ruby-lang
sferik has joined #ruby-lang
emaxi has quit [Ping timeout: 276 seconds]
lolmaus has quit [Read error: Connection reset by peer]
cbreeze has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
qba73 has joined #ruby-lang
phansch has quit [Quit: WeeChat 0.4.2]
iTrojan1 has joined #ruby-lang
<apeiros>
whitequark: does perf work on OSX 10.9 too?
<apeiros>
oh, linux kernel profiling… I guess not
afreidah4 has joined #ruby-lang
lolmaus has joined #ruby-lang
iTrojan has quit [Ping timeout: 252 seconds]
<ledestin>
yorickpeterse: hi. care to tell your mongodb story?
vondruch has quit [Ping timeout: 276 seconds]
<yorickpeterse>
ledestin: are you interested in me blasting for 6 hours about vague issues we've had in the past?
<yorickpeterse>
also which of the 20 stories?
<ledestin>
yorickpeterse: no, not for 6 hours.
<ledestin>
yorickpeterse: ok. let me rephrase it. do you think mongo is ever useful?
<yorickpeterse>
Yes
alexju has quit [Remote host closed the connection]
<yorickpeterse>
It's useful in the early stages when prototyping
<yorickpeterse>
or when storing stuff like logs or w/e
<yorickpeterse>
Basically data you can afford to lose and can't normalize
<yorickpeterse>
Also data you don't need to access often
<ledestin>
what’s the problem with accessing often?
<yorickpeterse>
it's slow
<yorickpeterse>
That is, it works fine on small sets of data
<yorickpeterse>
But good luck getting the first 100 documents in a collection of 45 million
<ledestin>
yorickpeterse: ok, thanks!
yfeldblum has joined #ruby-lang
<yorickpeterse>
Honestly if you want NoSQL I'd try PostgreSQL with the JSON storage extension enabled
<whitequark>
^
<yorickpeterse>
Not sure about the performance of it but at least Pg is stable
<chris2>
nosql with sql ;)
Cakey has joined #ruby-lang
<yorickpeterse>
Our problems so far have mostly been Mongo becoming super slow out of the blue with no proper indication as to what's going on
<apeiros>
yorickpeterse: re PG for NoSQLy stuff - I thought there was some key/value optimized setting for Pg, but last time I searched, I didn't find it anymore. do you happen to know something in that regards?
<yorickpeterse>
No matter how many profilers we'd throw at it, the end "fix" was always to either increase the cluster size or to reboot it
<ledestin>
I’m just researching whether I should apply for a job that uses mongo
<yorickpeterse>
ha
<yorickpeterse>
apeiros: I don't know the name since I don't use Pg that heavily but yes, it has some key/value store thing built-in
<whitequark>
hstore
<apeiros>
whitequark: that's for a single value afaik
<apeiros>
as in: serialize something like a hash into a single value
<yorickpeterse>
ledestin: ask them about the total size of their DB, if it's less than 100GB you'll probably be fine
<whitequark>
apeiros: you can index keys inside hstore for example
<whitequark>
and use them in queries
<apeiros>
I thought there was something akin to having a key and a value row with unique keys. but maybe I'm just dreaming stuff up :)
<ledestin>
yorickpeterse: ok, thanks
<apeiros>
(or maybe the way is to indeed just use two columns, have a unique constraint on the key column and use hstore for the value column)
momomomomo has joined #ruby-lang
yfeldblum has quit [Ping timeout: 276 seconds]
<yorickpeterse>
My biggest issue with Mongo has always been that I can't gather any solid facts as to why it's not working for us.
<yorickpeterse>
That is, it acts up but I can't accurately show what is the problem
<apeiros>
whitequark: awesome about pg in devel are the new json functions
momomomomo has quit [Client Quit]
afreidah4 has quit [Ping timeout: 245 seconds]
emaxi has joined #ruby-lang
<apeiros>
where you can aggregate a select into a single json array of objects
dsaint-pierre has joined #ruby-lang
rahul_j has quit [Quit: rahul_j]
<apeiros>
some of the nice stuff has already landed in 9.3 too
<apeiros>
still need to bench it, but from preliminary test, I'd expect it to be magnitudes faster than going via AR + Oj
vpretzel_ is now known as vpretzel
momomomomo has joined #ruby-lang
momomomomo has quit [Client Quit]
elliotec has joined #ruby-lang
<yorickpeterse>
we still need to plan when we move away from El Mongo to either MySQL or Pg
<yorickpeterse>
soon ™
sandbags has quit [Remote host closed the connection]
<apeiros>
do. not. use. mysql.
<apeiros>
at the very least, use maria.
<yorickpeterse>
RDS bra
<yorickpeterse>
no Maria there
<apeiros>
mysql belongs to oracle and hence has fallen to the dark domain.
<yorickpeterse>
says the one using Oracle :)
<apeiros>
FOCEDLY!
sandbags has joined #ruby-lang
sandbags has quit [Changing host]
sandbags has joined #ruby-lang
<apeiros>
I mourn about it everyday.
<apeiros>
*FORCEDLY even
<yorickpeterse>
come work here, I promise you we don't use Oracle
<yorickpeterse>
But yeah, we'll be looking at Pg as well
<yorickpeterse>
There's a bit of FUD around it though
elliotec has quit [Ping timeout: 240 seconds]
<ledestin>
Pg has nice features
<yorickpeterse>
e.g. my CTO made the remark that there was a lot more to find on MySQL
vondruch has joined #ruby-lang
nhmood has joined #ruby-lang
<ledestin>
yorickpeterse: I just read that mysql still doesn’t have check constraints
<yorickpeterse>
I don't know that much about Pg (I use it at tiny-scale only), I do know that it's more correct and has more features
<yorickpeterse>
e.g. being able to insert NULL into a datetime in MySQL pisses me off
<yorickpeterse>
errrr ''
<yorickpeterse>
Not NULL, that makes some sense at least
<yorickpeterse>
<mysql> k I'll turn that into 0000-00-00 00:00:00
rahul_j has joined #ruby-lang
<ledestin>
yorickpeterse: horrible stories you tell
nathanstitt has joined #ruby-lang
sandbags has quit [Ping timeout: 245 seconds]
charliesome has joined #ruby-lang
<apeiros>
yorickpeterse: mysql is owned by oracle. so using mysql means using an oracle product :)
momomomomo has joined #ruby-lang
<apeiros>
also, mysql - the db without a query planner…
<yorickpeterse>
apeiros: although I fully agree with veto-ing Oracle that's a bit more difficult to use as an argument for moving an entire infrastructure over from MyFirstSQL to Pg
<darix>
apeiros: that is FUD too
<yorickpeterse>
(on company level that is)
<apeiros>
darix: default db engine in mysql has no planner. no FUD, fact.
<apeiros>
at least 2y ago. but do tell if it changed since.
<apeiros>
i.e., the only "speed up" you'd get from a prepared statement in mysql was that the SQL would not need parsing.
<apeiros>
of course, you'd still use it, because you want bind variables.
Cumol has joined #ruby-lang
<apeiros>
there were other issues with the default db engine in mysql, but I don't remember :-/
marcofernandez has joined #ruby-lang
kyb3r_ has quit [Quit: Leaving]
<yorickpeterse>
lol MyISAM
<apeiros>
see, I even forgot that name. I only remembered InnoDB (that's the saner db engine in mysql, right?)
<apeiros>
ah, lol, right, myisam = no transactions
<apeiros>
and table level locking
afreidah4 has joined #ruby-lang
Cumol has quit [Ping timeout: 250 seconds]
marcofernandez has quit [Ping timeout: 240 seconds]
<yorickpeterse>
Transactions are overrated anyway
<DefV_>
hmz
<yorickpeterse>
It's business logic, it belongs on application level
<yorickpeterse>
just like foreign keys
<apeiros>
yorickpeterse: BS
marcofernandez has joined #ruby-lang
<DefV_>
how would I compare [{:a => 43}] and [{"a" => 43}]
<apeiros>
yes, business logic belongs into application level. that doesn't mean you should not use transactions.
<apeiros>
it's outstandingly foolish not to use transactions for anything non-trivial.
rahul_j has quit [Quit: rahul_j]
<yorickpeterse>
But the Rails gods say that it belongs on application level
<yorickpeterse>
(also how is the joke not obvious)
<apeiros>
yorickpeterse: because there are sadly so many people who truly believe what you said
matp has quit [Remote host closed the connection]
<yorickpeterse>
I was hoping I was annoying this channel long enough for people to realize that 9 out of 8 times I'm not entirely serious
<yorickpeterse>
But yeah, those people make me sad
<apeiros>
but yeah, I didn't figure you were kidding
<DefV_>
How would you guys do name matching?
<DefV_>
I have a database with full names, and I want to see if someone is in it
<yorickpeterse>
DefV_: are your names normalized?
<DefV_>
example: "Jan De Poorter" should match "De Poorter Jan" or "Jan d Poorter"
<DefV_>
nope
<yorickpeterse>
The most naive form is substring matching, but it's pretty difficult to do accurately
<ledestin>
DefV_: normalize it first, then proceed as usual
<yorickpeterse>
e.g. for input name "Jan De Poorter" you'd check for the 3 words in every existing name
<yorickpeterse>
which is going to be super duper slow
<DefV_>
ledestin: how would you normalize it then :-)
<apeiros>
n-gram matching with pg
<yorickpeterse>
apeiros: hey don't get all academic on us
<apeiros>
/stop markov
mnngfltg has joined #ruby-lang
<ledestin>
DefV_: code the rules you can, the rest is manual
<yorickpeterse>
DefV_: there literally are dozens of ways to match names, addresses, etc
<DefV_>
(the hard part is that "Jan De Poortere" != "Jan De Poorter")
<yorickpeterse>
Your first step is to make your data set sane
<yorickpeterse>
e.g. use a uniform order for names where possible
<DefV_>
I can't make the data set sane
<DefV_>
I get my input from 3 files
<DefV_>
1 CSV, 1 XLS, 1 XML
<apeiros>
we should replace people names with check-digited numbers
<yorickpeterse>
You can pre-process the data
<DefV_>
all with about the same people
<DefV_>
but noted in a different, non-uniform way
<apeiros>
hey there, 123-982-281-542
<yorickpeterse>
apeiros: dibs on 666-666-666-666
<cout>
yorickpeterse: I prefer to use a unicorn order
<ledestin>
apeiros: nazis did it btw
<yorickpeterse>
I didn't want to make that joke
<yorickpeterse>
since apeiros is German
chouhoulis has joined #ruby-lang
<apeiros>
yorickpeterse: you'll have to set up the checksum digit algorithm for that number to work out :)
<apeiros>
ledestin: congrats to godwinning this channel the first time in the 10y I'm here
<ledestin>
apeiros: I just thought you didn’t know that
marcofernandez has quit [Ping timeout: 240 seconds]
miqui has joined #ruby-lang
<apeiros>
ledestin: SSN and similar exist in every country
<apeiros>
ok, most
<ledestin>
apeiros: true
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Cakey has quit [Ping timeout: 265 seconds]
<ledestin>
but. there’s big difference
<ledestin>
still
<yorickpeterse>
as long as we don't end up with QR codes on the back of our heads
<ledestin>
a novel idea
malconis has joined #ruby-lang
<wm3|lunch>
yorickpeterse: I'm putting together a proposal that we should have QR codes painted onto our skulls with lead-based paint, so that they can be read with high-powered xray beams fired at people's heads
<wm3|lunch>
yorickpeterse: that sounds reasonable, yeah?
wm3|lunch is now known as workmad3
<yorickpeterse>
make sure you also include a bit.ly URL in case people don't have a QR scanner
sferik has joined #ruby-lang
<yorickpeterse>
responsive QR codes
<workmad3>
yorickpeterse: oh sure, that can just be tattooed onto the lips...
<gnufied>
apeiros: not really every country, India tried one - but i think it is abandoned now.
<yorickpeterse>
Pretty sure there's at least one nerd on this planet with a QR code on the back of their head
<gnufied>
unless you mean from first world perspective
<workmad3>
well, there are people who have implanted RFID chips into themselves
<yorickpeterse>
I never got that too
Varun_krishna has joined #ruby-lang
<yorickpeterse>
wait there's a perfect xkcd for that
<workmad3>
a QR tattoo would be somewhat less than that
sandbags has joined #ruby-lang
alexju_ has joined #ruby-lang
<Varun_krishna>
Hi all, I am new to ruby and ror, I wish to learn it quickly, what are the resources that helps me to learn it quickly ?
<ledestin>
Varun_krishna: I guess it’s out of date now, but still
sandbags has quit [Ping timeout: 276 seconds]
afreidah4 has quit [Ping timeout: 246 seconds]
<gnufied>
the best is obviously to ask questions here for ruby. yorick is always glad to be of help.
<yorickpeterse>
actually that is pretty true
ironsand has joined #ruby-lang
Hytosys has quit [Quit: Hytosys]
Squarepy has quit [Ping timeout: 276 seconds]
<yorickpeterse>
I'm not going to blast newbies for asking questions
<Varun_krishna>
@yorick So sorry.
<yorickpeterse>
Varun_krishna: eh?
<yorickpeterse>
For what?
Cakey has joined #ruby-lang
<Varun_krishna>
You said that you are going to blast the newbies for asking questions.
<yorickpeterse>
No, I said *not*
<apeiros>
gnufied: I corrected myself to "ok, most"
<yorickpeterse>
"yorickpeterse | I'm not going to blast newbies for asking questions" <- note the "I'm *not* going ..."
<Varun_krishna>
Oops sorry I didn't notice that "not" . :P
fbernier has joined #ruby-lang
enebo has joined #ruby-lang
jgpawletko has joined #ruby-lang
<Varun_krishna>
So how is ruby different from java?
rahul_j has joined #ruby-lang
<yorickpeterse>
Java is a more-or-less compiled language, Ruby is interpreted (as a start)
<ledestin>
Java is full of boilerplate
<yorickpeterse>
Java is also statically typed, Ruby is dynamic/duck typed
<yorickpeterse>
it means that instead of having to do
<yorickpeterse>
name: String = "foo"
<yorickpeterse>
you do
<yorickpeterse>
name = "foo"
<Varun_krishna>
Oh
<apeiros>
yorickpeterse: meh, compiled/interpreted/bytecodeVM is not a language propert
<apeiros>
*property
<apeiros>
you can have a C interpreter ffs
<yorickpeterse>
No, but it's a pretty big difference in the usage of the language
<apeiros>
not really
<apeiros>
macruby can compile your ruby code. you don't write it any differently.
mechanicles has quit []
c_s_g has joined #ruby-lang
<Varun_krishna>
What is macruby? is it different from ruby?
Squarepy has joined #ruby-lang
eugmill has joined #ruby-lang
futilegames has quit [Ping timeout: 265 seconds]
<yorickpeterse>
it's basically a Ruby flavour for iOS
<yorickpeterse>
errrrr
<yorickpeterse>
wait
<yorickpeterse>
wait
<yorickpeterse>
that's Rubymotion
<apeiros>
that's rubymotion
<yorickpeterse>
derp
<apeiros>
yes
<apeiros>
macruby was a 1.9 fork using llvm
<apeiros>
and the base for rubymotion
<apeiros>
but rubymotion compiles your code too
<apeiros>
but rubymotion is arguably quite a bit different from vanilla ruby
<yorickpeterse>
I'd say it's not Ruby
<yorickpeterse>
it just looks like it
saarinen has joined #ruby-lang
Cakey has quit [Ping timeout: 258 seconds]
rofel has quit [Remote host closed the connection]
tbuehlmann has quit [Ping timeout: 252 seconds]
scmx has quit [Ping timeout: 250 seconds]
futilegames has joined #ruby-lang
rahul_j has quit [Quit: rahul_j]
achal has joined #ruby-lang
user22345345 has joined #ruby-lang
marcofernandez has quit [Ping timeout: 265 seconds]
rofel has joined #ruby-lang
<user22345345>
Hello. Question about ruby constants. I would like to define a constant array of other constants and found a way that eliminates duplication of definitions, but want some feedback. Here it is: CONST_ARRAY = [ CONST_A = 1, CONST_B = 2 ]
<apeiros>
user22345345: you asked. you get feedback.
<apeiros>
inline assignment is ugly beyond reason.
<user22345345>
apeiros: You're right. I meant: I don't worry about that.
<apeiros>
then why do you even ask?
eugmill has quit [Ping timeout: 276 seconds]
<user22345345>
apeiros: in case there are non-asthetic reasons why this should be avoided
<user22345345>
apeiros: can you think of any?
<apeiros>
no
<user22345345>
Thanks
eugmill has joined #ruby-lang
<cout>
how do I force ruby to use the minitest gem and not the builtin one? I put gem 'minitest' at the top of my script per the minitest docs, but it still seems to be using the wrong minitest.
tbuehlmann has joined #ruby-lang
user22345345 has quit [Quit: Page closed]
kitak_ has joined #ruby-lang
kitak_ has quit [Remote host closed the connection]
codemonk has joined #ruby-lang
yalue has joined #ruby-lang
<codemonk>
yo
kitak has quit [Ping timeout: 240 seconds]
<gnufied>
cout: you can specify a different version via gem method
<gnufied>
have you tried it?
<cout>
gnufied: I haven't tried that yet
ericwood_ is now known as ericwood
sferik_ has joined #ruby-lang
<gnufied>
yeah as long as gem version is different than builtin one, you should be able to use it
chouhoulis has quit [Remote host closed the connection]
<cout>
didn't work
<cout>
oh wait, hmm
davispuh has joined #ruby-lang
AncientAmateur has joined #ruby-lang
<cout>
afaict the version of minitest that comes with ruby 1.9.3p0 (don't ask) is 2.5.1
<cout>
but if I request >= 4.7.5, it still uses that one
<cout>
if I say = 4.7.5, it gets the gem
sferik has quit [Ping timeout: 252 seconds]
marcofernandez has joined #ruby-lang
Cakey has joined #ruby-lang
afreidah4 has joined #ruby-lang
marcofernandez has quit [Ping timeout: 258 seconds]
nathanstitt has quit [Quit: I growing sleepy]
ledestin has quit [Quit: ledestin]
<yorickpeterse>
headius: ping
<headius>
yorickpeterse: sup
karamazov has joined #ruby-lang
ledestin has joined #ruby-lang
afreidah4 has quit [Ping timeout: 265 seconds]
<yorickpeterse>
headius: in JRuby, are String instances stored as a form of byte buffers? To be more specific, does it have a way to get the ordinal/codepoint of an index of a String without having to copy it?
dik_dak has joined #ruby-lang
<yorickpeterse>
Basically I'm looking for a way to do something like `'fooo'.codepoint_at(1)` vs `'foo'[1].ord`
<yorickpeterse>
I can probably hack this in C but then I'd need a JRuby compatible equivalent
<headius>
they're stored as bytes, yes...so codepoint_at(n) will be O(n)ish
<yorickpeterse>
nice
<headius>
everything in JRuby is accessible from Ruby...we just don't publish the secret sauce anywhere
<yorickpeterse>
Does JRuby actually expose the underlying buffer to Ruby?
<yorickpeterse>
(in a way that doesn't require instance_variable_get and friends)
<headius>
there's no standard Ruby way to get it, but there's JRuby-specific methods
<yorickpeterse>
hm
<yorickpeterse>
Context: given a 10MB String (any size really) I want to get the codepoints in blocks, *without* having to create new String instances for every character
<yorickpeterse>
For MRI this seems to require C hacking
<headius>
hmm
<headius>
like codepoint-at-a-time?
<yorickpeterse>
Rbx has a buffer that I could pull in, but I'd end up having to do 3 different things for MRI, JRuby and Rbx
<yorickpeterse>
That however gets the codepoints as a whole, which is not efficient at all
<headius>
cough
<headius>
yes
<yorickpeterse>
So hence I hacked a little buffer which gets them out in chunks instead
<headius>
is this a limitation of ragel that it can't work with the bytes directly?
<headius>
pondering...
<yorickpeterse>
it can, but I need to get those bytes from somewhere
<yorickpeterse>
Ignore Ragel, it can do bytes so that part is fine
<headius>
String#getbyte
<yorickpeterse>
tl;dr of this issue: if Strings were to always use byte arrays I could access those bytes directly and this would be a non issue
<headius>
stream them out of that
<headius>
the interesting tokens are going to be either 7-bit ascii or text anyway
<yorickpeterse>
hmmm...I wonder how getbyte performs
<headius>
I'm just saying make the parser work with bytes and figure out codepoints as needed, rather than trying to feed it codepoints
vpretzel is now known as vpretzel|1297
<headius>
getbyte should be very fast...only the cost of a couple memory accesses and a Fixnum
<headius>
and even on JRuby, we cache a full -256..255 range of Fixnums, so it should be little more than the memory accesses
phansch has quit [Quit: WeeChat 0.4.2]
eugmill has quit [Remote host closed the connection]
eugmill has joined #ruby-lang
miqui has joined #ruby-lang
eugmill has quit [Remote host closed the connection]
<yorickpeterse>
Hm interesting, that uses both more memory and time
loincloth has joined #ruby-lang
rahul_j has joined #ruby-lang
<yorickpeterse>
oh and it seems I bork the buffer too
<yorickpeterse>
heh
shinnya has joined #ruby-lang
meizaps has quit [Ping timeout: 264 seconds]
mnngfltg has quit [Remote host closed the connection]
Varun_krishna has left #ruby-lang [#ruby-lang]
kitak_ has quit [Remote host closed the connection]
apeiros has joined #ruby-lang
momomomomo has quit [Quit: momomomomo]
vpretzel|1297 has quit [Remote host closed the connection]
vpretzel|1297 has joined #ruby-lang
<darix>
yorickpeterse: so the idea of having it pure ruby is dropped already?
<yorickpeterse>
hell no
<yorickpeterse>
interesting enough filling up an array with #getbyte actually uses more memory and is slower
nathanstitt has joined #ruby-lang
codemonk has quit [Quit: Leaving]
eugmill has joined #ruby-lang
<yorickpeterse>
though I suspect I'm overlooking something
eugmill has quit [Remote host closed the connection]
eugmill has joined #ruby-lang
<yorickpeterse>
also getbyte messes up with Unicode, hrmpf
eugmill_ has joined #ruby-lang
mistym has joined #ruby-lang
<apeiros>
with getbyte, you need to take care of MB sequences yourself
eugmill has quit [Remote host closed the connection]
<apeiros>
i.e., getbyte(N) obviously doesn't get you char at position N, additionally, it might be a byte from within a multibyte sequence.
<yorickpeterse>
yeah, so that's not really an option because I'd rather not deal with that
bawigga has joined #ruby-lang
chouhoulis has joined #ruby-lang
chouhoulis has quit [Remote host closed the connection]
<apeiros>
but iirc, all multibyte sequences have the highest bit set
<yorickpeterse>
so codepoints it is
<yorickpeterse>
but then I need to hack codepoint_at in somehow
<apeiros>
i.e., 0b1xxxxxxx is always part of a sequence
chouhoulis has joined #ruby-lang
<apeiros>
you might not have to
<apeiros>
as headius said, in html/xml, all interesting chars are 7bit
bawigga_ has joined #ruby-lang
<apeiros>
so you can just map any non-7bit char to e.g. a null-byte or anything else your parser doesn't care about
<apeiros>
s/non-7bit char/non-7bit byte/
<yorickpeterse>
eh, I don't see that helping here
marcofernandez has quit [Ping timeout: 240 seconds]
<apeiros>
you parse <foo>hägar</foo> - what do you care about hägar? not at all. that it's 6bytes doesn't matter. it's just "6x some byte I don't care about"
mistym has quit [Remote host closed the connection]
<apeiros>
so you can pass it to your parser as <foo>......</foo>
<yorickpeterse>
That will only help if further down the line that value is not used
dm78 has joined #ruby-lang
<apeiros>
o0
eugmill_ has quit [Remote host closed the connection]
<yorickpeterse>
unless I'm not understanding it
bawigga_ has quit [Client Quit]
<yorickpeterse>
considering I'm doing like 10 things atm that could be the case
bawigga has quit [Ping timeout: 240 seconds]
rahul_j has quit [Quit: rahul_j]
<headius>
yorickpeterse: none of the 7-bit tokens you're interested will appear within an MBC
<headius>
e.g. space, <>"=
<headius>
&
<headius>
there aren't many
<headius>
raw text between those tokens can be whatever encoding, you shouldn't really care
<headius>
and all identifiers will be bounded by those tokens too
Cakey has quit [Ping timeout: 276 seconds]
mykoweb has quit [Remote host closed the connection]
<headius>
once you need to pull off an identifier or string, use byteslice
<apeiros>
basically you treat your string as binary. tell your ragel machine that [0x80-0xff] is "other char/don't care"
<headius>
it doesn't have the O(n) characteristics of a normal slice
<headius>
right, like apeiros said
symm- has joined #ruby-lang
sandbags has quit [Remote host closed the connection]
<yorickpeterse>
I fail to see how that would help though, my little script already shows that using #getbyte is slower that #codepoints
<apeiros>
and "treating as binary" == .force_encoding (if necessary at all), which only sets an attribute and doesn't actually do any conversion
futilegames_ has joined #ruby-lang
<yorickpeterse>
It also uses more memory and brings the pain of having to stich back together MBs at some point
<apeiros>
o0
<yorickpeterse>
* stitch
eugmill has joined #ruby-lang
<apeiros>
yer doin it wrong!
<yorickpeterse>
yeah totally
<apeiros>
codepoints returns an array, so how can you even compare the two?
<yorickpeterse>
"interesting enough filling up an array with #getbyte actually uses more memory and is slower"
<apeiros>
also you don't have to stitch together nothing. since you don't take it apart.
<yorickpeterse>
note the part where I said filling an array with it
<apeiros>
yeah, *DONT* fill up an array.
<apeiros>
if you do that, you reimplement unpack("C*"), and poorly
karamazov has quit []
<apeiros>
you use getbyte as your - what's it in ragel? getc?
futilegames has quit [Ping timeout: 250 seconds]
futilegames_ is now known as futilegames
<yorickpeterse>
Hm, let me check if it can even handle its input in that case
<yorickpeterse>
or whether it completely fucks up
<yorickpeterse>
hm the lexer actually very much has to stitch the bytes back together
Fretta has joined #ruby-lang
momomomomo has joined #ruby-lang
<yorickpeterse>
That is, when a T_TEXT token is emitted it has to have the correct string value
<headius>
yorickpeterse: don't buffer the bytes into an array
<headius>
using getbyte you can always have current byte plus a byte offset to slice against to get real strings out
<yorickpeterse>
As an example, assume the input <foo>神</foo>
dstynchula has joined #ruby-lang
<headius>
but you won't create strings for logical tokens
<yorickpeterse>
"神" is not a single byte, as such you somehow have to stich the separate bytes back together
momomomomo has quit [Client Quit]
<yorickpeterse>
ffs, * stitch
marcofernandez has joined #ruby-lang
<headius>
yorickpeterse: but all bytes contained within that char are >127
<headius>
and none of them are XML tokens
<headius>
so...you just getbyte from token to token an then byteslices off chunks
<apeiros>
yorickpeterse: why do you think you'd have to stitch? you don't break them apart.
wallerdev has joined #ruby-lang
<yorickpeterse>
I feel I'm not following so sec
<apeiros>
your parser gets 231, 165, 158 - all 0x80-xff, doesn't care about them and they're still in one piece
<headius>
all the lexer needs to do is scan for single-byte XML tokens, track the ranges od non-token bytes between them, and turn those ranges into appropriate identifiers and strings
<yorickpeterse>
Assuming I'd make @data a String and #getbyte from it, I'd need to call String#[] there
<yorickpeterse>
and I doubt that would bring much of a benefit
<headius>
no
<headius>
you'd call String#byteslice
<apeiros>
String#[] is char based. not compatible.
<headius>
havenwood: IRB code runs within an eval context
<apeiros>
ah, that issue exhibits another issue - you can't easily just extend/include a refinement if you want it to be global
<havenwood>
headius: ah
yfeldblum has joined #ruby-lang
skade has quit [Ping timeout: 265 seconds]
<havenwood>
any thoughts on the proposed?: using Foo, global: true
<apeiros>
belly feel: don't like it
<apeiros>
haven't thought about it, though
mikecmpbll has quit [Quit: i've nodded off.]
<apeiros>
*sob*, one downside of easter: shops close. gotta go shopping :-S
<headius>
havenwood: anything that makes a refinement be used globally will severely impact performance
<apeiros>
headius: couldn't it be implemented via include/extend?
<headius>
whether refinements is a good feature or not, it's a terrible feature to optimize
<apeiros>
heh, I can imagine
<headius>
no, because using doesn't modify hierarchy
<headius>
refinements is a dynamic method-lookup scope that has to be checked for every call
<apeiros>
headius: ruby already has hidden hierarchy (singleton_class)
<headius>
yes, but you wouldn't be able to have two different usings
<headius>
it has to be local to the code, not the type
<headius>
that's why I argued for it to be made lexical
<apeiros>
huh? maybe I misunderstand the global: true bit
<havenwood>
using Foo, slow_as_hell_global_prototyping: true
marcofernandez has joined #ruby-lang
charlies_ has joined #ruby-lang
vsorlov has quit [Read error: Connection reset by peer]
<headius>
global: true would make every call site in the system check for a refinement every time you call
vsorlov has joined #ruby-lang
<apeiros>
*sob*
<headius>
havenwood: I don't like adding features that are horribly slow but useful, because people invariably use them and then complain about them being horribly slow
<apeiros>
I want infinite time, damit
<apeiros>
then I could build my toy language
<apeiros>
which is the bestestest language evarrr!
madb055 has joined #ruby-lang
charliesome has quit [Ping timeout: 240 seconds]
alexju has joined #ruby-lang
arBmind has quit [Read error: Connection reset by peer]
benlovell has quit [Ping timeout: 252 seconds]
michaeldeol has joined #ruby-lang
arBmind has joined #ruby-lang
yfeldblum has quit [Ping timeout: 250 seconds]
pixelhandler has joined #ruby-lang
sandbags has joined #ruby-lang
sandbags has quit [Changing host]
sandbags has joined #ruby-lang
brianpWins has quit [Quit: brianpWins]
wallerdev has quit [Quit: wallerdev]
mykoweb has quit [Remote host closed the connection]
rofel has quit [Remote host closed the connection]
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<wallerdev>
if only people could come to a consensus on csv haha
<imperator>
oic
<wallerdev>
its all just random rules
<apeiros>
wallerdev: yes. that's one of its biggest flaws.
<wallerdev>
yeah
<yorickpeterse>
headius: seems jruby is much, much slower
<yorickpeterse>
still going
<apeiros>
at work we have a heuristic detection for file uploads. it detects xls, xlsx, csv in macroman/windows-1252/utf-8 using , or ; as colsep and \r\n or \n as rowsep
<wallerdev>
i had to port a csv parser from another language for my previous job since it was the only one that worked with the csv files we had haha
<yorickpeterse>
5686.94 lines/second apparently
<yorickpeterse>
taking around 180 seconds in total
<apeiros>
simply because the kind of users we have couldn't be taught which is what and why the f* they should care (and IMO correctly so)
<wallerdev>
haha yeah
eugmill has quit [Remote host closed the connection]
rahul_j has quit [Quit: rahul_j]
achal has quit [Quit: Connection closed for inactivity]
marcofernandez has joined #ruby-lang
<apeiros>
I intend on finishing the C implementation of a stream and a file parser (though, I'll kick the fileparser if it isn't at least 20% faster than the streamparser).
<headius>
yorickpeterse: in order to kick the jit up a notch I set threshold to zero, which improved perf a good bit
<apeiros>
once that's done I'll try to get it a bit known
<headius>
so for this bench, there's methods getting hit too few times to JIT that slow it down
<apeiros>
and then start native implementations in various languages. should help me to finally get around learning other languages.
<headius>
like a big top-level method or something
workmad3 has quit [Ping timeout: 245 seconds]
cnivolle has joined #ruby-lang
cnivolle has quit [Remote host closed the connection]
<wallerdev>
cool
cnivolle has joined #ruby-lang
<wallerdev>
you should see if you can get it funded with VC, thats the way to get things known these days, could probably raise at least $5 mil for a csv parser
<apeiros>
the stream parser will be a cool bit of tech. it can be stopped at any position in the stream. that way it's trivial to implement any kind of non-blocking or partial parsers on top
<apeiros>
wallerdev: you're kidding me?
<wallerdev>
yes haha
<apeiros>
good.
<yorickpeterse>
headius: what option and how do I set it?
<apeiros>
sarcasm detector not completely broken.
<yorickpeterse>
hm, rbx has 5604 lines/sec
<headius>
yorickpeterse: -Xjit.threshold=0
<headius>
and I'm running on Java 8, so invokedynamic is active
<yorickpeterse>
Ah, I have 1.7
robbyoconnor has quit [Excess Flood]
<wallerdev>
although...
<apeiros>
wallerdev: I'll get back at you in 2y
<apeiros>
wallerdev: when I've successfully raise 10mio $
<headius>
yorickpeterse: quick bench put jruby at 20k lines/s, total of 49s
robbyoconnor has joined #ruby-lang
<apeiros>
;o)
<wallerdev>
you could probably have a service that takes various formats like xls, xlsx,csv, and returns a correctly formatted version
<wallerdev>
charge some monthly fee for access
<wallerdev>
lol
<apeiros>
well, the ruby version of it will actually read/write xlsx,xls,csv and ept and can convert between them
DEac-_ has quit [Read error: Connection reset by peer]
<wallerdev>
cool :)
<apeiros>
most of that work is already done
<wallerdev>
didnt realize you could parse xls
<wallerdev>
isnt it binary or something
<apeiros>
it is. thankfully somebody waded through that mess and wrote a parser in ruby
DEac- has joined #ruby-lang
elliotec has quit [Remote host closed the connection]
<wallerdev>
haha nice
<apeiros>
also it's intentionally messed up to throw off competitors (not kidding)
<wallerdev>
lol
<headius>
yorickpeterse: MRI 2.1 gets about 15k
<yorickpeterse>
huh
elliotec has joined #ruby-lang
dwknoxy is now known as dknox-lunch
<yorickpeterse>
how on earth do I get such a massive difference then
<yorickpeterse>
I do have an SSD but it shouldn't matter in this case since it's all in memory already
<headius>
beats me...this is just a plain rvm build of MRI 2.1.1
<cout>
I get 17K on 1.9
<headius>
I'm trying to run rbx but it may take longer than I have patience for
<yorickpeterse>
btw with that -X option it seems jruby is taking longer than without
<headius>
yorickpeterse: it will be slower to get going since more code compiles, but it should run faster
<imperator>
spreadsheet::excel, ah, i remember it well
<cout>
excel?
<cout>
is that like quattro pro?
<imperator>
talking about xls files
<yorickpeterse>
headius: 3249.379 lines/second, total of 313 seconds
<yorickpeterse>
so it seems JIT overhead outweights the benefits
jds has quit [Quit: Connection closed for inactivity]
<imperator>
i wrote the first excel writer i think, ported from perl, long long ago
<imperator>
(in a galaxy far far away)
<headius>
yorickpeterse: Java version? Indy?
sandbags has joined #ruby-lang
<headius>
again, I'm running off master
<headius>
rbx appears to be many times slower than MRI here
<cout>
yorickpeterse: so the behavior is just as confusing to you as to me?
kalehv has quit [Read error: Connection reset by peer]
<cout>
oh wait
<cout>
oh I'm an idiot
kalehv has joined #ruby-lang
<cout>
ok
<cout>
can't have two keys with the same value
<yorickpeterse>
depr
<yorickpeterse>
* derp
<yorickpeterse>
DAMN IT
<cout>
yeah
<yorickpeterse>
My typing sucks today
sandbags has quit [Read error: Connection reset by peer]
<imperator>
you derped when you should have herped
benlovell has quit [Ping timeout: 265 seconds]
<imperator>
i should work on my ole lib replacement, but i'm not motivated
saarinen has joined #ruby-lang
loincloth has quit [Remote host closed the connection]
dknox-lunch is now known as dknox
loincloth has joined #ruby-lang
ssb123 has quit [Ping timeout: 250 seconds]
kalehv has quit [Ping timeout: 252 seconds]
robbyoconnor has quit [Ping timeout: 258 seconds]
robmiller has joined #ruby-lang
Anon__ has joined #ruby-lang
jcs222 has quit [Quit: leaving]
<headius>
yorickpeterse: non-indy 1.7.11 performs like your numbers
Anon_ has joined #ruby-lang
<headius>
so either indy is doing something great, or the non-indy logic has a bottleneck
<headius>
I'd be inclined to the latter
Anon__ has quit [Client Quit]
<headius>
yorickpeterse: is Rubinius still going? I just checked out github pulse page
<wallerdev>
headius: are you related to jruby
<yorickpeterse>
headius: eh yes?
banisterfiend has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<yorickpeterse>
brixen is on holidays, dbussink is super busy with GH
<headius>
yorickpeterse: the pace seems to be almost zero
<headius>
ahh...well that explains some then
<headius>
2 commits in the past week, 92 for the month
<whitequark>
"are you related to jruby" heh
<yorickpeterse>
I'm swamped with Oga, there's a lot of stuff happening on the issue tracker though
<headius>
wallerdev: you could say that
<yorickpeterse>
and e.g. cremes is working on some massive IO improvements
<headius>
yeah, what's the status of his FFI-based IO stuff?
<wallerdev>
yeah names familiar haha, didnt remember if you created jruby or what
<headius>
frankly I have no idea why FFI would be better than primitives
<headius>
wallerdev: I'm one of the leads, yes
<yorickpeterse>
headius: I think he needed some feedback from brixen or something
<wallerdev>
cool stuff
<yorickpeterse>
I'd have to ask him again when he's around
<headius>
yorickpeterse: what I saw of his FFI stuff was way off from being fully compat
<yorickpeterse>
oh yeah, he started with some specific bits
<headius>
no thread safety, missing lots of encoding stuff
<yorickpeterse>
mostly to get an idea if it was worth the effort at all
<headius>
yeah
rofel has joined #ruby-lang
<headius>
logically FFI should never end up faster than a primitive, but perhaps the value will be in having less C++ rather than perf
<headius>
other than second-system effect from the FFI rewrite
eugmill has joined #ruby-lang
<headius>
yorickpeterse: mm yeah, I guess there's some issue activity
robmiller has quit [Quit: Leaving.]
<whitequark>
I wonder if you can use JIT together with FFI descriptions
<whitequark>
I mean, not go through libffi each time
zergut has left #ruby-lang [#ruby-lang]
rofel has quit [Ping timeout: 276 seconds]
sepp2k1 has joined #ruby-lang
sepp2k has quit [Ping timeout: 252 seconds]
<headius>
JRuby's FFI does that
<headius>
I'm not sure if Rubinius's does
<headius>
the FFI we're going to add to OpenJDK will do it too
<yorickpeterse>
headius: e.g. for me literally the only thing that prevents me from using Rbx, and thus tweaking it more, is Nokogiri
<yorickpeterse>
as such I'm spending as much time as I can on getting rid of that pile of crap
<yorickpeterse>
But that will take at least another 2-3 months
<yorickpeterse>
so I at least spend more time triaging issues, chasing people down, etc
<yorickpeterse>
But make no mistake, it's far from dead
<headius>
well, that's good to hear
<|jemc|>
yorickpeterse: do you know when brixen is back from holiday?
fbernier has quit [Read error: Connection reset by peer]
<headius>
yorickpeterse: anyway, back to the matter at hand... JRuby is comfortably above 20k with invokedynamic and around 3k without, where MRI does around 8k
<xybre>
yorickpeterse: Isn't Nokogiri a C extension?
Johz has quit [Ping timeout: 245 seconds]
fragamus has joined #ruby-lang
<yorickpeterse>
|jemc|: some time next week I believe
<yorickpeterse>
xybre: yes
<yorickpeterse>
headius: interesitng to see how there's such a huge difference on MRI
<xybre>
The C compatibility layer doesn't support enough of the API?
simono has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
simono has joined #ruby-lang
hahuang65 has joined #ruby-lang
benlovell has joined #ruby-lang
bzalasky has quit [Remote host closed the connection]
robmiller has joined #ruby-lang
yfeldblu_ has joined #ruby-lang
mbj has quit [Quit: leaving]
yfeldblum has quit [Ping timeout: 258 seconds]
saarinen has joined #ruby-lang
mistym has quit [Remote host closed the connection]
dm78 has quit [Remote host closed the connection]
michaeldeol has joined #ruby-lang
symm- has joined #ruby-lang
vpretzel|1292 is now known as vpretzel|964
kalehv has joined #ruby-lang
amsi has quit [Ping timeout: 264 seconds]
heftig has joined #ruby-lang
alexju has quit [Remote host closed the connection]
cnivolle has quit [Ping timeout: 246 seconds]
achal has joined #ruby-lang
agarie has quit [Read error: Connection reset by peer]
<xybre>
Is there a data_structures gem?
agarie has joined #ruby-lang
kalehv has quit [Ping timeout: 240 seconds]
imperator has quit [Quit: Valete!]
wallerdev has joined #ruby-lang
_ht has quit [Remote host closed the connection]
saarinen has quit [Quit: saarinen]
nisstyre has joined #ruby-lang
arBmind has joined #ruby-lang
futilegames has quit [Quit: futilegames]
cnivolle has joined #ruby-lang
fragamus has quit [Quit: Computer has gone to sleep.]
Anon_ has quit [Quit: Leaving]
rofel has joined #ruby-lang
elliotec has quit [Remote host closed the connection]
elliotec has joined #ruby-lang
rofel has quit [Ping timeout: 265 seconds]
melter has quit [Quit: Client exiting]
miqui has quit [Remote host closed the connection]
elliotec has quit [Ping timeout: 258 seconds]
ur5us has joined #ruby-lang
<|jemc|>
so, if I'm using ragel to tokenize/lex the source string for a language parser, is there any reason I can't or shouldn't use ragel again as the parser for those tokens?
<|jemc|>
I'm thinking something like converting each token to a byte value that ragel can recognize
<|jemc|>
is there a reason to use racc or some other more traditional tool here instead of just using two layers of ragel?
<whitequark>
ragel recognizes regular languages, racc is LALR(1)
<whitequark>
you can use ragel for languages with zero lookahead, I think. but those are scarce
<|jemc|>
whitequark: I'm still processing these concepts, so forgive me if I sound ignorant, but doesn't ragel handle non-regular languages if you call/goto between machine instantiations?
ylluminate has joined #ruby-lang
<whitequark>
well, yes, but it's a lot of pointless work
<whitequark>
you're doing racc's job by hand
<|jemc|>
yeah, it was starting to seem like I was doing more than I should be in that regard - I just thought I wasn't quite using ragel correctly
<|jemc|>
the parsing I'm trying to do is pretty far from context-free
<|jemc|>
in fact, the end goal is to host nested contexts in entirely different and runtime-configurable grammars through heredoc-style delimiting and multiple passes with different parsers
<headius>
I hate parsing
<|jemc|>
but the runtime-configurable grammars will probably all be PEG to keep it simple
ikrima has joined #ruby-lang
<whitequark>
|jemc|: well, if you like the code you have with ragel, by all means go for it.
<whitequark>
but racc can often make it ridiculously simpler
mistym has joined #ruby-lang
mattsp1290 has joined #ruby-lang
<|jemc|>
whitequark: I don't
<|jemc|>
but should I still be tokenizing with ragel if I use racc to parse the tokens?
ur5us has quit [Remote host closed the connection]
<|jemc|>
I suppose I should look into rex as well
cnivolle has quit [Remote host closed the connection]
benlovell has quit [Ping timeout: 240 seconds]
alexju has joined #ruby-lang
<whitequark>
|jemc|: yes, you should
<whitequark>
er, should be tokenizing.
<whitequark>
see, the reason you need a separate lexing step is that racc recognizes LALR(*1*) grammars
<whitequark>
it can only see a single token of lookahead. so you can't use characters as tokens (for practically all interesting languages)
<whitequark>
if it was LALR(n), you could directly feed characters to racc. but this is not how it works, for some obscure reasons
yfeldblu_ has quit [Remote host closed the connection]
<|jemc|>
whitequark: Is there a convenient pattern for marking specific parts of a sub-machine inside of a machine instantiation so that my final action can know the positions of various parts of the match of the sub-machine?
yfeldblum has joined #ruby-lang
<|jemc|>
(in ragel)
<|jemc|>
for example.
agarie has quit [Remote host closed the connection]
<whitequark>
and then you'll have indexes in t1,t2
<|jemc|>
not knowing how to do that is part of the reason I've had machine-instantiation sprawl
<|jemc|>
yeah, part of what was hanging me up about that technique (using machine definition actions) was that I didn't necessarily want that action to happen every time I ran across a constant, for example
<|jemc|>
but the realization I just had was:
<|jemc|>
I could easily have two distinct machine definitions that define a constant in the same way, but with different actions, and I use them in different parts of the machine instantiations
jacky has quit [Excess Flood]
<|jemc|>
so that I use the machine that invokes the action I want for that combination of machines in that context
rofel has joined #ruby-lang
cnivolle has joined #ruby-lang
Guest6575 has joined #ruby-lang
<whitequark>
yep
Guest6575 has quit [Excess Flood]
amsi has joined #ruby-lang
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
michaeldeol has joined #ruby-lang
Guest86890 has joined #ruby-lang
mehlah has joined #ruby-lang
elia has joined #ruby-lang
Guest86890 is now known as jackyalcine
jackyalcine has quit [Changing host]
jackyalcine has joined #ruby-lang
jackyalcine is now known as jacky
robmiller has quit [Quit: Leaving.]
dik_dak has quit [Quit: Leaving]
solars has quit [Ping timeout: 265 seconds]
elia has quit [Client Quit]
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
LMity has joined #ruby-lang
bzalasky has joined #ruby-lang
elliotec has quit [Read error: Connection reset by peer]
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
elliotec has joined #ruby-lang
SilkFox has quit [Ping timeout: 276 seconds]
nisstyre has quit [Quit: WeeChat 0.4.3]
caral has quit [Quit: caral]
emaxi has quit [Remote host closed the connection]
emaxi has joined #ruby-lang
bawigga has quit []
AncientAmateur has quit [Remote host closed the connection]
__butch__ has quit [Quit: Leaving.]
bawigga has joined #ruby-lang
elia has joined #ruby-lang
sarkyniin has quit [Quit: Quitte]
emaxi has quit [Ping timeout: 276 seconds]
ssb123 has quit [Remote host closed the connection]
jason__ has quit [Remote host closed the connection]
bjh13 has quit [Quit: leaving]
<wallerdev>
zenspider: this is awesome haha
postmodern has joined #ruby-lang
|jemc| has quit [Quit: WeeChat 0.4.1]
yfeldblu_ has quit [Remote host closed the connection]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
enebo has quit [Quit: enebo]
ikrima has joined #ruby-lang
hgl_ has quit [Quit: Computer has gone to sleep.]
omosoj has quit [Ping timeout: 252 seconds]
emaxi has joined #ruby-lang
jason__ has joined #ruby-lang
SilkFox has joined #ruby-lang
|jemc| has joined #ruby-lang
jason__ has quit [Remote host closed the connection]
hgl_ has joined #ruby-lang
hgl_ has quit [Client Quit]
elliotec has quit [Remote host closed the connection]
jason__ has joined #ruby-lang
rofel has quit [Remote host closed the connection]
yfeldblum has joined #ruby-lang
achal has quit [Quit: Connection closed for inactivity]
ssb123 has joined #ruby-lang
<zenspider>
wallerdev: a bit addictive. :D
<wallerdev>
haha yeah had to email the link to myself, cant play it all day at work unfortunately -_-
jason__ has quit [Remote host closed the connection]
dstynchu_ has joined #ruby-lang
dstynchu_ has quit [Read error: Connection reset by peer]
dstynchu_ has joined #ruby-lang
dstynchula has quit [Read error: Connection reset by peer]
dstynchu_ has quit [Read error: Connection reset by peer]
<zenspider>
I can! unfortunately
bzalasky has quit [Remote host closed the connection]
arBmind has quit [Quit: Leaving.]
tbuehlmann has quit [Remote host closed the connection]
ssb123 has quit [Ping timeout: 276 seconds]
elliotec has joined #ruby-lang
<xybre>
Took me a while to figure out how to beat level 2 with only 4 characters, I'm not a JS guy, so when I realized it, I was like "doh"
herpless has quit [Quit: Connection closed for inactivity]
bzalasky has joined #ruby-lang
dstynchula has joined #ruby-lang
ylluminate` has joined #ruby-lang
ikrima has quit [Ping timeout: 252 seconds]
<zenspider>
xybre: I didn't bother to figure it out. don't remember what I did tho
ylluminate_ has joined #ruby-lang
symm- has quit [Read error: Connection reset by peer]
<xybre>
zenspider: I started with if(false) and realized JS has block comments.
ylluminate has quit [Ping timeout: 250 seconds]
kitak has quit [Remote host closed the connection]
ylluminate` has quit [Ping timeout: 255 seconds]
kitak has joined #ruby-lang
symm- has joined #ruby-lang
<zenspider>
oh. hah
<zenspider>
derp
<wallerdev>
spoilers :p
nathanstitt has quit [Quit: I growing sleepy]
<xybre>
Oops
elliotec has quit [Remote host closed the connection]
AncientAmateur has joined #ruby-lang
symm- has quit [Read error: Connection reset by peer]
<yorickpeterse>
|jemc|: re ragel before I head off, Ragel can't build trees
<yorickpeterse>
at least not easily
<yorickpeterse>
|jemc|: you use Ragel (or similar) to produce a single level, stream of tokens. Racc and others can then be used to turn that into a tree
ikrima has joined #ruby-lang
bawigga has quit []
symm- has joined #ruby-lang
mehlah has quit [Quit: Leaving...]
<|jemc|>
thanks, yorickpeterse; I think I'm grasping the typical flow and usage of tools a bit better now
btiefert has joined #ruby-lang
shinnya has joined #ruby-lang
<yorickpeterse>
it's pretty painful to get into the whole parsing scene
hahuang65 has quit [Ping timeout: 265 seconds]
<|jemc|>
I do enjoy a good mental reshaping every now and then though
* |jemc|
mumbles something about personal betterment
<t4nk337>
so i just did 'brew uninstall ruby', then reinstalled it
<t4nk337>
same problem when installing a gem
yfeldblum has joined #ruby-lang
<zenspider>
huh.
<t4nk337>
so whats the difference in using brew to install ruby vs rvm?
<zenspider>
the code in question for creating the symlinks hasn't been changed since 2012-05
elliotec has quit [Ping timeout: 258 seconds]
<zenspider>
personally I'm not a fan of rvm because it is a big complicated mess
<zenspider>
I use rbenv sometimes, mostly I just use my own stuff
<zenspider>
I should say, rbenv + ruby_build
<t4nk337>
i don't think i've ever done a ruby install without issues
<postmodern>
t4nk337, brew install installs into /usr/local which should already be in $PATH
<zenspider>
in this case, the symlink shit is a bit ... clever. They're doing it to externalize the gems from the Cellar install
<zenspider>
but it isn't new at all, so I'm guessing the problem is over on the rubygems side
<t4nk337>
what's weird is i've installed ruby before using homebrew and it worked
<postmodern>
t4nk337, rvm/rbenv have their own build scripts for installing rubies into $HOME, and will manipulate $PATH to select the right one. rbenv also uses binstubs
<t4nk337>
only this time i updated my os recently
<zenspider>
t4nk337: right, but maybe not with that version of rubygems
agarie has joined #ruby-lang
<zenspider>
hah. _I_ wrote the line in question on the rubygems side, and it hasn't changed since 2011
<zenspider>
so... wtf
bzalasky has joined #ruby-lang
<t4nk337>
lol
<t4nk337>
should i downgrade ruby gems?
<zenspider>
t4nk337: I don't know what to suggest. this combo should be working fine or we'd have a shit tonne of bug reports