code: def _backcompatible_cache_file(query_flags, bed_file, target_name, data):
      
      cmd_id = "num_" + " and ".join(query_flags).replace(" ", "_")
      if bed_file is not None:
          target_name = target_name or os.path.basename(bed_file)
          cmd_id += "_on_" + target_name
      work_dir = os.path.join(dd.get_work_dir(data), "coverage", dd.get_sample_name(data), "sambamba")
      output_file = os.path.join(work_dir, cmd_id)
      if utils.file_exists(output_file):
          return output_file
docs: Back-compatible: retrieve cache file from previous location.