[issue15201] C argument errors and Python arguments error are different

2012-09-29 Thread Ramchandra Apte

Changes by Ramchandra Apte maniandra...@gmail.com:


--
versions: +Python 3.4 -Python 3.2

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15201
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15201] C argument errors and Python arguments error are different

2012-09-29 Thread Benjamin Peterson

Benjamin Peterson added the comment:

This is won't fix at least for now. The way arguments to C functions are parsed 
prevents them from ever really being the same. Specific improvements can be 
considered.

--
nosy: +benjamin.peterson
resolution:  - wont fix
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15201
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15201] C argument errors and Python arguments error are different

2012-06-27 Thread Ramchandra Apte

New submission from Ramchandra Apte maniandra...@gmail.com:

C argument errors and Python arguments error are different.
For example:
all(4,4,4)
Traceback (most recent call last):
  File stdin, line 1, in module
TypeError: all() takes exactly one argument (3 given)
def func(a):pass
a(4,4)
Traceback (most recent call last):
  File stdin, line 1, in module
TypeError: func() takes exactly 1 positional argument (2 given)
I do not know which error message is better.
I think the second example's (func) error message is better.
Though feel free to vote by commenting on this bug.
Another example with not enough arguments given:
hasattr(4)
Traceback (most recent call last):
  File stdin, line 1, in module
TypeError: hasattr expected 2 arguments, got 1
func()
Traceback (most recent call last):
  File stdin, line 1, in module
TypeError: func() takes exactly 1 argument (0 given)
I don't know which of this error messages are better.
You can vote on this by commenting.

--
components: Interpreter Core
messages: 164129
nosy: ramchandra.apte
priority: normal
severity: normal
status: open
title: C argument errors and Python arguments error are different
type: behavior
versions: Python 3.2

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15201
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15201] C argument errors and Python arguments error are different

2012-06-27 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +Arfrever

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15201
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com