which: add time module import

(integrated from trunk branch change d21c71b by Todd Whiteman <toddw@activestate.com>)