Reland "Don't include missing paths in CAS tree"

This is a reland of commit 16c574c18a2ad1530425106ea76b13ff9f8be4b2

Includes "data_deps" as "deps" for the "test_runner_py" target, as each
kind of dependency has a behavior this target needs: "data_deps" ensures
the dependencies are included as runtime dependencies, while "deps"
ensures the dependencies are built before the action runs. ("data_deps"
does not guarantee this.)

Tested this change on a clean build (which was breaking) and an unclean
build (to make sure nothing new has broken).

Original change's description:
> Don't include missing paths in CAS tree
>
> Skips paths that don't exist when archiving the CAS tree. If the missing
> paths aren't needed locally, they aren't needed in the CAS tree, either.
>
> Emits a warning in case we want to fix the incorrect runtime
> dependencies at the source.
>
> Bug: pdfium:1933
> Change-Id: Ib7ae7d710f73e98adc8d1fe6631ceef000efc6b5
> Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/110330
> Reviewed-by: Lei Zhang <thestig@chromium.org>
> Commit-Queue: K. Moon <kmoon@chromium.org>
> Commit-Queue: Lei Zhang <thestig@chromium.org>
> Auto-Submit: K. Moon <kmoon@chromium.org>

Bug: pdfium:1933
Change-Id: Ib910f5d41819c8f9aa8c26b273f3789004c5da48
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/110393
Commit-Queue: K. Moon <kmoon@chromium.org>
Auto-Submit: K. Moon <kmoon@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
diff --git a/testing/tools/BUILD.gn b/testing/tools/BUILD.gn
index b5277aa..f60f413 100644
--- a/testing/tools/BUILD.gn
+++ b/testing/tools/BUILD.gn
@@ -37,4 +37,7 @@
     "../../:pdfium_diff",
     "../../samples:pdfium_test",
   ]
+
+  # Force `data_deps` to be built before this target, rather than in parallel.
+  deps = data_deps
 }
diff --git a/testing/tools/generate_cas_paths.py b/testing/tools/generate_cas_paths.py
index bf41c26..43690eb 100644
--- a/testing/tools/generate_cas_paths.py
+++ b/testing/tools/generate_cas_paths.py
@@ -8,6 +8,7 @@
 from collections import deque
 import filecmp
 import json
+import logging
 from pathlib import Path
 import os
 
@@ -32,6 +33,10 @@
   while unvisited_paths:
     path = unvisited_paths.popleft()
 
+    if not path.exists():
+      logging.warning('"%(path)s" does not exist', {'path': path})
+      continue
+
     if path.is_dir():
       # Expand specific children if any are excluded.
       child_paths = expand_dir(path)