diff --git a/fsspec/implementations/cached.py b/fsspec/implementations/cached.py
index 4a13834..31fb3ff 100644
--- a/fsspec/implementations/cached.py
+++ b/fsspec/implementations/cached.py
@@ -614,20 +614,28 @@ class WholeFileCacheFileSystem(CachingFileSystem):
         getpaths = []
         storepaths = []
         fns = []
-        for p in paths:
-            detail = self._check_file(p)
-            if not detail:
-                fn = self._make_local_details(p)
-                getpaths.append(p)
-                storepaths.append(fn)
-            else:
-                detail, fn = detail if isinstance(detail, tuple) else (None, detail)
-            fns.append(fn)
+        out = {}
+        for p in paths.copy():
+            try:
+                detail = self._check_file(p)
+                if not detail:
+                    fn = self._make_local_details(p)
+                    getpaths.append(p)
+                    storepaths.append(fn)
+                else:
+                    detail, fn = detail if isinstance(detail, tuple) else (None, detail)
+                fns.append(fn)
+            except Exception as e:
+                if on_error == "raise":
+                    raise
+                if on_error == "return":
+                    out[p] = e
+                paths.remove(p)
+
         if getpaths:
             self.fs.get(getpaths, storepaths)
             self.save_cache()
 
-        out = {}
         callback.set_size(len(paths))
         for p, fn in zip(paths, fns):
             with open(fn, "rb") as f:

diff --git a/fsspec/implementations/tests/test_cached.py b/fsspec/implementations/tests/test_cached.py
index 2b6d538..53ec289 100644
--- a/fsspec/implementations/tests/test_cached.py
+++ b/fsspec/implementations/tests/test_cached.py
@@ -924,3 +924,28 @@ def test_str():
     lfs = LocalFileSystem()
     cfs = CachingFileSystem(fs=lfs)
     assert "CachingFileSystem" in str(cfs)
+
+
+def test_getitems_errors(tmpdir):
+    tmpdir = str(tmpdir)
+    os.makedirs(os.path.join(tmpdir, "afolder"))
+    open(os.path.join(tmpdir, "afile"), "w").write("test")
+    open(os.path.join(tmpdir, "afolder", "anotherfile"), "w").write("test2")
+    m = fsspec.get_mapper("file://" + tmpdir)
+    assert m.getitems(["afile", "bfile"], on_error="omit") == {"afile": b"test"}
+
+    # my code
+    m2 = fsspec.get_mapper("simplecache::file://" + tmpdir)
+    assert m2.getitems(["afile"], on_error="omit") == {"afile": b"test"}  # works
+    assert m2.getitems(["afile", "bfile"], on_error="omit") == {
+        "afile": b"test"
+    }  # throws KeyError
+
+    with pytest.raises(KeyError):
+        m.getitems(["afile", "bfile"])
+    out = m.getitems(["afile", "bfile"], on_error="return")
+    assert isinstance(out["bfile"], KeyError)
+    m = fsspec.get_mapper("file://" + tmpdir, missing_exceptions=())
+    assert m.getitems(["afile", "bfile"], on_error="omit") == {"afile": b"test"}
+    with pytest.raises(FileNotFoundError):
+        m.getitems(["afile", "bfile"])

bug: FSMap on_error option does not work with simplecache
Recently, I noticed that when I create a FSMap to a `simplecache` FS, the `on_error="omit"` does not work as intended. Here is an example, which is a modified version of `test_getitems_errors` in `/fsspec/tests/test_mapping.py` that I ran with FSSpec version 2023.1.0:

```py
def test_getitems_errors(tmpdir):
    tmpdir = str(tmpdir)
    os.makedirs(os.path.join(tmpdir, "afolder"))
    open(os.path.join(tmpdir, "afile"), "w").write("test")
    open(os.path.join(tmpdir, "afolder", "anotherfile"), "w").write("test2")
    m = fsspec.get_mapper("file://" + tmpdir)
    assert m.getitems(["afile", "bfile"], on_error="omit") == {"afile": b"test"}

    # my code
    m2 = fsspec.get_mapper("simplecache::file://" + tmpdir)
    assert m2.getitems(["afile"], on_error="omit") == {"afile": b"test"} # works
    assert m2.getitems(["afile", "bfile"], on_error="omit") == {"afile": b"test"} # throws KeyError

    with pytest.raises(KeyError):
        m.getitems(["afile", "bfile"])
    out = m.getitems(["afile", "bfile"], on_error="return")
    assert isinstance(out["bfile"], KeyError)
    m = fsspec.get_mapper("file://" + tmpdir, missing_exceptions=())
    assert m.getitems(["afile", "bfile"], on_error="omit") == {"afile": b"test"}
    with pytest.raises(FileNotFoundError):
        m.getitems(["afile", "bfile"])
```

In the example, a `KeyError` is still thrown even when `on_error="omit"` is specified. I was able to reproduce this bug both on the local filesystem (as shown in the example) as well as on GCS.
fsspec/implementations/tests/test_cached.py::test_getitems_errors
fsspec/implementations/tests/test_cached.py::test_idempotent fsspec/implementations/tests/test_cached.py::test_write fsspec/implementations/tests/test_cached.py::test_clear fsspec/implementations/tests/test_cached.py::test_clear_expired fsspec/implementations/tests/test_cached.py::test_pop fsspec/implementations/tests/test_cached.py::test_write_pickle_context fsspec/implementations/tests/test_cached.py::test_local_filecache_creates_dir_if_needed[filecache] fsspec/implementations/tests/test_cached.py::test_local_filecache_creates_dir_if_needed[simplecache] fsspec/implementations/tests/test_cached.py::test_local_filecache_creates_dir_if_needed[blockcache] fsspec/implementations/tests/test_cached.py::test_get_mapper[filecache-True] fsspec/implementations/tests/test_cached.py::test_get_mapper[filecache-False] fsspec/implementations/tests/test_cached.py::test_get_mapper[simplecache-True] fsspec/implementations/tests/test_cached.py::test_get_mapper[simplecache-False] fsspec/implementations/tests/test_cached.py::test_get_mapper[blockcache-True] fsspec/implementations/tests/test_cached.py::test_get_mapper[blockcache-False] fsspec/implementations/tests/test_cached.py::test_local_filecache_basic fsspec/implementations/tests/test_cached.py::test_local_filecache_does_not_change_when_original_data_changed fsspec/implementations/tests/test_cached.py::test_local_filecache_gets_from_original_if_cache_deleted fsspec/implementations/tests/test_cached.py::test_local_filecache_with_new_cache_location_makes_a_new_copy fsspec/implementations/tests/test_cached.py::test_filecache_multicache fsspec/implementations/tests/test_cached.py::test_filecache_multicache_with_same_file_different_data_reads_from_first[filecache] fsspec/implementations/tests/test_cached.py::test_filecache_multicache_with_same_file_different_data_reads_from_first[simplecache] fsspec/implementations/tests/test_cached.py::test_filecache_with_checks fsspec/implementations/tests/test_cached.py::test_add_file_to_cache_after_save fsspec/implementations/tests/test_cached.py::test_with_compression[gzip-filecache] fsspec/implementations/tests/test_cached.py::test_with_compression[gzip-simplecache] fsspec/implementations/tests/test_cached.py::test_with_compression[bz2-filecache] fsspec/implementations/tests/test_cached.py::test_with_compression[bz2-simplecache] fsspec/implementations/tests/test_cached.py::test_again[simplecache] fsspec/implementations/tests/test_cached.py::test_again[filecache] fsspec/implementations/tests/test_cached.py::test_multi_cache[simplecache] fsspec/implementations/tests/test_cached.py::test_multi_cache[filecache] fsspec/implementations/tests/test_cached.py::test_multi_cache_chain[simplecache] fsspec/implementations/tests/test_cached.py::test_multi_cache_chain[filecache] fsspec/implementations/tests/test_cached.py::test_strip[blockcache] fsspec/implementations/tests/test_cached.py::test_strip[simplecache] fsspec/implementations/tests/test_cached.py::test_strip[filecache] fsspec/implementations/tests/test_cached.py::test_cached_write[simplecache] fsspec/implementations/tests/test_cached.py::test_cached_write[filecache] fsspec/implementations/tests/test_cached.py::test_expiry fsspec/implementations/tests/test_cached.py::test_equality fsspec/implementations/tests/test_cached.py::test_str