def _finalize(self):
        """Dump traces using cPickle."""
        container = {}
        try:
            for name in self._traces:
                container[name] = self._traces[name]._trace
            container['_state_'] = self._state_

            file = open(self.filename, 'w+b')
            std_pickle.dump(container, file)
            file.close()
        except AttributeError:
            pass
def _finalize ( self ) : container = { } try : for name in self . _traces : container [ name ] = self . _traces [ name ] . _trace container [ '_state_' ] = self . _state_ file = open ( self . filename , 'w+b' ) std_pickle . dump ( container , file ) file . close ( ) except AttributeError : pass
Dump traces using cPickle.