code: def get_all_errors(artifact_dir, job_links=None):
      """Extract errors from all artifact files"""
  
      errors = []
  
      paths = [
          os.path.join(artifact_dir, p)
          for p in os.listdir(artifact_dir)
          if p.endswith(".zip")
      ]
      for p in paths:
          errors.extend(
              get_errors_from_single_artifact(p, job_links=job_links)
          )
  
      return errors
  
file_path: H2O/h2o_flexgen/benchmark/third_party/transformers/utils/get_ci_error_statistics.py
imports: import argparse
  import json
  import math
  import os
  import subprocess
  import time
  import zipfile
  from collections import Counter
  import requests
label_desc: Use image node_id 5 for calling a global function with example usage: get_all_errors(artifact_dir, job_links) and returns: errors