[Python-Dev] python 3 niggle: None < 1 raises TypeError
v+python at g.nevcal.com
Wed Feb 19 20:23:48 CET 2014
On 2/19/2014 2:53 AM, Lennart Regebro wrote:
> On Tue, Feb 18, 2014 at 5:10 PM, Mark Lawrence <breamoreboy at yahoo.co.uk> wrote:
>> Sorry if this has already been suggested, but why not introduce a new
>> singleton to make the database people happier if not happy? To avoid
>> confusion call it dbnull? A reasonable compromise or complete cobblers? :)
> I think this is possible already, for the database people. The problem
> is that it will not pass the is None test, which at the very least is
> not backwards compatible with how they have used it before.
The new singleton will be called something else, likely with Null in the
name, so that's what I'll call it here... Null.
So when switching from None to Null, you must also switch from "is None"
to "is Null".
Of course it is not backwards compatible... but once all the "database
related None usage" is switched to "Null usage" it should work the same
as before, but with proper (for some database's definition of proper)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Python-Dev