[client] fs.walk() now implements followlinks=False; fix fs.remove()

- Add unit test to fs_test.py to confirm walk() now ignores symlinks on Windows.
- Fix remove() on Windows, it was aliased by accident.
- These two fixes fix problems that surfaced in local_caching due to the walk
  going through directory symlinks, deleting too much.
- local_caching.NamedCache: Raise exception reusing the previous traceback.
  Otherwise it's impossible to know which line had failed. This way, we know
  which operation failed.
- local_caching.NamedCache: fix cleanup() on Windows to check symlinks the same
  way it's done on posix.
- Update local_caching_test.py to use package fs.
- Make local_caching_test.py pass on Windows.

Ran fs_test.py and local_caching_test.py on macOS and Windows.

Change-Id: Id26effd1b52a81986f4f22036e3d1a5a6765e822
Bug: 853721
Reviewed-on: https://chromium-review.googlesource.com/c/1443917
Commit-Queue: Marc-Antoine Ruel <maruel@chromium.org>
Reviewed-by: Quinten Yearsley <qyearsley@chromium.org>
Cr-Mirrored-From: https://chromium.googlesource.com/infra/luci/luci-py
Cr-Mirrored-Commit: 28ba10a22b771271620ee84a819286c8b81f3d2f
4 files changed
tree: d841392c9b319eae2d52b6980e4799a88e65ffbc
  1. example/
  2. libs/
  3. proto/
  4. tests/
  5. third_party/
  6. tools/
  7. utils/
  8. .gitignore
  9. auth.py
  10. cipd.py
  11. isolate.py
  12. isolate_format.py
  13. isolate_storage.py
  14. isolated_format.py
  15. isolateserver.py
  16. LICENSE
  17. local_caching.py
  18. LUCI_CONTEXT.md
  19. OWNERS
  20. PRESUBMIT.py
  21. README.md
  22. README.py
  23. run_isolated.py
  24. swarming.py
  25. trace_inputs.py
  26. WATCHLISTS
README.md

LUCI Python Client

This is the Python Client code for LUCI. It's part of the main python repo, and is also mirrored into a standalone client-py repo.

To contribute changes you need to clone the main python repo and then use git cl upload. The client-py repo mirror (which appears in Chromium's third_party directory) cannot be contributed to directly.

License

This project is licensed under Apache v2.0 license. See LICENSE for details.