Forum: Ruby wrong number of arguments (0 for 2..3)

D3064ff1f45c83ccb4526275bbd6a918?d=identicon&s=25 Justin Stanczak (Guest)
on 2014-06-11 20:20
(Received via mailing list)
I'm using ruby-2.0.0-p353

When I do this:

def test_one?
   true
end

def test_two?
   true
end


test_two? && test_one? => error


I get:  wrong number of arguments (0 for 2..3)


activesupport (4.1.1) is loaded.


Seems like it should not be an issue, or I'm missing something big.
Thanks.
0e388aa42783bc651af828ef2b17c8ef?d=identicon&s=25 Jernej Mihalic (Guest)
on 2014-06-11 20:21
(Received via mailing list)
Unsibscribe please.
D3064ff1f45c83ccb4526275bbd6a918?d=identicon&s=25 Justin Stanczak (Guest)
on 2014-06-11 20:30
(Received via mailing list)
Why?


On Wed, Jun 11, 2014 at 2:20 PM, Jernej Mihalic
<mihalic.jernej@gmail.com>
0e388aa42783bc651af828ef2b17c8ef?d=identicon&s=25 Jernej Mihalic (Guest)
on 2014-06-11 20:32
(Received via mailing list)
to much emails

please
D3064ff1f45c83ccb4526275bbd6a918?d=identicon&s=25 Justin Stanczak (Guest)
on 2014-06-11 20:38
(Received via mailing list)
Who are you and why are you asking me to unsubscribe? If you get too
many
emails the leave the mailing list.


On Wed, Jun 11, 2014 at 2:31 PM, Jernej Mihalic
<mihalic.jernej@gmail.com>
0e388aa42783bc651af828ef2b17c8ef?d=identicon&s=25 Jernej Mihalic (Guest)
on 2014-06-11 20:38
(Received via mailing list)
How can I do that?
8e91a3ee19b7930c8807a30309467e4b?d=identicon&s=25 Jay Ka (jkaye31)
on 2014-06-11 20:40
(Received via mailing list)
Hi Justin,

I don't think he's asking you specifically to unsubscribe, he's just
trying
to unsubscribe from the mailing list. And you have to type
'unsubscribed'
into any thread to be removed.
D3064ff1f45c83ccb4526275bbd6a918?d=identicon&s=25 Justin Stanczak (Guest)
on 2014-06-11 20:41
(Received via mailing list)
https://www.ruby-lang.org/en/community/mailing-lists/


On Wed, Jun 11, 2014 at 2:38 PM, Jernej Mihalic
<mihalic.jernej@gmail.com>
0e388aa42783bc651af828ef2b17c8ef?d=identicon&s=25 Jernej Mihalic (Guest)
on 2014-06-11 20:42
(Received via mailing list)
unsubscribed
D3064ff1f45c83ccb4526275bbd6a918?d=identicon&s=25 Justin Stanczak (Guest)
on 2014-06-11 20:43
(Received via mailing list)
Oh. That whole thing seemed strange. Has he not heard of a filter.
D3064ff1f45c83ccb4526275bbd6a918?d=identicon&s=25 Justin Stanczak (Guest)
on 2014-06-11 20:45
(Received via mailing list)
I think this may be activesupport causing this. When I do true && false
=>
false but with activesupport loaded I get nothing.
D3064ff1f45c83ccb4526275bbd6a918?d=identicon&s=25 Justin Stanczak (Guest)
on 2014-06-11 20:50
(Received via mailing list)
No, scrap that. Did it again and it's working. Not sure why this is
having
that issue.
D3064ff1f45c83ccb4526275bbd6a918?d=identicon&s=25 Justin Stanczak (Guest)
on 2014-06-11 20:58
(Received via mailing list)
Oh crap. Just ignore me all together. I figured it out. Just one of
those
days. Not sure why I didn't put two and two together. Sorry.
4be91d1e04fd298e6122f99d6abcb88b?d=identicon&s=25 Jeremy Axelrod (Guest)
on 2014-06-11 21:09
(Received via mailing list)
Can you explain the answer?

Sent from my phone
249c7fd851c5c5ac5a1abdb756472ae1?d=identicon&s=25 Arup Rakshit (my-ruby)
on 2014-06-11 21:18
(Received via mailing list)
On Wednesday, June 11, 2014 02:20:17 PM Justin Stanczak wrote:
> end
>
>
> test_two? && test_one? => error
>
>
> I get:  wrong number of arguments (0 for 2..3)
>

Show us the full error stack trace. That will be helpful to figure out
what
was is wrong and from where it has been thrown.

--
================
Regards,
Arup Rakshit
================
Debugging is twice as hard as writing the code in the first place.
Therefore,
if you write the code as cleverly as possible, you are, by definition,
not
smart enough to debug it.

--Brian Kernighan
D3064ff1f45c83ccb4526275bbd6a918?d=identicon&s=25 Justin Stanczak (Guest)
on 2014-06-11 21:45
(Received via mailing list)
It was just a stupid mistake on my part. I just didn't follow the logic,
and tried to access a variable out of scope. I should have reviewed the
code more. Thanks.


On Wed, Jun 11, 2014 at 3:08 PM, Jeremy Axelrod
<axelrod.jeremy@gmail.com>
1442d84cb806bf6e49709e75ae58ce63?d=identicon&s=25 Florian Frank (Guest)
on 2014-06-11 23:27
(Received via mailing list)
On Wed, Jun 11, 2014 at 02:39:04PM -0400, Jason Kaye wrote:
> I don't think he's asking you specifically to unsubscribe, he's just
> trying to unsubscribe from the mailing list. And you have to type
> 'unsubscribed' into any thread to be removed.

Good one. :)
4c7c3a68dc32e45e5be62eab76944b85?d=identicon&s=25 Steve Barnes (stevewonders)
on 2014-06-12 06:10
(Received via mailing list)
Unsubscribe please


On Wednesday, June 11, 2014 9:07 PM, Justin Stanczak
<rizenine@gmail.com> wrote:



Who are you and why are you asking me to unsubscribe? If you get too
many emails the leave the mailing list. 



On Wed, Jun 11, 2014 at 2:31 PM, Jernej Mihalic
<mihalic.jernej@gmail.com> wrote:

to much emails…
15000f55138ae94b0f362ed7c625461a?d=identicon&s=25 unknown (Guest)
on 2014-06-12 09:54
(Received via mailing list)
Am 11.06.2014 20:39, schrieb Jason Kaye:
> And you have to type 'unsubscribed' into any thread to be removed.

That's wrong! You need to send "unsubscribe" to a **special** address,
please read https://www.ruby-lang.org/en/community/mailing-lists/
more carefully.

Regards,
Marcus
15000f55138ae94b0f362ed7c625461a?d=identicon&s=25 unknown (Guest)
on 2014-06-12 09:57
(Received via mailing list)
Am 12.06.2014 06:09, schrieb Steve Barnes:
> Unsubscribe please

See
https://www.ruby-lang.org/en/community/mailing-lis....
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.