After some experimentation, at least with the way I am working with web2py’s orm, the migrate command causes problems from an interactive shell session, i.e. within iPython.
So instead of
I have to use
migrate=’some_file.table’ if request.env else False
That’s no so bad. Previously I thought I would have to use
migrate=’some_file.table’ if __name__==’__builtin__’ else False
I didn’t like that. There may be another way but this is pretty clean and consistent for now. It also means I can combine ORMs with web2py’s orm now.