fossa-cli icon indicating copy to clipboard operation
fossa-cli copied to clipboard

[untested]: Make walker resilient to dir access errors

Open skilly-lily opened this issue 3 years ago • 1 comments

Overview

When the discovery traverses the file tree, it crashes if there are any errors reading the directory, or executing the directory handler.

This PR only addresses the read errors, since handler errors could be valid.

Acceptance criteria

Walker is resilient to errors during the listdir operation.

Testing plan

TBD

Risks

We lose information here, since we can't log the directories that failed (too noisy to do it for every discovery).

References

Internal slack thread: https://teamfossa.slack.com/archives/C0155DTGWB1/p1655439461261949

Checklist

  • [ ] I added tests for this PR's change (or explained in the PR description why tests don't make sense).
  • [ ] If this PR introduced a user-visible change, I added documentation into docs/.
  • [ ] If this change is externally visible, I updated Changelog.md. If this PR did not mark a release, I added my changes into an # Unreleased section at the top.
  • [ ] If I made changes to .fossa.yml or fossa-deps.{json.yml}, I updated docs/references/files/*.schema.json. You may also need to update these if you have added/removed new dependency type (e.g. pip) or analysis target type (e.g. poetry).

skilly-lily avatar Jun 17 '22 20:06 skilly-lily

resilient-walk

Baro1905 avatar Jul 12 '22 00:07 Baro1905