← Back to team overview

launchpad-dev team mailing list archive

Making migrating to storm easier.

 

Amongst other migration issues, __nonzero__ on SQLObjectResultSet
makes converting SQLObject to Storm code tricky, because its hard to
grep for, silently fails (bool(now-storm-resultset) -> always true).

I think it would be great to finish eliminating SQLObject from the
code base because - well, we're all agreed on that.

So, I propose to put together a patch for storm to make setting an
environment variable control warning/blowing up on this method and
potentially others.

I'm thinking something like this:
STORM_WARN_SQLOBJECT_ONLY at import time ->
-> SQLObjectResultSet.__nonzero__ will warn
-> ResultSet.__nonzero__ will exist and raise

Does this sound useful or crackful ?

-Rob



Follow ups