Fixed trace imports not working if there was a recording in the trace.
(a lazy cache had a withSession call in its initializer, but it was
being initialized from inside another transaction, causing locking
issues)