cschneid_ has quit [Remote host closed the connection]
nacsurte has quit [Ping timeout: 260 seconds]
enterprisey has joined #ruby
Trynemjoel has joined #ruby
Danny_ has quit [Remote host closed the connection]
cschneid_ has joined #ruby
cschneid_ has quit [Ping timeout: 260 seconds]
yeticry_ has quit [Ping timeout: 268 seconds]
harfangk has joined #ruby
aarwine has quit [Ping timeout: 276 seconds]
rkazak has quit [Quit: Sleep.....ing....]
creshiem has quit [Quit: WeeChat 1.8]
hutch34 has joined #ruby
astrobunny has joined #ruby
carterdea has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
carterdea has joined #ruby
hutch34 has quit [Ping timeout: 276 seconds]
beilabs__ has joined #ruby
eljimmy has quit [Quit: This computer has gone to sleep]
eljimmy has joined #ruby
enterprisey has quit [Remote host closed the connection]
ascarter has joined #ruby
nicesignal has quit [Ping timeout: 240 seconds]
<ledestin>
In the Rails itself, how do I enable output via puts?
<ledestin>
Rails framework code
nacsurte has joined #ruby
Trynemjoel has quit [Ping timeout: 276 seconds]
ascarter has quit [Ping timeout: 268 seconds]
mim1k has joined #ruby
jnollette has joined #ruby
Trynemjoel has joined #ruby
nicesignal has joined #ruby
nacsurte has quit [Ping timeout: 240 seconds]
mim1k has quit [Ping timeout: 240 seconds]
Coldblackice_ has joined #ruby
Danny__ has joined #ruby
chouhoulis has quit [Remote host closed the connection]
Coldblackice has quit [Ping timeout: 260 seconds]
Danny__ has quit [Ping timeout: 240 seconds]
Coldblackice_ has quit [Max SendQ exceeded]
<havenwood>
ledestin: Rails.logger.info
Coldblackice_ has joined #ruby
<ledestin>
havenwood no luck witht hat
<havenwood>
ledestin: There's a #RubyOnRails channel for Rails-specific questions.
<ledestin>
that's a dump
<havenwood>
ledestin: No luck in that it's not logging to stdout?
<ledestin>
but thanks anyway
<havenwood>
ledestin: A dump?
<ledestin>
not logging anywhere
<havenwood>
ledestin: In dev or prod?
<ledestin>
havenwood that's a crappy channel
<havenwood>
ledestin: How so?
<havenwood>
ledestin: Which environment, development, test, production?
<ledestin>
havenwood Rails framework itself
rippa has joined #ruby
<ledestin>
I'm debugging some Rails framework code
boombox_ has quit [Remote host closed the connection]
<havenwood>
ledestin: How about a `binding.pry` instead of stdout?
nofxxxx has joined #ruby
<havenwood>
Or `binding.irb` these days if you prefer.
<ledestin>
havenwood people that were unhappy with that channel made RoR slack, and that's great. But that channel I hoped I'd never go to again. Not friendly, rude, not helpful.
<havenwood>
It's nice that Ruby 2.4 got `binding.irb`.
r3vDev has joined #ruby
<havenwood>
ledestin: If you're not seeing Kernel#puts and don't know why, you might look at what STDOUT is.
<havenwood>
ledestin: Then sanity check that it works: STDOUT.puts
<havenwood>
Or check `$stdout` and : $stdout.puts
<havenwood>
ledestin: I don't get from what you've said why you're not seeing the output you expect.
nofxxx has quit [Ping timeout: 260 seconds]
<havenwood>
I'm curious if you see STDERR output. How about: warn
<havenwood>
Or STDERR.puts, $stderr.puts, however.
<ledestin>
havenwood it's my fault. it was using source code from a gem
<havenwood>
ledestin: aha
<ledestin>
let me try it the proper way
govg has joined #ruby
comet23 has joined #ruby
<comet23>
i started reading the rails 4 book, it's well written :)
<comet23>
rails 4 in action
Ropeney has joined #ruby
<comet23>
i have a quick question for real life development.... this is my function https://repl.it/JBqN/0
<comet23>
should i delegate error checking to a different function or is it okay to keep it there as-is?
<havenwood>
comet23: There are a few problems with that method. The first is it doesn't get my age right!
<comet23>
no, this assumes the year is 2003
yogg-saron has joined #ruby
<havenwood>
comet23: When in the year?
<comet23>
it's on line 2 i think
<havenwood>
comet23: Birthdays don't wait 'till the end of the year then all happen at once!
<comet23>
yes, line 2
<havenwood>
People born in the same year might be different ages.
<comet23>
i don't celebrate birthdays
<havenwood>
Nonetheless.
<comet23>
but that's besides the point haha
<comet23>
so how can two people being born... oh i get it
<havenwood>
If it's beside the point then the method is missnamed. ;-P
<comet23>
well, i am taking a course from flatironschool, they were nice enough to offer a 1 month free trial of their entire bootcamp (normally $149, but free for a month if you link to github education)
<havenwood>
comet23: Do you count someone as a day older the second the clock strikes midnight?
<havenwood>
comet23: Have they covered tests at all yet?
<comet23>
a lot of people surprisingly don't know the time they were born
<comet23>
my code passes the tests
<comet23>
i don't think their bootcamp is worth $149, but that's my opinion, but i am going to finish it in a week :)
<comet23>
it's $149 a month to be clear and they say it takes 6 months to complete on average
<havenwood>
comet23: Normally you'd `raise` if something exceptional happened.
<comet23>
oh, thank you
<havenwood>
comet23: If you just want to warn about it use `warn` instead of `puts` so it goes to STDERR.
<havenwood>
Kernel#warn also respects disabling warnings.
<havenwood>
If you want to warn then exit with a nonzero status there's `abort 'flee at once!'`.
<havenwood>
comet23: Are negative ages forbidden?
<comet23>
no, i just added that extra thought
<havenwood>
When I was -5 the programming scene was just heating up.
<comet23>
negative age doesn't make sense, hopefully one day people will figure out how to solve that problem and make it a thing
ketan has joined #ruby
<havenwood>
comet23: I think we just say it as "five years before I was born" instead of "when I was negative five".
yogg-saron has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<comet23>
warn isn't working on repl
<kruppm>
I want to overwrite a method `find`, defined in a module inside a class definition: https://goo.gl/Q4FVEn
<kruppm>
I usually monkey-patch stuff like this with `prepend`, but that does not seem to work here, with modules inside classes
eb0t_ has quit [Ping timeout: 255 seconds]
<kruppm>
is there a way to monkey-patch this method without re-opening the class?
def_jam has quit [Ping timeout: 240 seconds]
<comet23>
i read that monkey-patching is a horrible, horrible, idea and you should never ever do it
<havenwood>
comet23: That's not true.
<kruppm>
comet23: ye, but it is how it is. i cannot rewrite a ~50k LoC project just to fix raisl 5 compatibility :)
<kruppm>
rails*
<havenwood>
comet23: Freedom patching is sometimes okay, though it's fair to say you can't just monkey patch core classes in libraries.
<comet23>
oh, now that makes sense
<kruppm>
So, is there a reason why `ActionView::LookupContext::ViewPaths.prepend` does not seem to work as (I) expected?
<comet23>
what does it output?
<kruppm>
.ancestors shows the patch, but a call to .find() still calls the original method
<havenwood>
comet23: There're refinements these days, which actually do end up being handy. They let you monkeypatch just within the file and class you're in.
<comet23>
it sounds like find's return value might be the culprit
<kruppm>
comet23: no, i need to extend the function, to handle some edge-cases (specifically, different lookup paths, in certain cases)
<kruppm>
but the "prepended" method never gets called, ActionView still calls the original method for some reason, altough, ActionView::LookupContext::ViewPaths.ancestors DOES show the patch
<havenwood>
kruppm: I'm curious why prepend isn't working. You might try the #RubyOnRails channel as well.
<kruppm>
thought there might be some scoping general issues with modules defined inside classes.
<kruppm>
that's why i asked here :)
<havenwood>
kruppm: Nothing that I'm aware of. Let me sanity check real quick.
<havenwood>
kruppm: Works for me.
xall has joined #ruby
<havenwood>
>> class X; module Y; def foo; :foo end end end; module Z; def foo; :bar end end; X::Y.prepend Z; include X::Y; foo
<comet23>
i'm more than impressed and i would like to learn how you do that :)
<baweaver>
Basically reading through that a lot.
<dminuoso>
comet23: baweaver does not qualify as people.
<dminuoso>
baweaver is... something else.
<sekmo>
I think that it could be improved with some object oriented programming
<baweaver>
Basically it reads: Take each 3 elements, transform them to join them with ' | ' ('x | | o' for instance), then join that with the line delimiters.
<dminuoso>
sekmo: This is actually pure functional programming mixed in with Smalltalk.
<baweaver>
dminuoso's not much of one for smalltalk
<dminuoso>
That was puntastic.
* baweaver
rolls laughing
<baweaver>
Anyways, as far as OO, baby steps
<comet23>
but what you just did and what radar did with those one lines of confusing code is just so impressive
<comet23>
i want to learn that
<baweaver>
In this specific instance an object isn't needed yet. It only requires outputting of the board.
<dminuoso>
tau: There is however a Ruby feature almost nobody uses..
<tau>
i thought it would gain some benefits.
<tau>
dminuoso whats it?
<dminuoso>
tau: Refinements.
<tau>
dminuoso more strictly speaking, what would it be reinements?
<tau>
refinements*
<tau>
in the context.
<dminuoso>
tau: More strictly speaking it's a feature you will have to consult the Ruby documentation for.
<tau>
i see.
<dminuoso>
&ri refinements
<`derpy>
No results
* dminuoso
kicks `derpy with adaedra
Fernando-Basso has joined #ruby
rohitpaulk has quit [Ping timeout: 255 seconds]
jameser has quit [Ping timeout: 240 seconds]
apparition has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<zenspider>
tau: if you look at the code for lax, I highly doubt the're extending their own built in types... they have a parser of some sort, and that's gonna make a model of the input, and then you'll do something with it to generate output.
nacsurte has joined #ruby
cschneid_ has joined #ruby
jaruga_________ has quit [Ping timeout: 260 seconds]
_joes_ has joined #ruby
jaruga_________ has joined #ruby
cschneid_ has quit [Ping timeout: 246 seconds]
nacsurte has quit [Ping timeout: 276 seconds]
<tau>
zenspider yes. i know.
<tau>
zenspider i was wondering if it were possible to avoid parsing in ruby(i was the one who wrote lax).
<dminuoso>
Parsing ruby with ruby.
<tau>
zenspider it seems it can be done but it wouldnt be possible to be used in irb.
<tau>
i just need to overload the + for Integer.
<tau>
then ask for a string then build the ast then eval it.
astrobunny has quit [Remote host closed the connection]
<zenspider>
"i just need"... no, that's not just what you need.
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
ur5us has quit [Read error: Connection reset by peer]
ur5us has joined #ruby
<tau>
zenspider yea, i meant 'sort of'.
<zenspider>
tau: you're just parsing straight algebraic expressions?
<tau>
zenspider yea.
<tau>
i believe that if i implement lax in ruby then i could better extend it with functionalities.
<tau>
although i'm not sure yet.
<tau>
i have to think more of the gains in rewriting it in ruby.
<zenspider>
meaning handling more maths?
<tau>
zenspider exact.
<zenspider>
or just easier to write the impl in?
<tau>
handling more maths.
ascarter has joined #ruby
<tau>
and turning the implementation easier somehow too i guess.
<zenspider>
you're gonna need a parser
<zenspider>
example: lax -c '(x-3)(x+y)'
<tau>
hmm
<tau>
well..
<zenspider>
seems like a simple lexer & parser for this shouldn't be hard...
vondruch has quit [Ping timeout: 258 seconds]
jzigmund has quit [Ping timeout: 246 seconds]
jaruga_________ has quit [Ping timeout: 260 seconds]
<tau>
thats possible in python because we have __call__.
<tau>
i mean with no parsing.
<zenspider>
I don't know what tokenize does... but it's at least lexing everything out and creating you nodes for those types...
<herwin>
I'm not sure if it is intended to be able to parse ruby math expression, but in that case you could just use Ripper to create the AST
<zenspider>
no, don't think you can
<zenspider>
or, even if you can, you shouldn't
<Papierkorb>
tau: So I get it correctly, that you intend to parse some math expression, and then "compile" that into LaTex?
<tau>
papierkorb yea.
ascarter has quit [Ping timeout: 276 seconds]
<zenspider>
yeah... the mathier you get, the less ruby you get: #<Racc::ParseError: env:1 :: parse error on value "(" (tLPAREN2)>
<Papierkorb>
tau: In that case, I also want to recommend writing a custom parser for it, you'll most likely end up writing a recursive-descent LL parser. it's not too hard once you got the hang of it, and is great to know for projects to come
alex`` has joined #ruby
<tau>
papierkorb yea, nice.
nobitanobi has quit [Remote host closed the connection]
<Papierkorb>
tau: write a simple calculator first. this is also a really common introductory example parser, so you're actually lucky here. And once that works correctly, make it emit LaTeX code instead of calculating
<tau>
thats a good approach.
<tau>
to start it :D
<tau>
okay guys, thank you for the insight.
<tau>
i gotta be off now.
vondruch has joined #ruby
jaruga_________ has joined #ruby
dionysus69 has quit [Remote host closed the connection]
vondruch has quit [Client Quit]
vondruch has joined #ruby
jaruga_________ has quit [Quit: jaruga_________]
lxsameer has quit [Read error: Connection reset by peer]
vondruch has quit [Quit: vondruch]
dasher00 has joined #ruby
DoubleMalt has joined #ruby
DoubleMalt has quit [Client Quit]
vondruch has joined #ruby
vondruch has quit [Remote host closed the connection]
vondruch has joined #ruby
vondruch has quit [Quit: vondruch]
mim1k has quit [Ping timeout: 260 seconds]
mim1k has joined #ruby
apparition has joined #ruby
Danny_ has joined #ruby
ponzii has joined #ruby
ponzii has left #ruby [#ruby]
vondruch has joined #ruby
Danny_ has quit [Remote host closed the connection]
Danny_ has joined #ruby
vondruch has quit [Client Quit]
vondruch has joined #ruby
Danny_ has quit [Remote host closed the connection]
PatrikasZvaigzde has quit [Ping timeout: 240 seconds]
jaruga_________ has joined #ruby
Danny_ has joined #ruby
jenrzzz has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
ldnunes has joined #ruby
Danny_ has quit [Client Quit]
__urux__ has joined #ruby
swills has joined #ruby
ur5us has quit [Remote host closed the connection]
jenrzzz has quit [Ping timeout: 268 seconds]
ur5us has joined #ruby
jphase_ has quit [Remote host closed the connection]
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
ascarter has quit [Ping timeout: 240 seconds]
ur5us has quit [Ping timeout: 240 seconds]
synthroid has joined #ruby
GinoMan has joined #ruby
jaruga________ has joined #ruby
jaruga_________ has quit [Quit: jaruga_________]
Vel_ has joined #ruby
psychicist__ has quit [Ping timeout: 260 seconds]
GinoMan2440 has joined #ruby
vuoto has quit [Quit: Lost terminal]
milardovich has quit [Remote host closed the connection]
<Vel_>
In my app i am passing the params object to model class. But to test the model in rpsec i am not sure how to create params. is there a way to create params in model spec
milardovich has joined #ruby
sepp2k has joined #ruby
vali has joined #ruby
alex`` has quit [Quit: WeeChat 1.8]
milardovich has quit [Remote host closed the connection]
GinoMan has quit [Ping timeout: 276 seconds]
tau has quit [Ping timeout: 276 seconds]
ldnunes has quit [Ping timeout: 255 seconds]
simmaniac has joined #ruby
ledestin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Silthias1 has joined #ruby
Silthias has quit [Ping timeout: 260 seconds]
sysvalve has quit [Ping timeout: 240 seconds]
<dminuoso>
?rails Vel_
<ruby[bot]>
Vel_: Please join #RubyOnRails for Rails questions. You need to be identified with NickServ, see /msg NickServ HELP
alex`` has joined #ruby
Vel_ has quit [Ping timeout: 260 seconds]
nobitanobi has joined #ruby
ldnunes has joined #ruby
jameser has joined #ruby
dropsh0t has joined #ruby
jameser has quit [Client Quit]
DoubleMalt has joined #ruby
minimalism has joined #ruby
roshanavand has quit [Remote host closed the connection]
jameser has joined #ruby
rohitpaulk has joined #ruby
Kug3lis_off is now known as Kug3lis
nacsurte has joined #ruby
DoubleMalt has quit [Ping timeout: 240 seconds]
nacsurte has quit [Ping timeout: 255 seconds]
zapata has quit [Ping timeout: 255 seconds]
mim1k has joined #ruby
bmurt has joined #ruby
jokke has quit [Quit: WeeChat 1.7.1]
Mortomes|Work has quit [Ping timeout: 260 seconds]
jokke has joined #ruby
shinnya has joined #ruby
umaaji has quit [Quit: Leaving...]
rikkipitt has quit [Quit: Leaving...]
DLSteve has quit [Quit: All rise, the honorable DLSteve has left the channel.]
haylon has joined #ruby
workmad3 has joined #ruby
Kug3lis is now known as Kug3lis_off
Kug3lis_off is now known as Kug3lis
lxsameer has joined #ruby
rohitpaulk has quit [Ping timeout: 255 seconds]
apparition has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
TheBrayn has quit [Quit: WeeChat 1.8]
ascarter has joined #ruby
TheBrayn has joined #ruby
ascarter has quit [Ping timeout: 255 seconds]
TheBrayn has quit [Client Quit]
dionysus69 has joined #ruby
psychicist__ has joined #ruby
TheBrayn has joined #ruby
TheBrayn has quit [Client Quit]
milardovich has joined #ruby
r3vDev has joined #ruby
TheBrayn has joined #ruby
iomotoko has quit [Quit: leaving]
uZiel has joined #ruby
vali has quit [Quit: vali]
rohitpaulk has joined #ruby
eljimmy has joined #ruby
uZiel has quit [Ping timeout: 248 seconds]
workmad3 has quit [Ping timeout: 240 seconds]
fergal has joined #ruby
<dminuoso>
>> instance_eval &->(){}
<ruby[bot]>
dminuoso: # => wrong number of arguments (given 1, expected 0) (ArgumentError) ...check link for more (https://eval.in/822461)
<dminuoso>
Can someone explain this to me?
<dminuoso>
What the heck? Is this a bug?
<dminuoso>
It clearly must be a bug.
DoubleMalt has joined #ruby
tgragnato has joined #ruby
gnufied has joined #ruby
gnufied has quit [Client Quit]
chimkan has joined #ruby
chimkan has left #ruby [#ruby]
futilegames has joined #ruby
DLSteve has joined #ruby
patarr has joined #ruby
chimkan has joined #ruby
Silthias1 has left #ruby [#ruby]
uZiel has joined #ruby
<dminuoso>
Oh. Haha.
<dminuoso>
Shoot me.
rfoust has quit [Ping timeout: 240 seconds]
milardovich has quit [Read error: Connection reset by peer]
oleo has joined #ruby
nacsurte has joined #ruby
__urux__ has quit [Quit: __urux__]
judofyr has quit [Remote host closed the connection]
judofyr has joined #ruby
chouhoulis has joined #ruby
nacsurte has quit [Ping timeout: 240 seconds]
gizmore has joined #ruby
jenrzzz has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
sanguisdex has joined #ruby
judofyr has quit [Ping timeout: 240 seconds]
<sanguisdex>
hi there low hanging question for yall. How can I install a gem from a repo/branch with the cli `gem install` command?
<ljarvis>
sanguisdex: you can't
<sanguisdex>
ljarvis: thanks that was easy.
<ljarvis>
you should download the repo, `gem build foo.gemspec` and then gem install the resulting .gem file
apparition has joined #ruby
beilabs__ has quit [Read error: Connection timed out]
apparition has quit [Client Quit]
jenrzzz has quit [Ping timeout: 240 seconds]
Silthias has joined #ruby
zapata has joined #ruby
yogg-saron has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jameser has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
chouhoulis has quit [Remote host closed the connection]
chouhoulis has joined #ruby
my123_ has quit [Ping timeout: 255 seconds]
chalkmonster has joined #ruby
my123 has joined #ruby
my123 has joined #ruby
swills has quit [Quit: Leaving]
DoubleMalt has quit [Ping timeout: 276 seconds]
mradmacher has quit [Quit: WeeChat 1.4]
<Burgestrand>
dminuoso I assume the issue was that `instance_eval` passes the object as the first parameter to the given block (if given a block), and that `->() { }` lambdas are strict in their arguments?
<Mon_Ouie>
Well at least I imagine that's just the verification code and not a password
<ljarvis>
ya
<Burgestrand>
hunter2!
rfoust has joined #ruby
<travisgrib>
haha yes
rivalomega has joined #ruby
travisgrib has quit [Quit: Page closed]
dionysus69 has quit [Remote host closed the connection]
Kug3lis has quit [Ping timeout: 240 seconds]
rfoust has quit [Ping timeout: 246 seconds]
dionysus69 has joined #ruby
mim1k has joined #ruby
mathys has quit [Remote host closed the connection]
rivalomega has quit [Ping timeout: 240 seconds]
rfoust has joined #ruby
rohitpaulk has quit [Ping timeout: 246 seconds]
mathys has joined #ruby
travisgrib has joined #ruby
djbjd has joined #ruby
chouhoul_ has joined #ruby
dionysus69 has quit [Remote host closed the connection]
<travisgrib>
guys, in my project’s gemspec, i specify development and runtime dependencies. is there an equivalent fo specifying these types of dependencies in a Gemfile?
dionysus69 has joined #ruby
urux has quit [Ping timeout: 260 seconds]
dionysus69 has quit [Remote host closed the connection]
<travisgrib>
canton7: so would the omission of a group correlate to a runtime dependency?
<canton7>
not sure what you're asking
<canton7>
oh, defining a dependency outside of any groups, rather than using 'bundle install --without'. Yes. Dependencies not in a group are always required
nacsurte has joined #ruby
simmaniac has quit [Ping timeout: 268 seconds]
runescape07rsps has joined #ruby
lolzorplox has joined #ruby
lolzorplox has quit [Client Quit]
isBEKaml has joined #ruby
nacsurte has quit [Ping timeout: 276 seconds]
rfoust has joined #ruby
dionysus69 has joined #ruby
catphish has joined #ruby
rohitpaulk has joined #ruby
ResidentBiscuit has joined #ruby
ResidentBiscuit has quit [Max SendQ exceeded]
ResidentBiscuit has joined #ruby
cam27 has joined #ruby
<travisgrib>
canton7: cool, thanks!
Burgestrand has quit [Quit: Closing time!]
Burgestrand has joined #ruby
ferr has quit [Quit: WeeChat 1.8]
Burgestrand has quit [Client Quit]
theunraveler has joined #ruby
rivalomega has joined #ruby
<catphish>
is there going to be an efficient way to unpack a 6 byte string into a 64 bit number? ie: "\0\0\0\0\0\1".unpack('Q>')
rfoust has quit [Ping timeout: 246 seconds]
djbjd has quit [Quit: djbjd]
<catphish>
i'm going to be doing this a lot, except the code above won't work, because it's expecting 8 bytes
rfoust has joined #ruby
<matthewd>
catphish: Seems pretty easy to benchmark
enterprisey has joined #ruby
<catphish>
that's true, 2 options occur to me: #bytes and math, or #rjust and unpack
cschneid_ has joined #ruby
<catphish>
my money's on the first
d10n-work has joined #ruby
cschneid_ has quit [Remote host closed the connection]
<im314ous>
just out of curiosity but what are you programming, catphish? :)
ascarter has quit [Ping timeout: 255 seconds]
<catphish>
well it's a very small part of a large project, but i have a file, the file contains pointers to other parts of the file, due to the size of the file, these pointers want to be 6 bytes long
<matthewd>
Omitting the (0) would save a couple of cycles, though I don't know it'd even be measurable
<im314ous>
hm, sounds interesting!
<catphish>
so: position = file.read(6); file.seek(unpack(position))
GodFather has quit [Remote host closed the connection]
rfoust has quit [Ping timeout: 240 seconds]
<matthewd>
catphish: Are you inventing your own file format? :/
elsevero has joined #ruby
<catphish>
i am
mim1k has joined #ruby
<catphish>
couldn't find anything off the shelf for version block storage :)
GodFather has joined #ruby
<im314ous>
that's pretty cool. fucking difficult, but cool
andikr has quit [Remote host closed the connection]
_joes_ has quit []
<matthewd>
It sounds suspiciously similar to a filesystem, at a glance
aupadhye has quit [Ping timeout: 240 seconds]
<catphish>
it is distressingly like a filesystem, sadly it's not a filesyste, else i'd love to just use a filesystem :)
nacsurte has quit [Ping timeout: 240 seconds]
rfoust has joined #ruby
dionysus69 has quit [Remote host closed the connection]
<catphish>
it's versioned
<catphish>
and only has one file
<catphish>
the idea is to track changes to that "file"
ptx0 is now known as kash
<catphish>
and the inverse: [int].pack('Q>')[2,6]
<catphish>
not sure there's a better way to do that
<catphish>
in any case, both work so will stick with it unless they become a bottleneck
<catphish>
thanks
dionysus69 has joined #ruby
Rodya_ has quit [Remote host closed the connection]
chalkmonster has quit [Ping timeout: 240 seconds]
rfoust has quit [Read error: Connection reset by peer]
rfoust has joined #ruby
synthroid has quit [Remote host closed the connection]
chouhoul_ has quit [Remote host closed the connection]
synthroid has joined #ruby
cpruitt has joined #ruby
ltem has joined #ruby
rohitpaulk has quit [Ping timeout: 240 seconds]
synthroid has quit [Ping timeout: 240 seconds]
plujon has joined #ruby
im314ous has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
dionysus69 has quit [Ping timeout: 240 seconds]
DLSteve has quit [Quit: All rise, the honorable DLSteve has left the channel.]
synthroid has joined #ruby
hutch34 has quit [Ping timeout: 255 seconds]
rohitpaulk has joined #ruby
jenrzzz has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
<plujon>
I'm curious why a particular ruby process is using 140MB of memory. Is it possible for me to inspect the object state of this already-running process?
cschneid_ has quit []
vondruch has quit [Remote host closed the connection]
<lupine>
sure, although it's easier if you throw in a debug console from the start
<matthewd>
plujon: Yes, though there are limits to what you can learn
<plujon>
The machine is linux, so I can find some things in /proc . But the more I can learn, the better.
<matthewd>
plujon: You can attach to it with gdb, and [carefully] execute ruby from there
<catphish>
it tends to be much saner to add some memory debugging code and wait for it to happen again
<matthewd>
You'll then be able to look at ObjectSpace, for example -- which will tell you what objects are allocated, but not *where* they got allocated; you need allocation tracing turned on at allocation time to get that
jenrzzz has quit [Ping timeout: 255 seconds]
<matthewd>
It's pretty straightforward to get a heap dump, at least
yogg-saron has joined #ruby
<plujon>
I guess I should collect what information I can now to see if there are any clues as to where most of the memory is used, then add some debugging hooks for the future.
dviola has joined #ruby
<plujon>
How do you execute ruby from within gdb?
conta has quit [Ping timeout: 240 seconds]
<plujon>
(and/or get a heap dump)
mathys has quit [Quit: Leaving]
antgel has joined #ruby
<matthewd>
I'm sure Google can do a better job of answering either of those than I could off the top of my head
* plujon
nods
gil_ has joined #ruby
gil_ has joined #ruby
gil_ has quit [Changing host]
brent__ has joined #ruby
amclain has joined #ruby
elcontrastador has joined #ruby
SuperLag has joined #ruby
vondruch has joined #ruby
hutch34 has joined #ruby
Rodya_ has joined #ruby
ivanskie has joined #ruby
judofyr has joined #ruby
jzigmund has quit [Ping timeout: 240 seconds]
eljimmy has quit [Quit: This computer has gone to sleep]
dionysus69 has quit [Remote host closed the connection]
patarr has joined #ruby
nobitanobi has quit [Ping timeout: 268 seconds]
dionysus69 has joined #ruby
simmaniac has joined #ruby
dionysus69 has quit [Remote host closed the connection]
graft has quit [Ping timeout: 258 seconds]
dionysus69 has joined #ruby
<darix>
ALoneNoMad: the question also is ... with all the js based stuff you can do already do you need a native app or just a well written web app with mobile in mind
graft has joined #ruby
graft has joined #ruby
graft has quit [Changing host]
agimenez has quit [Ping timeout: 246 seconds]
mikecmpbll has joined #ruby
muelleme_ has joined #ruby
<guest223>
Ybur si dab.
shinnya has joined #ruby
hahuang65 has joined #ruby
qguv has left #ruby ["WeeChat 1.8"]
mwlang has quit [Quit: mwlang]
rohitpaulk has quit [Ping timeout: 240 seconds]
gusrub has quit [Read error: Connection reset by peer]
chouhoul_ has quit [Remote host closed the connection]
gusrub has joined #ruby
chouhoulis has joined #ruby
weathermaker has quit [Quit: weathermaker]
jenrzzz has quit [Ping timeout: 255 seconds]
rivalomega has quit [Remote host closed the connection]
<guest223>
Why should i learn ruby?
<guest223>
?
<guest223>
?
<guest223>
?
<Zarthus>
why not
antgel has joined #ruby
<guest223>
I have no interest in web. Is ruby good as a general purpose language?
Fernando-Basso has quit [Quit: WeeChat 1.8]
<apeiros>
yes it is
Fernando-Basso has joined #ruby
uZiel has quit [Ping timeout: 248 seconds]
jackjackdripper has quit [Read error: Connection reset by peer]
jackjackdripper has joined #ruby
kmhn has quit [Remote host closed the connection]
ascarter has joined #ruby
dionysus69 has quit [Quit: dionysus69]
agimenez has joined #ruby
dasher00 has quit [Ping timeout: 268 seconds]
sysvalve has joined #ruby
ascarter has quit [Ping timeout: 255 seconds]
montanonic has quit [Ping timeout: 258 seconds]
im314ous has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
simmaniac has quit [Ping timeout: 240 seconds]
elsevero has quit [Quit: elsevero]
agimenez has quit [Ping timeout: 240 seconds]
dasher00 has joined #ruby
t-recx has joined #ruby
guest223 has quit [Remote host closed the connection]
kmhn has joined #ruby
kmhn has quit [Remote host closed the connection]
nacsurte has quit [Ping timeout: 260 seconds]
eljimmy has quit [Quit: This computer has gone to sleep]
P-NuT has joined #ruby
cadillac_ has quit [Quit: Quit]
<jolamb>
Any faraday wizards here?
<jolamb>
I'm trying to figure out how to e.g. skip a specific middleware in the stack for just one request