code: def test_cache_write_failure_is_ignored(monkeypatch, capsys):
      def bad_write(*args, **kwargs):
          raise FileNotFoundError("unable to copy from source file")
  
      monkeypatch.setattr(shutil, "copyfileobj", bad_write)
      policy = WandbStoragePolicy()
      path = Path("foo.txt")
      path.write_text("hello")
  
      entry = ArtifactManifestEntry(
          path=str(path),
          digest="NWQ0MTQwMmFiYzRiMmE3NmI5NzE5ZDkxMTAxN2M1OTI=",
          local_path=str(path),
          size=path.stat().st_size,
      )
  
      policy._write_cache(entry)
  
      captured = capsys.readouterr()
      assert "Failed to cache" in captured.err
  
imports: import asyncio
  import functools
  import queue
  import shutil
  import unittest.mock
  from pathlib import Path
  from typing import TYPE_CHECKING, Any, Mapping, Optional
  from unittest.mock import Mock
  import pytest
  import requests
  from wandb.filesync.step_prepare import ResponsePrepare, StepPrepare
  from wandb.sdk.artifacts.artifact import Artifact
  from wandb.sdk.artifacts.artifact_file_cache import ArtifactFileCache
  from wandb.sdk.artifacts.artifact_instance_cache import artifact_instance_cache
  from wandb.sdk.artifacts.artifact_manifest_entry import ArtifactManifestEntry
  from wandb.sdk.artifacts.exceptions import ArtifactNotLoggedError
  from wandb.sdk.artifacts.storage_policies.wandb_storage_policy import WandbStoragePolicy
label_desc: Use image node_id 13 for calling a global function with example usage: test_cache_write_failure_is_ignored(monkeypatch, capsys) without return types