diff --git a/Python/ceval.c b/Python/ceval.c index 3b984c8115d..d4be04e4e45 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -3176,12 +3176,12 @@ err_args(PyObject *func, int flags, int nargs) { if (flags & METH_NOARGS) PyErr_Format(PyExc_TypeError, - "%.200s() takes 1 argument (%d given)", + "%.200s() takes no arguments (%d given)", ((PyCFunctionObject *)func)->m_ml->ml_name, nargs); else PyErr_Format(PyExc_TypeError, - "%.200s() takes no arguments (%d given)", + "%.200s() takes exactly one argument (%d given)", ((PyCFunctionObject *)func)->m_ml->ml_name, nargs); }