[issue28072] Empty Strings are not parsed to None.

Ethan Furman report at bugs.python.org
Sat Sep 10 19:32:37 EDT 2016


Ethan Furman added the comment:

Empty strings are empty strings, not None.

An better way for your code example would be:

def ...():
    if url:
       ....
    else:
       raise URLError(...URL cannot be empty...)

----------
nosy: +ethan.furman
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed
type:  -> behavior

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue28072>
_______________________________________


More information about the Python-bugs-list mailing list