code: def safe_extractall(
      tar: tarfile.TarFile,
      path: Path = Path("."),
      members=None,
      *,
      numeric_owner=False,
  ):
      """
      Safe wrapper around ``TarFile.extractall`` that checks all destination
      files to be strictly within the given ``path``.
      """
      will_extractall_into(tar, path)
      tar.extractall(path, members, numeric_owner=numeric_owner)
  
imports: import copy
  import tarfile
  from functools import lru_cache
  from pathlib import Path
  from typing import TYPE_CHECKING, TypeVar
label_desc: Use image node_id 3 for calling a global function with example usage: safe_extractall(tar, path, members) without return types