code: def report(self, filename=None):
      
      # TODO(zundel) set report to stream to the file
      filename = filename or self._filename
      if filename:
        # Usually the directory exists from reporting initialization, but not if clean-all was a goal.
        with safe_open(filename, 'w') as writer:
          writer.write(
            'invocation_id,task_name,targets_hash,target_id,cache_key_id,cache_key_hash,phase,valid'
            + '\n')
          for task_report in self._task_reports.values():
            task_report.report(writer)
docs: Write details of each versioned target to file
      :param string filename: file to write out the report to
  
      Fields in the report:
        invocation_id: A sequence number that increases each time a task is invoked
        task_name: The name of the task
        targets_hash: an id from a hash of all target ids to identify a VersionedTargetSet
        target_id: target id
        cache_key_id: the Id for the cache key
        cache_key_hash: computed hash for the cache key
        phase: What part of the validation check the values were captured
        valid: True if the cache is valid for the VersionedTargetSet