Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure tmpdir usage internally is always the realpath #870

Merged
merged 1 commit into from
Jun 23, 2021

Commits on Jun 23, 2021

  1. Ensure tmpdir usage internally is always the realpath

    As it turns out os.tmpdir can point to a symlink, which can introduce path ambiguity. Some of our algorithms are sensitive to path equality, and introducing a path with indirection via a symlink can confuse the system. For example shared-internal’s explicit-relative algorithm fails to create the expected relative paths for externals as it attempts to compare /private/var/folders/… with /var/folders/…
    
    The algorithms in question are currently not coupled to the state of the filesystem, and most likely should remain decoupled, this then implies the inputs should be carefully considered and we should not introduce spurious ambiguity where the state enters the system. Given that, ensuring a stable + realpath’d tmpdir is appropriate.
    stefanpenner committed Jun 23, 2021
    Configuration menu
    Copy the full SHA
    f2d2049 View commit details
    Browse the repository at this point in the history