<apeiros>
why do you suppress those poor falses? I'm for `p x > 2`!
<apeiros>
funny method where you don't know for which values "true" was emitted…
* dminuoso
slaps nofxx with a big Italian baguette
<dminuoso>
Serves you right.
<apeiros>
italian baguette…
<dminuoso>
Are you jealous?
<apeiros>
of your identity crisis?
<apeiros>
french, italian, french, italian…
<dminuoso>
I cant tell the difference. They have the same flag.
<dminuoso>
red white and something.
<dminuoso>
well and blue. green is like blue with yellow.
<apeiros>
I thought colorblindness was mainly red/green, not blue/green? :-p
<dminuoso>
Not sure, I don't have a Master in eyeology.
<apeiros>
maybe you should practice your lookamancy
Burgestrand has joined #ruby
bluOxigen has joined #ruby
pandaant has joined #ruby
sneakerhax has quit [Ping timeout: 272 seconds]
djbkd has quit [Quit: My people need me...]
bluOxigen has quit [Ping timeout: 248 seconds]
bluOxigen has joined #ruby
<nofxx>
apeiros, dminuoso europe's map: draw a horizontal line, up is dutch down is france
<nofxx>
and that's it
gizless has joined #ruby
gizmore has quit [Ping timeout: 272 seconds]
zapata has joined #ruby
<apeiros>
dutch ain't a country :-p
<dminuoso>
nofxx: That's what Ive been telling people for a long time. There really are not that many countries.
submitnine has joined #ruby
<nofxx>
apeiros, for him, and the line... and all those dutch states like netherlands
<apeiros>
got it. spain is french. belgium is dutch. is germany dutch or french?
JoshS has quit [Read error: Connection reset by peer]
fivmo has joined #ruby
JoshS has joined #ruby
saneax-_-|AFK is now known as saneax
fivmo has quit [Client Quit]
<nofxx>
nobody remembers portugal... endless fun, the ISIS kalifate map... did you notice they colored all europe BUT portugal?
<nofxx>
it's like...nah... nevermind
jaguarmagenta has joined #ruby
<apeiros>
portuwhat?
elenatanasoiu has joined #ruby
<dminuoso>
apeiros: port wine.
ocbtec has joined #ruby
alaibe has joined #ruby
<nofxx>
apeiros, you can thank 'em for a lot of candies, lot of deserts are portuguese in fact. and poetry, but who cares about poetry?
<apeiros>
that I know. but I don't know any portu gals
h1fuelce_ has quit [Remote host closed the connection]
jaguarmagenta has quit [Ping timeout: 252 seconds]
h1fuelcell has joined #ruby
<nofxx>
apeiros, hah... neither. We have an endless joke war with portugal, like the classic 'portugal made a submarine so damn well engineered it never sunk'
samof76 has quit [Ping timeout: 248 seconds]
<nofxx>
they do the same but the dumb guy is always a brazilian
ferr has joined #ruby
claudiuinberlin has joined #ruby
Dimik has quit [Ping timeout: 248 seconds]
<apeiros>
for some reason we have that with austrians
<apeiros>
my favorite though - austrian: "why do you swiss people always make fun of us? I mean we even have the same colors in our flag" - swiss: "sure, sure. but we have a +, you a -"
kimegede has joined #ruby
minimalism has quit [Quit: minimalism]
teclator has quit [Ping timeout: 272 seconds]
h1fuelcell has quit [Remote host closed the connection]
h1fuelcell has joined #ruby
jsrn_ has joined #ruby
djbkd has joined #ruby
cloaked1 has quit [Ping timeout: 272 seconds]
h1fuelcell has quit [Remote host closed the connection]
prawnzy has quit [Remote host closed the connection]
tomphp has joined #ruby
etehtsea has joined #ruby
capitainIsh has joined #ruby
Puffball has quit [Read error: Connection reset by peer]
teclator has joined #ruby
h1fuelcell has joined #ruby
Kruppe has quit [Ping timeout: 256 seconds]
craigp_ has joined #ruby
h1fuelcell has quit [Remote host closed the connection]
<Dysp>
No question about it. Otherwise I wouldn't come here.
<ciawal>
did you check what I said?
naftilos76 has joined #ruby
jenrzzz has joined #ruby
<Dysp>
Never came down to it, because of the sudden outbreak of fire in the channel
<Dysp>
ciawal: pwd?
<dminuoso>
Dysp: At any rate ciawal makes a valid point - regardless whether it's the source of your issue. If you want relative paths to the current file, use __FILE__
<dminuoso>
Don't use "./foo/bar"
<dminuoso>
They will depend on the current working directory.
<Dysp>
Do you have any articles I can read about the subject? Because you are indeed right.
<Dysp>
I just didn't know how to do it properly when I began and so it catched on.
<Dysp>
The same when 'loading' the library. I have a big file which require_relatives like a baws. But it doesn't seem like the right way.
<dminuoso>
Dysp: Also, you should have included the file /xercise/loading/excel/_kincom.rb in the gist as well. With the stacktrace and that file added, this would have been probably very obvious.
<Dysp>
Yes, I could, but that is still not the root of the problem.
<dminuoso>
Dysp: Let's agree that you are not the authority to tell us what the root of the problem is.
<dminuoso>
Because if you were, you wouldn't be here.
<Dysp>
This line should raise an exception and thus the other code should never be used: raise ArgumentError, "No file has been loaded." if !instance_variable_defined?(:@file)
<ciawal>
have you even checked what I said yet
tuxaddicted has quit [Quit: leaving]
<Dysp>
And my problem is that it sometimes raises an exception and sometimes does not, thus producing the failure, because the code is used
<dminuoso>
Dysp: Okay, this requires some Ruby stuff.
<dminuoso>
Dysp: Give me a moment prep an eval.in for this.
<Dysp>
And please respond in a non-technical way, I am by far not as much into programming as you are.
<Dysp>
ciawal: No. What is "pwd"?
AnoHito has joined #ruby
<ciawal>
the directory you are in
<Dysp>
Ah.
moneylotion has quit [Ping timeout: 260 seconds]
<dminuoso>
Dysp: No actually, just show us these files please.
moneylotion has joined #ruby
<Dysp>
What do you need?
<Dysp>
_kincmo?
<ciawal>
just check what I said
<dminuoso>
Dysp: Yes.
<Dysp>
ciawal: I just did. I don't think that is the error due to the way I run tests.
<dminuoso>
Dysp: "I dont think" means you dont know.
<dminuoso>
Dysp: stop guessing.
alaibe has quit [Quit: WeeChat 1.5]
<ciawal>
you should add a print of the @file variable before your assertion
<Dysp>
Alrighty.
<dminuoso>
Stop thinking, it doesn't seem to work.
<dminuoso>
Just debug it.
<ciawal>
if it's nil when it fails, I'm right
AnoHito_ has quit [Ping timeout: 264 seconds]
<dminuoso>
ciawal: the issue is that he has a require which has a side effect on the current class apparently.
<dminuoso>
ciawal: and he is hiding that code.
<Dysp>
dminuoso: I like that you want to help me, but you need to calm down on your offensiveness. I get that I pissed you off at some point, but acting the way you are right now is not a sufficient way of communicating.
watersoul has joined #ruby
<Dysp>
But, yes, moment.
<dminuoso>
Dysp: No I mean it without any offense intended. With debugging, it's often better to stop thinking and guessing.
<Dysp>
Should be updated now. Let me know if you need something else
dionysus69 has quit [Ping timeout: 272 seconds]
blackwind_123 has quit [Ping timeout: 264 seconds]
AnoHito_ has joined #ruby
<ciawal>
when you say this sometimes fails, sometimes passes
<ciawal>
what do you mean
<ciawal>
if you run the test 10 times in a row what happens
<Dysp>
Exactly
<Dysp>
Then it passes x amount of times
<Dysp>
and fails y amount
<Dysp>
I can try running it 10 times
<ciawal>
where x is 10 and y is 0?
<Dysp>
Haha, no :)
<Dysp>
Like, variating amount of each variable
blackwind_123 has joined #ruby
<ciawal>
how are you running the tests
<Dysp>
I am quite sure the wrong way
<Dysp>
Let me run it 10 times for a start
AnoHito has quit [Ping timeout: 248 seconds]
<Dysp>
Now it actually keeps passing, like 5 times in a row. Didn't change anything.
<ciawal>
;)
<Dysp>
But regarding how I test.. Probably the wrong way.
<Dysp>
This is the first thing I've ever built, so I've been learning throughout.
<Dysp>
I manually load a test file
<Dysp>
I should probably use rake or something like that
lucast has quit [Ping timeout: 265 seconds]
<ciawal>
just tell me what you do to run the test
<Dysp>
You are welcome to examine my repository, then you can probably see for yourself instead of me trying to use technical terms I don't understand well
<Dysp>
Ha, it failed
<Dysp>
Like the 9th time
<ciawal>
are you running in a terminal?
<Dysp>
Yes.
<ciawal>
then just pastebin the terminal contents if you can't answer
<Dysp>
I do "ruby tests.rb"
lucast has joined #ruby
<Dysp>
tests.rb is a file I made that loads and runs all the tests.
<Dysp>
And it's powershell, windows.
<ciawal>
run only this failing test
<ciawal>
10 times
<Dysp>
I am.
<Dysp>
I just did.
<Dysp>
I manually comment out tests I don't want to be run
<Dysp>
But. That is probably where my lack of knowledge becomes a problem. I am not even sure I can do what I am trying to do here.
tuxaddicted has joined #ruby
<Dysp>
I am trying to create an interface, where I can use method chaining.
jsrn__ has joined #ruby
<Dysp>
I want to be able to run Loading.file(FILE).excel(:TYPE) and then let the interface handle the request.
<Dysp>
Problem is that if I then run Loading.excel(:TYPE) that shouldn't be a valid request, because no file is loaded and thus the failure you see.
jenrzzz has quit [Ping timeout: 248 seconds]
<Dysp>
(Cannot load anything from nothing)-
Snickers has joined #ruby
<Dysp>
The exception should catch that no file is loaded in @file. However, I don't even know if you can load something when an instance of the class isn't even created.
<Dysp>
That is where I think the problem is. But I was told not to think.,
<Dysp>
;)
<Dysp>
I mean, @file is an instance variable, right? And if there isn't any instance, how can I check if it exists? But then I tried it out and it passed.. some times. And now I am here.
jsrn_ has quit [Ping timeout: 248 seconds]
blackgoat has joined #ruby
Devalo has quit [Ping timeout: 265 seconds]
zotherst1 has quit [Quit: WeeChat 1.5]
samof76 has joined #ruby
pawnbox has joined #ruby
hiro` has joined #ruby
<maloik>
I find the structure of that code quite weird. Why not call it Loader like your other classes, and use `new` instead of `file`?
<maloik>
Loader.new(file).excel(:type) instead of Loading.file(file).excel(:type)
<Dysp>
It probably is weird, no doubt about it.
<Dysp>
I could call it loader. I think I will do that.
jaguarmagenta has joined #ruby
<maloik>
the file method should be how you initialize that too, imo
<hiro`>
Hey. Started using rbenv last night. Got a strange bug though (or what seems like one). I'm in a project that specifies 2.2 in the .ruby-version file. I didn't have that version installed so I rbenv installed 2.2.5. But rbenv is still insisting that I don't have 2.2 installed.
ramfjord has quit [Ping timeout: 272 seconds]
<maloik>
it becomes easier to reason about... "what is an instance of the class Loader" has an answer, but "instance of Loading" becomes harder to reason about
<Dysp>
But I understand, dminuoso. I was also what I thought would be the problem; but I don't know exactly how Singleton classes work. I just figured it had something to do with that.
<Dysp>
Will stare at it for hours
<Dysp>
It feels like hours already.
<Dysp>
Your point with that line?
charliesome has joined #ruby
<dminuoso>
Dysp: Is there any chance that test_interface is run before test_exceptions? :-)
<Dysp>
As per how the test is written by me (the intention), then no.
<Dysp>
But as far as I don't know how testing actually workings, then of course. Quite possibly
prawnzy has quit [Ping timeout: 265 seconds]
<dminuoso>
Dysp: Not an expert in Minitest, but I'd say that is your issue. It seems like a race condition based on shared state across multiple tests.
<Dysp>
But I can deduce that @file is being set through the set and because it is a singleton class(?), then @file is suddenly not nil producing the failure.
<Dysp>
second set = test
<toretore>
Dysp: singleton = global. it will retain state from previous calls when you call it again (@file in your case). singleton = evil. don't use singletons.
pawnbox has quit [Remote host closed the connection]
<Dysp>
I will never touch a singleton again
<Dysp>
:P
<dminuoso>
Dysp: "Class level methods" are always methods defined on your classes singleton class.
<Dysp>
Lesson of the day: Don't fuck around with class methods
<dminuoso>
Dysp: No, it's not class methods that is the problem.
<toretore>
will you provide information when asked for the next time you ask others to give their time and effort in order to help you with a problem?
<dminuoso>
But class-level state the way you are testing.
<dminuoso>
Dysp: Either you need to provide some tear down mechanism, or ensure that you get different classes for each test.
<Dysp>
toretore: I would like to counter that and ask you if the answer to my question was'nt in fact in the code provided and the code asked for was irrelevant?
aries_liuxueyang has quit [Quit: No Ping reply in 180 seconds.]
<Dysp>
Which I tried to point out, thus producing hell fire.
<dminuoso>
minitest is multithreaded right?
<dminuoso>
Is so, you have a heck of race conditions there.
pawnbox has joined #ruby
<Dysp>
This is way beyond my understanding of Ruby and minitest
<ljarvis>
just have Loading.file return a proxy object
<ljarvis>
solved
<dminuoso>
^-
<Dysp>
:D
<Dysp>
I've changed it now
<toretore>
Dysp: not relevant. it's very arrogant to ask others to help you and then refuse to give them the information they ask for in return
<ljarvis>
also pass filenames to your loader classes, not open file descriptors
<dminuoso>
Dysp: Without the stack trace we had no way of understanding the error.
<Dysp>
This is what I changed it to.
<dminuoso>
Dysp: Nope, still not good.
<Dysp>
I tried to explain the error and that the trace not was of importance, because I knew what produced the error.
<dminuoso>
oh wait!
<Dysp>
but my reply was not well formulated, I see that.
<dminuoso>
Dysp: no this works.
<dminuoso>
Yeah.
<Dysp>
Yeah!
<Dysp>
Thank you so much for your help.
tlaxkit has joined #ruby
<dminuoso>
Dysp: Next time don't argue about what we need and don't need.
<ljarvis>
Dysp: you don't need the self in the initialize method anymore, initialize can't return anything else
<dminuoso>
Dysp: Feel free to ask *why* we need it if you think differently.
<Dysp>
ljarvis: True
<ljarvis>
and please close your file somewhere
<ljarvis>
it's killing me
<dminuoso>
ljarvis: initialize can return all it wants, but we actually use #new from the outside :p
<ljarvis>
dminuoso: i was waiting for a pedant to come along!
<dminuoso>
:P
<Dysp>
dminuoso: Isn't that also a semi-arrogant response to give? Like "WHY YOU NEED DAT?"
<Dysp>
ljarvis: Please elaborate. I have been thinking alot about optimization and the fact that I open files all along and never close them
<Dysp>
In a small scale system that wouldn't do much, but I guess it would kill the memory at some point?
<ljarvis>
Dysp: only open them when you want to read them
<ljarvis>
then close them when you're done
<Dysp>
And when closing, it removes it from memory?
maloik has quit [Remote host closed the connection]
<Dysp>
Is my understanding correct?
Wizznt has joined #ruby
maloik has joined #ruby
<ljarvis>
no, it closes the open file handle though
<ljarvis>
ya don't want dangling file handles
<Dysp>
I have also been thinking about all the instances that are made throughout the life of a program
<ljarvis>
(in theory it closes by itself at some point), but this is just good programming
<Dysp>
Where do they go?
<Dysp>
I mean, it must pile up somewhere
<Dysp>
Narnia?
<toretore>
Dysp: there are only two correct responses to a request for information when you are asking for help: 1) yes, here it is 2) i can not legally share it
stamina has joined #ruby
<Dysp>
Is it Narnia, ljarvis ?
<ljarvis>
it's somewhere less magical
<Dysp>
:(
<Dysp>
toretore: I don't agree, but I can respect that is the way of the channel.
<toretore>
you are wrong
<Dysp>
Sometimes you have to accept people being wrong in their opinions.
<Dysp>
I work with patients. They don't understand anything.
_joes__ has quit [Quit: Connection closed for inactivity]
<Dysp>
"No, you cannot take 5 pills at one time to compensate that you forgot to bring the pills with you on your 5 day trip".
<Dysp>
ljarvis: I am still waiting in eager anticipation
<ljarvis>
Dysp: you want to go down that rabbit hole?
<Dysp>
Now it is slowly turning into something magical again
<ljarvis>
it's where rabbit's go to die
<apeiros>
are we still discussing why people seeking help should provide information helpers ask for? o0
<ljarvis>
no
<Dysp>
Nah, we are beyond that now.
<apeiros>
good
<Dysp>
We are lurking into a magical place where objects (and rabbits) go to die.
<Dysp>
Is there any short answer, ljarvis ?
<Dysp>
Or is it something more suitable for bed time reading?
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
<ljarvis>
Dysp: sure. They stick around until they're not needed and swept up by a garbage collector
ur5us has quit [Remote host closed the connection]
<Dysp>
Is "not needed" defined by time past?
<apeiros>
no. by "nothing references it anymore"
<ljarvis>
no :)
ur5us has joined #ruby
<ljarvis>
and thus begins the journey of the ruby GC
<Dysp>
But if I define a @variable = 20
<Dysp>
when will @variable ever not be = 20?
<ljarvis>
defined where?
h1fuelcell has joined #ruby
<Dysp>
Lets say IRB for instance?
<apeiros>
Dysp: when either the object which contains the @variable is no longer referenced, or when you assign another value than 20 to @variable
mrBen2k2k2k has joined #ruby
<ljarvis>
if you open IRB and type @variable = 20, then idle for 10 years and type @variable, it will still be 20, yes
<apeiros>
i.e. "variable goes out of scope", and "variable gets another value assigned" are the two ways to stop referencing an object.
<Dysp>
I see. If the block ends the variable goes down the rabbit hole.
<Dysp>
It makes sense. Thank you.
c355e3b has joined #ruby
<Dysp>
ljarvis: Quick question; how to close a file?
capitainIsh has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
capitainIsh has joined #ruby
nettoweb has quit [Client Quit]
gnufied has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
TvL2386 has joined #ruby
xduba is now known as tsabx
vasilakisfil has joined #ruby
capitainIsh has quit [Client Quit]
yeticry has quit [Ping timeout: 264 seconds]
yeticry has joined #ruby
JeanCarloMachado has quit [Ping timeout: 244 seconds]
GodFather has joined #ruby
johnmilton has quit [Remote host closed the connection]
Snowy is now known as SnowyLUNCK
_sfiguser has quit [Remote host closed the connection]
<Dysp>
dminuoso: Noted
Aquazi has joined #ruby
emilkarl has joined #ruby
mvxlr has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
blaxter has quit [Quit: foo]
mvxlr has joined #ruby
nettoweb has joined #ruby
Guest35374 has quit [Read error: Connection reset by peer]
yqfvwal has joined #ruby
ldnunes has joined #ruby
nuck has joined #ruby
nuck is now known as Guest58009
JeanCarloMachado has joined #ruby
flak has joined #ruby
rippa has quit [Ping timeout: 272 seconds]
gnufied has quit [Ping timeout: 248 seconds]
gnufied has joined #ruby
gnufied has quit [Max SendQ exceeded]
lifted has quit [Remote host closed the connection]
Burgestrand has joined #ruby
zipace has joined #ruby
jenrzzz has joined #ruby
nettoweb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
samof76 has quit [Ping timeout: 248 seconds]
frankiee_ has quit [Ping timeout: 248 seconds]
andikr has quit [Remote host closed the connection]
tuxaddicted has quit [Ping timeout: 244 seconds]
jenrzzz has quit [Ping timeout: 264 seconds]
Devalo has joined #ruby
Akuma has quit [Quit: So long sukkas!]
Akuma has joined #ruby
dionysus69 has joined #ruby
elenatanasoiu has quit [Ping timeout: 252 seconds]
Devalo has quit [Ping timeout: 244 seconds]
tuxaddicted has joined #ruby
lifted has joined #ruby
jaguarmagenta has joined #ruby
elenatanasoiu has joined #ruby
h1fuelcell has joined #ruby
bigkevmcd has quit [Read error: Connection reset by peer]
flak has quit [Read error: Connection reset by peer]
workmad3 has quit [Read error: Connection reset by peer]
workmad3 has joined #ruby
face has joined #ruby
SesMan has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rbr has quit [Read error: Connection reset by peer]
h1fuelcell has quit [Remote host closed the connection]
gnufied has joined #ruby
jaguarmagenta has quit [Ping timeout: 265 seconds]
Prira has quit [Remote host closed the connection]
brendan- has joined #ruby
Bounga has joined #ruby
elenatanasoiu has quit [Ping timeout: 265 seconds]
rippa has joined #ruby
mvxlr has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rbr has joined #ruby
Prira has joined #ruby
zukin has quit [Ping timeout: 264 seconds]
johnmilton has joined #ruby
johnmilton has quit [Read error: Connection reset by peer]
voids has joined #ruby
raeoks has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bruce_lee has quit [Ping timeout: 248 seconds]
bruce_lee has joined #ruby
zukin has joined #ruby
johnmilton has joined #ruby
tuxaddicted has quit [Quit: Reconnecting]
tuxaddicted has joined #ruby
faces has joined #ruby
tuxaddicted has quit [Client Quit]
tuxaddicted has joined #ruby
tsabx has quit [Ping timeout: 240 seconds]
naftilos76 has quit [Quit: Αποχώρησε]
face has quit [Ping timeout: 264 seconds]
h1fuelcell has joined #ruby
yardenbar has quit [Ping timeout: 244 seconds]
h1fuelcell has quit [Remote host closed the connection]
face has joined #ruby
7ITAAQS4S has joined #ruby
voids has quit [Ping timeout: 276 seconds]
tbboin has quit [Remote host closed the connection]
bruce_lee has quit [Read error: Connection reset by peer]
faces has quit [Ping timeout: 252 seconds]
bruce_lee has joined #ruby
lel has quit [Read error: Connection reset by peer]
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
nando293921 has quit [Ping timeout: 264 seconds]
face has quit [Remote host closed the connection]
face has joined #ruby
synthroid has joined #ruby
Bounga has quit [Remote host closed the connection]
Bounga has joined #ruby
prawnzy has joined #ruby
SesMan has joined #ruby
anquegi has quit [Remote host closed the connection]
thatsnotjack has quit [Ping timeout: 244 seconds]
banisterfiend has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
SnowyLUNCK has quit [Remote host closed the connection]
gingray has quit [Ping timeout: 244 seconds]
prawnzy has quit [Ping timeout: 248 seconds]
sdothum has joined #ruby
jcao219 has joined #ruby
neohunter has quit [Ping timeout: 272 seconds]
pawnbox has quit [Remote host closed the connection]
Madplatypus has quit [Quit: Connection closed for inactivity]
brendan- has joined #ruby
tyang has joined #ruby
SnowyLUNCK has joined #ruby
SnowyLUNCK is now known as Snowy
tuxaddicted has quit [Ping timeout: 248 seconds]
ruby-lang927 has joined #ruby
ruby-lang927 has quit [Client Quit]
pandaant has quit [Remote host closed the connection]
teclator has quit [Ping timeout: 272 seconds]
GinoManWorks has joined #ruby
aupadhye has quit [Quit: Leaving]
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
elenatanasoiu has joined #ruby
<fbt>
I wonder what was the point of the inconsistency in some languages of “some functions take arguments after a space but some only do so in brackets”
<fbt>
Ruby is not the only one here
aries_liuxueyang has quit [Ping timeout: 265 seconds]
<fbt>
But really, why allow 'puts "foo"' instead of puts("foo")?
aries_liuxueyang has joined #ruby
<Snowy>
can you give an example? i'm not aware of any inconsistency in ruby.
<Snowy>
the only time i'm aware that brackets are required is when there are multiple function calls leading to ambiguity
yardenbar has joined #ruby
<fbt>
Ah, so any method can take arguments both ways?
<fbt>
I was somehow sure that wasn't the case
blackgoat has quit [Quit: WeeChat 1.5]
sandelius has joined #ruby
kegster has quit [Quit: Shiner, TX makes good beer.]
harfangk has joined #ruby
zirpu has joined #ruby
zukin has quit [Ping timeout: 265 seconds]
anquegi has joined #ruby
anquegi has quit [Remote host closed the connection]
zukin has joined #ruby
anquegi has joined #ruby
<Snowy>
that's correct by my understanding (with 4 years using rubY0
boogeyman has quit [Quit: bb]
<Snowy>
but if you wanted to print the result of a method it'd be ambiguous:
<Snowy>
print some_method, "foo", "bar"
<Snowy>
which function are foo and bar being passed to?
<Snowy>
so you need to wrap one of them in brackets, which can be written as:
<apeiros>
fbt: why allow methods to be called without parens - because it reduces noise.
<apeiros>
and Snowy is correct. parens are only required when it'd be ambiguous without.
<Snowy>
print(some_method "foo", "bar)
<Snowy>
or
<Snowy>
print some_method("foo", "bar")
<apeiros>
or when precedence would cause ruby to interpret it differently
<apeiros>
foo :bar { "baz!" } # invalid, because the block is tied to :bar by precedence, and objects don't take blocks
<apeiros>
foo(:bar) { "baz!" } # valid, because now precedence has been established explicitly through parens
nh_cham has quit [Ping timeout: 252 seconds]
yardenbar has quit [Ping timeout: 244 seconds]
<apeiros>
also re terminology IMO use () parens, [] brackets, {} (curly-)braces ;-)
<fbt>
Ah, () are parens, not brackets, yeah
<fbt>
Anyway. I'll try sticking with just using parens always and see how that goes
<fbt>
Just looks better to me .-.
anquegi has quit [Remote host closed the connection]
anquegi has joined #ruby
lucasb_ has joined #ruby
blackwind_123 has quit [Ping timeout: 265 seconds]
ramfjord has joined #ruby
yardenbar has joined #ruby
Alayde has quit [Ping timeout: 244 seconds]
stamina has quit [Ping timeout: 248 seconds]
nankyokusei has joined #ruby
rajdesai has joined #ruby
jonyijoe has quit [Remote host closed the connection]
ramfjord has quit [Ping timeout: 252 seconds]
7ITAAQS4S has quit [Remote host closed the connection]
jonyijoe has joined #ruby
emilkarl has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
chouhoulis has joined #ruby
<Aquazi>
is 2.1.6 still the recommended version of ruby to start with'
yardenbar has quit [Ping timeout: 264 seconds]
<Aquazi>
?
last_staff has quit [Quit: going AWNOL]
<Aquazi>
or 2.2.5?
<Dysp>
Start with? Like to begin to learn?
<ineb>
i would start with the newest possible version
<fbt>
I just went with the one available in my distro's repos
<fbt>
Which happens to be the latest one
nankyokusei has quit [Ping timeout: 265 seconds]
<Dysp>
I would also pick the latest one if I were to learn it. Why spend time on learning an older version? The only reason I see to use an older version is if you work with something written in another version.
<dminuoso>
Aquazi: The recommended version is always the newest version.
jonyijoe has quit [Remote host closed the connection]
<dminuoso>
Aquazi: Go with 2.3.1
jonyijoe has joined #ruby
<dminuoso>
Aquazi: If you only have something older that's fine too, don't worry too much about it.
<dminuoso>
The changes in the past couple versions were minor
<Aquazi>
i was thinking about gems compatibility ecc
coolboy has joined #ruby
<dminuoso>
Aquazi: Don't worry about it.
pwnd_nsfw` has joined #ruby
<dminuoso>
Aquazi: As long as you go with any version that is supported (check the topic) you will be fine for sure.
Filiphe has joined #ruby
<Aquazi>
thx
<Dysp>
Why isn't there a command line to update Ruby, btw?
SteenJobs has joined #ruby
emilkarl has joined #ruby
<dminuoso>
Dysp: It is not Ruby's job to manage itself on every system outthere.
<Dysp>
I understand that and I am happy it isn't enforced, but why not add the option? What would the cons be?
<dminuoso>
Dysp: Either install Ruby through your package management system (apt, yum, homebrew, whatever floats your boat) or deal with it manually using ruby-install / chruby. The last options is generally preferred, as you are guaranteed the most recent version and can easily maintain multiple Rubies as well.
<dminuoso>
Dysp: Complexity.
<Dysp>
Yes, alright.
<dminuoso>
Dysp: I think Java is a real exception here.
<dminuoso>
But then again they have Oracle behind then.
<Dysp>
It's interesting. I wonder if it is even profitable to maintain a programming language
<apeiros>
fbt: so you'll write `class Foo; attr_reader(:bar); end`?
pawnbox has joined #ruby
jcao219 has quit [Ping timeout: 244 seconds]
<dminuoso>
Dysp: Considering that both Sun and Oracle are not inheritently bad at business, surely Java must have profits in them.
tyang has quit [Ping timeout: 264 seconds]
<Dysp>
I was thinking more of Ruby
<Dysp>
What drives the development
anquegi has quit [Remote host closed the connection]
ramortegui has joined #ruby
coolboy has quit [Remote host closed the connection]
<dminuoso>
Dysp: Rubys development is mostly driven by a handful of people. They probably have the backing of the companies they work at.
<fbt>
apeiros, yeah, why not
<apeiros>
fbt: because I haven't seen anybody do that. but of course, you're free to do so :)
konnigun has joined #ruby
<Dysp>
dminuoso: I see. It's lovely, though.
jugband has joined #ruby
jugband is now known as murilo
samof76 has joined #ruby
Immune has quit [Ping timeout: 244 seconds]
pawnbox has quit [Ping timeout: 272 seconds]
anquegi has joined #ruby
SesMan has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tyang has joined #ruby
pawnbox has joined #ruby
gregf_ has joined #ruby
Immune has joined #ruby
murilo has quit [Ping timeout: 265 seconds]
boogeyman has joined #ruby
jonyijoe has quit [Remote host closed the connection]
Silthias has left #ruby [#ruby]
brendan- has joined #ruby
jonyijoe has joined #ruby
ekinmur has joined #ruby
rajdesai has quit [Remote host closed the connection]
rajdesai has joined #ruby
lxsameer has quit [Quit: WeeChat 1.5]
jonyijoe has quit [Ping timeout: 265 seconds]
lifted has quit [Quit: lifted]
bsrd has quit [Quit: WeeChat 1.5]
FINbit has joined #ruby
SesMan has joined #ruby
zukin has quit [Ping timeout: 244 seconds]
rajdesai has quit [Ping timeout: 272 seconds]
tvw has quit []
tvw has joined #ruby
malconis has joined #ruby
lifted has joined #ruby
Bellthoven has joined #ruby
ben_ has joined #ruby
Snickers has quit [Ping timeout: 244 seconds]
SteenJobs has quit [Quit: SteenJobs]
Alayde has joined #ruby
thatsnotjack has joined #ruby
fmcgeough has joined #ruby
zatherz_ has joined #ruby
zatherz has quit [Ping timeout: 265 seconds]
Bellthoven has quit [Client Quit]
fuzzyhorns has joined #ruby
Bellthoven has joined #ruby
gregf_ has quit [Ping timeout: 240 seconds]
<Aquazi>
I just can't install that fuckin rails, no matter the procedure
<Aquazi>
tried every fix online about SSL, it just won't work
<Aquazi>
(win 7)
nando293921 has joined #ruby
lifted has quit [Quit: lifted]
bsrd has joined #ruby
lifted has joined #ruby
lifted_ has joined #ruby
<lifted>
I’m starting to love Rails… i’ve been writing code 5 days a week for the last 40 days in RoR and it’s pretty great for frontend stuff. that being said, for my heavy lifting im REALLY considering offloading it to a Docker cloud running Python APIs for my resource intensive stuff… thoughts??
stan has joined #ruby
<ljarvis>
lifted: that sounds like a very specific use-case, I'm not sure what anyone here could offer you. You could also use smaller Ruby frameworks to power the APIs for heavy lifting stuff. I'm not really sure what you want
kus_ubuntui686 has joined #ruby
<dminuoso>
lifted: ?rails
* dminuoso
sighs
gregf_ has joined #ruby
<ineb>
what are your reasons to switch from ruby to python?
<dminuoso>
Does eye cancer suffice?
<ljarvis>
now now
patarr has joined #ruby
Alayde has left #ruby ["WeeChat 1.1.1"]
<dminuoso>
lifted: sorted(set(range(2,n+1)).difference(set((p * f) for p in range(2,int(n**0.5) + 2) for f in range(2,(n/p)+1))))
jenrzzz has joined #ruby
<dminuoso>
Tell me this does not give you eye cancer.
frankiee_ has joined #ruby
<hanmac>
yeah it does look fishy
nh_cham2 has joined #ruby
nh_cham2 has quit [Client Quit]
<ljarvis>
can we stay on topic? happy to debate ruby vs python in #ruby-offtopic
yeticry has quit [Ping timeout: 265 seconds]
nh_cham2 has joined #ruby
nh_cham2 has quit [Client Quit]
<apeiros>
dminuoso: other way round. bot is supposed to answer when spoken to.
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
<apeiros>
+only
x0f has quit [Ping timeout: 265 seconds]
<dminuoso>
apeiros: ?
<ljarvis>
?rails apeiros
<ruby[bot]>
apeiros: Please join #RubyOnRails for Rails questions. You need to be identified with NickServ, see /msg NickServ HELP
<ljarvis>
^
<dminuoso>
Im getting confused.
<dminuoso>
Too many bots on this network.
ben_ has quit []
<dminuoso>
Each with his own syntax.
<ljarvis>
I can't disagree with that one
nh_cham2 has joined #ruby
<ljarvis>
they're taking over
Jameser has joined #ruby
Devalo has joined #ruby
<apeiros>
lets implement a standard for bot invocations!
<dminuoso>
unified bot language.
<apeiros>
hanmac can certainly aid us with the obligatory xkcd ref
<zatherz_>
yeah I tested that, it's some weirdness with the Parslet classes I am pretty sure
<ljarvis>
ah
<ljarvis>
yeah sounds pretty dumb
<zatherz_>
how the fuck would that even work
<zatherz_>
the `if false` block should never be ran
<ljarvis>
did you try a different variable name?
nando293921 has joined #ruby
tsabx has quit [Quit: .]
<zatherz_>
ljarvis: it works if I do `xcall = call` then use `xcall`
<zatherz_>
what the fuck
yardenbar has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
jenrzzz has joined #ruby
j3ll3 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
<zatherz_>
I'm so confused
ramfjord has joined #ruby
<apeiros>
lvar vs. method
<zatherz_>
why does it work if I do `xcall = call` and then use xcall?
<apeiros>
I think you just shadowed a method with an lvar. and no, the actual assignment doesn't need to be executed, it just needs to be "seen" by ruby
<ljarvis>
yeah they probably have a call method somewhere, so the second time it's called it's nil
<ljarvis>
because xcall didn't change
<zatherz_>
wait
mrBen2k2k2k has joined #ruby
<zatherz_>
it needs to be just "seen"?
<ljarvis>
it retains the original method call value
<apeiros>
the last code is what almost certainly happens in your case.
<zatherz_>
ah wait, I think I'm getting it
tlaxkit has quit [Quit: tlaxkit]
Expanse has joined #ruby
<hanmac>
local variables are set when the code is parsed, not when the code is excecuted
tvw has quit [Read error: Connection reset by peer]
jugband has joined #ruby
jugband is now known as murilo
colstrom has joined #ruby
<zatherz_>
that sounds terrible :/
murilo has left #ruby [#ruby]
nh_cham has joined #ruby
* apeiros
sobs
jenrzzz has quit [Ping timeout: 265 seconds]
<apeiros>
it's terrible if you have conditionally defined lvars
yannj has joined #ruby
<apeiros>
the rest is just you vs. faster code.
lifted has quit [Quit: lifted]
<zatherz_>
this seems like a pretty important thing, I'm surprised that it wasn't in the tutorial I was learning from
<zatherz_>
especially coming from lua
Guest19692 is now known as ndrst
<apeiros>
namely: any sane language will not look up lvars by name. the name is for us puny humans. and in order to use faster access to lvars, it'll reserve them upfront.
<zatherz_>
so, is the best workaround to just use the `xcall = call` stuff?
lifted has joined #ruby
tyang has quit [Ping timeout: 264 seconds]
programmerq has joined #ruby
<apeiros>
I'd use a better name. but yes. don't shadow methods.
<ineb>
i remember when this behaviour suprised me aswell
submitnine has quit [Remote host closed the connection]
<zatherz_>
what I'm gonna do instead is use parslet's transforms stuff to not have to do this in the first place
axl_ has quit [Quit: axl_]
<zatherz_>
basically, parslet will return an array of hashes if it finds multiple nodes marked as the same thing, but it'll only return a hash (not an array with a single element that's a hash) if there's only one element
wldcordeiro has joined #ruby
<zatherz_>
actually, I can't do that, so I'll just do something like `call_lvar = call`
lifted has quit [Client Quit]
nankyokusei has joined #ruby
jphase has quit [Remote host closed the connection]
<matthewd>
`call = call()` or `call = self.call` work too
lidenbrock has joined #ruby
Emmanuel_Chanel has quit [Ping timeout: 252 seconds]
<zatherz_>
matthewd: call = call() is great, thanks!
emilkarl has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
skweek has quit [Ping timeout: 252 seconds]
<ljarvis>
why would a variable name ever be called call D:
<ljarvis>
why would a variable ever be named call D: *
<zatherz_>
ljarvis: I'm writing a recursive command parser and `call` is the name of the command call node
ghostlight has joined #ruby
lifted has quit [Client Quit]
nankyokusei has quit [Ping timeout: 265 seconds]
dminuoso has quit [Remote host closed the connection]
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
luong has joined #ruby
j3ll3 has joined #ruby
antgel has quit [Ping timeout: 244 seconds]
dionysus69 has quit [Ping timeout: 265 seconds]
ferr has quit [Quit: WeeChat 1.5]
luong has quit [Client Quit]
miguelfernandes has joined #ruby
jphase has joined #ruby
yardenbar has quit [Ping timeout: 265 seconds]
DoubleMalt has joined #ruby
programmerq has left #ruby ["WeeChat 1.5"]
abernstein has quit [Quit: abernstein]
luong has joined #ruby
aganov has quit [Remote host closed the connection]
brendan- has joined #ruby
<LastWhisper____>
hey guys if i have an array of objects, and the objects have different classes "Johnsons" and "Jimmies" can i do an array.map to only find Johnsons ?
ccmcdee-sfc has joined #ruby
Emmanuel_Chanel has joined #ruby
skweek has joined #ruby
naftilos76 has quit [Quit: Αποχώρησε]
synthroid has quit [Remote host closed the connection]
<lucasb_>
LastWhisper____: array.grep(Johnson)
sepp2k has quit [Read error: Connection reset by peer]
<luong>
Which protocol that fog use to transfer file to AWS?
vasilakisfil has quit [Ping timeout: 265 seconds]
maddmaxx has joined #ruby
Renich has quit [Ping timeout: 244 seconds]
jonyijoe has quit []
emilkarl has joined #ruby
<luong>
I use sftp to upload avatars to my own server but it's very slow to connect. So, how can I handle this?
Aquazi has quit [Read error: Connection reset by peer]
mhoogkamer has joined #ruby
nando293921 has quit [Ping timeout: 265 seconds]
yqfvwal has joined #ruby
Guest38_ has joined #ruby
Oclair has quit [Ping timeout: 264 seconds]
LDJFIO has quit [Remote host closed the connection]
Oclair has joined #ruby
nadir has quit [Quit: Connection closed for inactivity]
brendan- is now known as bmurt-
synthroid has joined #ruby
LDJFIO has joined #ruby
bmurt- is now known as brendan-
frankiee_ has quit [Read error: Connection reset by peer]
nankyokusei has joined #ruby
Burgestrand has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sepp2k has joined #ruby
SesMan has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
LDJFIO has quit [Ping timeout: 264 seconds]
ctp has joined #ruby
dionysus69 has joined #ruby
kimegede has joined #ruby
mark_66 has quit [Remote host closed the connection]
luong has quit [Ping timeout: 272 seconds]
djbkd has joined #ruby
bkxd has quit [Ping timeout: 264 seconds]
tyang has joined #ruby
stamina has joined #ruby
jackjackdripper has joined #ruby
Jameser has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
kimegede has quit [Quit: Leaving...]
h1fuelcell has joined #ruby
conta has quit [Ping timeout: 244 seconds]
xentity1x has joined #ruby
shinnya has quit [Ping timeout: 265 seconds]
rodfersou is now known as rodfersou|lunch
miqlas-H has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
jenrzzz has joined #ruby
ramfjord has quit [Ping timeout: 264 seconds]
etehtsea has quit [Ping timeout: 244 seconds]
amclain has joined #ruby
Chair has joined #ruby
jenrzzz has quit [Ping timeout: 264 seconds]
TvL2386 has quit [Ping timeout: 244 seconds]
babblebre has joined #ruby
devmagpie has quit [Quit: devmagpie]
Coldblackice has joined #ruby
aufi has quit [Quit: Leaving]
symm- has joined #ruby
cred has joined #ruby
M-shine has quit [Quit: node-irc says goodbye]
tvw has joined #ruby
DoubleMalt has quit [Ping timeout: 272 seconds]
jaguarmagenta has joined #ruby
suchness has joined #ruby
nettoweb has joined #ruby
<suchness>
Anyone know if it's possible using "Mail" to get rid of an emails history? If I reply to someone, their original message is stuck in my reply, I want to strip everything out of each email (including a signature if I can) so only the exact message sent is left.
ChiefAlexander has quit [Ping timeout: 264 seconds]
hiro_ has joined #ruby
jaguarmagenta has joined #ruby
Devalo has quit [Ping timeout: 256 seconds]
conta has quit [Ping timeout: 252 seconds]
zipace has quit [Read error: Connection reset by peer]
<hiro_>
Hey everyone, I've been trying to resolve my version / dependency management hell. I uninstalled rvm and installed rbenv. One issue I'm still having is that when I try to run 'gem install bundler', I get this error: 'incompatible marshal file format (can't be read)'. Can anyone tell me what it means?
SteenJobs has quit [Quit: SteenJobs]
spligak has joined #ruby
<tubbo>
hiro_: probably using a really old version of rubygems...can you make sure the `gem` binary is coming from the right place by typing `which gem`?
<hiro_>
Also, when I try bundle (with my current version of bundler), I get a message telling me I can't install to system rubygems and asking for my password. But on the rbenv docs it says: 'You don't need sudo to install gems'.
Guest73 has joined #ruby
jaguarmagenta has quit [Ping timeout: 244 seconds]
<havenwood>
?rbenv hiro
<ruby[bot]>
havenwood: I don't see no hiro, whom should I tell about rbenv?
<hiro_>
tubbo: it's coming from /home/me/.rbenv/shims/gem
<havenwood>
?rbenv
<ruby[bot]>
Missing command under rbenv? Did you try `rbenv rehash`?
<hiro_>
which seems like the right place
<tubbo>
seems ok to me
Guest73 has quit [Client Quit]
<tubbo>
hiro_: but your rbenv might still be selecting the system ruby
<hiro_>
I think it is
<tubbo>
especially if you haven't installed any other versions of ruby on the machine
<hiro_>
this is the problem I was having with rvm before I nuked it
<tubbo>
i think you can do `rbenv local 2.3.1` or whatever to generate a .ruby-version in the current dir
<hiro_>
at least, I tihnk it was
<hiro_>
tubbo: I've done that
<tubbo>
cool
soulisson has joined #ruby
<tubbo>
try doing `cd .` to make sure it's being used
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
vdamewood has quit [Ping timeout: 265 seconds]
<hiro_>
still the same
<tubbo>
hiro_: so did you install any other versions of ruby on your machine/
<tubbo>
?*(
<hiro_>
I've installed a couple with rbenv since I installed it last night
<tubbo>
ok
<havenwood>
hiro_: Have you already run `rbenv rehash`? What do you get for `gem -v` and `which -a gem`?
<tubbo>
^
<tubbo>
also ruby -v
<hiro_>
havenwood: I tried that and it produced no output in the shell
<hiro_>
I'm not sure if it worked or not
<tubbo>
yeah that's usually what happens when it works
<tubbo>
rbenv rehash that is
<hiro_>
gem -v: 2.4.5.1
<tubbo>
havenwood: TIL about which -a :)
<hiro_>
which -a gem: me/.rbenv/shims/gem & /usr/bin/gem
blackgoat has joined #ruby
SteenJobs has joined #ruby
djbkd has joined #ruby
workmad3 has joined #ruby
<tubbo>
hiro_: can you try a `gem update --system`? usually, if gem has problems, it's solved by just upgrading rubygems.
<hiro_>
is it worth trying to uninstall the system ruby or gem?
<tubbo>
no
<tubbo>
makes more sense to upgrade rubygems in place. usually can't hurt, is almost always faster and more reliable.
SteenJobs has quit [Client Quit]
<hiro_>
gem is trying to update from the server at work
cibs has quit [Ping timeout: 268 seconds]
synthroid has joined #ruby
<hiro_>
which it can't do
<hiro_>
since I'm at home
<tubbo>
wat
<tubbo>
hiro_: well that might be *one* reason why you're having trouble, your sources sound screwed up
<hiro_>
not intentionally, but I did update ubuntu recently
nadir has joined #ruby
cibs has joined #ruby
synthroi_ has joined #ruby
synthroid has quit [Remote host closed the connection]
<tubbo>
not *that* sources list...i meant the one in rubygems :) only way i was able to reliably remove rubygems.org from the sources list in rubygems was to run a gem server on the same box and modify the firewall to redirect rubygems.org -> localhost
<tubbo>
so that way when the app looked in rubygems.org, it was really pointing to the loopback interface and the local server
polyidus has quit [Quit: Gone]
<hiro_>
I don't think I've modified it or even thought about it ever, tbh
claudiuinberlin has quit []
<hiro_>
Is there a way to un-screw-up my gem sources?
OnyxRaven has joined #ruby
leea has joined #ruby
nettoweb1 has joined #ruby
nettoweb has quit [Ping timeout: 252 seconds]
<hiro_>
download and reinstall?
<hiro_>
smash my laptop and start again?
<OnyxRaven>
i’m getting a weird issue where i’m getting ‘Ignoring gem-version’ because its extensions are not built on a bunch of gems (that arent in my Gemfile), but everything still works - and those gems all still work on the project they’re actually defined on (which also gets those errors).
soulisson has left #ruby ["Leaving"]
<OnyxRaven>
I recently had to uninstall and reinstall ruby (2.1.9) because of brew upgrading readline. I use rbenv
<OnyxRaven>
Is there some way to resolve those warnings?
Immune has quit [Ping timeout: 264 seconds]
nankyokusei has joined #ruby
nettoweb1 has quit [Ping timeout: 272 seconds]
jenrzzz has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
<hiro_>
OnyxRaven: have you tried rebuilding the gems?
<OnyxRaven>
yep
<havenwood>
OnyxRaven: I'd probably `gem pristine --all` and see if there are still any warnings. If there are, see where those gems are and if you still want those gems at all.
<OnyxRaven>
doing gem pristine like it suggests doesnt seem do solve it
<havenwood>
If they're just lingering from an unused old install, uninstall them.
<OnyxRaven>
I tried gem pristine —all and it didnt work either
Snowy has quit [Remote host closed the connection]
nalik89 is now known as nullwork
nankyokusei has quit [Ping timeout: 264 seconds]
<OnyxRaven>
there were no gems installed (rbenv uninstall blew them all away as I expected), so this is from a ‘fresh’ install
eljimmy has joined #ruby
<OnyxRaven>
and these are the versions in the Gemfile.lock
erlingur_ has joined #ruby
nando293921 has quit [Ping timeout: 265 seconds]
bkxd has joined #ruby
pawnbox has quit [Remote host closed the connection]
<havenwood>
OnyxRaven: Are you using a Bundler "remembered" --path or something?
<OnyxRaven>
i dont think so...
<havenwood>
Maybe check: bundle config
pawnbox has joined #ruby
<havenwood>
OnyxRaven: Can you Gist the error?
<OnyxRaven>
bundle config just has the coc/mit/test lines
jackjackdripper1 has quit [Ping timeout: 256 seconds]
<havenwood>
_sfiguser: Symbol#to_proc is a method you can call on a Symbol to return a Proc corresponding to a Method by the same name as the Symbol.
<meatchicken>
In rspec - how do I make a method on an obj return a specific value?
moneylotion has quit [Ping timeout: 260 seconds]
<meatchicken>
allow(obj).to receive(:method).and_return(:value) seems to be the way
postmodern has joined #ruby
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
<havenwood>
_sfiguser: When the Method corresponding to the Symbol only takes one argument you can use it like you showed to pass that Proc as a block. The `&` both calls #to_proc and passes it as a block parameter instead of an argument parameter.
<havenwood>
_sfiguser: It's the same thing when you `inject(:+)`, except that method calls #to_proc on the Symbol you provide and passes it as a block automatically, that's how #inject was implemented. An `inject(&:+)` ends up at the same place.
elenatanasoiu has joined #ruby
konnigun has quit [Client Quit]
biberu has quit [Read error: Connection reset by peer]
leea has joined #ruby
pawnbox has joined #ruby
jarred has quit [Quit: Connection closed for inactivity]
jaguarmagenta has quit [Ping timeout: 244 seconds]
skweek has quit [Ping timeout: 256 seconds]
Ishido has quit [Remote host closed the connection]
leea has quit [Read error: Connection reset by peer]
[Butch] has quit [Quit: I'm out . . .]
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
moneylotion has quit [Ping timeout: 260 seconds]
pawnbox has quit [Ping timeout: 265 seconds]
behemot has quit [Ping timeout: 272 seconds]
FINbit has joined #ruby
malcolmva has quit [Ping timeout: 244 seconds]
ben_ has quit [Ping timeout: 252 seconds]
moneylotion has joined #ruby
elenatanasoiu has quit [Ping timeout: 265 seconds]
gnufied has quit [Ping timeout: 252 seconds]
ruby_ has joined #ruby
fmcgeough has quit [Read error: Connection reset by peer]
fmcgeough has joined #ruby
whathappens has quit [Ping timeout: 265 seconds]
NTrash_ has quit [Quit: Konversation terminated!]
NTrash has joined #ruby
maddmaxx has quit [Quit: Going offline, see ya! (www.adiirc.com)]
howdoi has quit [Quit: Connection closed for inactivity]
nankyokusei has joined #ruby
whathappens has joined #ruby
malcolmva has joined #ruby
elastix has quit [Quit: elastix]
brianpWins has joined #ruby
NTrash has quit [Quit: Konversation terminated!]
<_sfiguser>
how can i assign all the multiples of a number less then a number with a one liner in ruby ?
NTrash has joined #ruby
nankyokusei has quit [Ping timeout: 264 seconds]
sepp2k has quit [Read error: Connection reset by peer]
NTrash has quit [Client Quit]
whathappens has quit [Ping timeout: 265 seconds]
<havenwood>
_sfiguser: What does that mean? What do you have and what do you want? Like: I have `[3, 24, 4]` and I want `[3, 42, 4]`.
<_sfiguser>
havenwood, i want all multiples of 3 but less than 30
<_sfiguser>
so they are
<havenwood>
_sfiguser: Gisting a few examples of expected input and desired output will get your questions answered more quickly!
gingray has quit [Ping timeout: 264 seconds]
<_sfiguser>
3, 6, 9 , 12, 15, 18, 21, 24, 27
<havenwood>
_sfiguser: and you want?
SCHAAP137 has quit [Read error: Connection reset by peer]
workmad3 has quit [Ping timeout: 252 seconds]
ChiefAlexander_ has quit [Remote host closed the connection]
<havenwood>
_sfiguser: Sound like you want to map, but it's hard to tell without seeing what you want returned.
<Nilium>
If you do a curl -v for it, what does it think the cert is for?
<Nilium>
Are you at an airport? In a hotel?
<baweaver>
work
nando293921 has joined #ruby
<Nilium>
Does your office MITM things?
<baweaver>
It shouldn't
<Nilium>
It's pretty common
<baweaver>
* Server certificate: l.ssl.fastly.net
<baweaver>
Never had this problem before
Rutix has quit [Read error: Connection reset by peer]
Rutix has joined #ruby
Rutix has quit [Changing host]
Rutix has joined #ruby
jhack has joined #ruby
<Nilium>
Yeah, nothing I can reproduce from here.
marxarelli|afk is now known as marxarelli
GodFather has joined #ruby
SteenJobs has quit [Quit: SteenJobs]
erlingur_ has joined #ruby
ResidentBiscuit has joined #ruby
Rutix`away has joined #ruby
Rutix`away has joined #ruby
Rutix`away has quit [Changing host]
Rutix has quit [Ping timeout: 272 seconds]
nofxx has joined #ruby
zukin has quit [Ping timeout: 256 seconds]
ResidentBiscuit has quit [Remote host closed the connection]
blackmesa has joined #ruby
cschneid_ has quit [Remote host closed the connection]
abernstein has quit [Quit: abernstein]
<havenwood>
baweaver: Hrm, someone mentioned a "certificate verify failed" in #rubygems this morning.
<baweaver>
2.1.2, for some reason I was running an old version
kingkong- has quit [Remote host closed the connection]
pragmatism has joined #ruby
kingkong- has joined #ruby
SteenJobs has joined #ruby
lifted has joined #ruby
bathtub_shark has quit [Remote host closed the connection]
erlingur_ has quit [Ping timeout: 272 seconds]
erlingur_ has joined #ruby
bathtub_shark has joined #ruby
<zenspider>
baweaver: you still having that ?
Akuma has quit [Quit: So long sukkas!]
<baweaver>
haven't tried recently
<baweaver>
switched over to 2.3 again
<baweaver>
must have been testing something in that tab
SteenJobs has quit [Ping timeout: 272 seconds]
patarr has quit [Quit: patarr]
pawnbox has joined #ruby
pwnd_nsfw has joined #ruby
capitainIsh has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
pwnd_nsfw` has quit [Ping timeout: 272 seconds]
<zenspider>
git is going to be the death of me
djbkd has quit [Read error: Connection reset by peer]
pawnbox has quit [Ping timeout: 256 seconds]
dviola has joined #ruby
djbkd has joined #ruby
ur5us has quit [Remote host closed the connection]
marr has quit [Ping timeout: 265 seconds]
ur5us has joined #ruby
nando293921 has quit [Ping timeout: 264 seconds]
gizmore has joined #ruby
capitainIsh has joined #ruby
Bellthoven has joined #ruby
gizless has quit [Ping timeout: 272 seconds]
ur5us has quit [Ping timeout: 265 seconds]
im0b has quit [Ping timeout: 244 seconds]
whathappens has quit [Ping timeout: 252 seconds]
caw has quit [Ping timeout: 265 seconds]
whathappens has joined #ruby
skweek has joined #ruby
djbkd has quit [Remote host closed the connection]
symm- has quit [Quit: Leaving...]
jcao219 has quit [Ping timeout: 272 seconds]
djbkd has joined #ruby
conta has joined #ruby
djbkd has quit [Client Quit]
jcao219 has joined #ruby
im0b has joined #ruby
h1fuelcell has joined #ruby
caw has joined #ruby
nettoweb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
prawnzy has quit [Remote host closed the connection]
conta has quit [Ping timeout: 264 seconds]
SCHAAP137 has joined #ruby
<_sfiguser>
hello all i want to do a switch case with a numerica variable telling... when x < 0 then do something, when x>0 do something else do something
<_sfiguser>
why it doesnt work this way ? and can't find examples like this online ?
jackjackdripper has quit [Quit: Leaving.]
tuxaddicted has joined #ruby
pawnbox has joined #ruby
<havenwood>
_sfiguser: What version of Ruby? (Since the newer ones have neat ways.) You might be searching for the wrong thing. Try "if statement in Ruby" or something like that.
frankiee_ has joined #ruby
pawnbox has quit [Ping timeout: 252 seconds]
Akuma has joined #ruby
wldcordeiro has quit [Ping timeout: 272 seconds]
nettoweb has joined #ruby
jcao219 has quit [Ping timeout: 264 seconds]
Aquazi has quit [Quit: Leaving]
erlingur_ has quit [Ping timeout: 244 seconds]
ur5us has joined #ruby
Akuma has quit [Client Quit]
whathapp_ has joined #ruby
Akuma has joined #ruby
wpostma has joined #ruby
whathappens has quit [Ping timeout: 265 seconds]
nfk has quit [Quit: Try memory.free_dirty_pages=true in about:config]
jcao219 has joined #ruby
whathappens has joined #ruby
rakm has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
whathapp_ has quit [Read error: Connection reset by peer]
nettoweb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]