Str(mybytes): wrong docs?

In the official documentation, the signature for str() passing a bytes object is:

class str ( object=b’’ , encoding=‘utf-8’ , errors=‘strict’ )

But the documentation says:

If at least one of encoding or errors is given, […] then str(bytes, encoding, errors) is equivalent to bytes.decode(encoding, errors) . […]

Passing a bytes object to str() without the encoding or errors arguments falls under the first case of returning the informal string representation

Indeed I tested it in REPL and the docs are correct. But in this case, I suppose the correct signature of the class is:

class str ( object=b’’ , encoding=None , errors=None )
class str ( object=b’’ [, encoding [, errors ] ] )

as help(str) reports.

If the docs are correct, why do you want to change the documented
signature?

encoding = None is not a valid encoding:

> str(b'abcd', encoding=None)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: str() argument 2 must be str, not None

The docs says that if encoding or errors is given, then bytes.decode(encoding, errors) is used.

But the signatures says that encoding is 'utf-8' by default and errors is 'strict' by default.

If the signature is correct, the default behavior will be using bytes.decode("utf-8", "strict"). But this is not true.

In REPL, help(str) returns:

str(bytes_or_buffer[, encoding[, errors]])

so I think this is the correct signature.