Repository navigation
Copy the target when DirectoryArchiver cannot create a symbolic link - #509
Merged
Merged
Conversation
DirectoryArchiver had the same unguarded link creation as the unarchivers, so a dir assembly of a tar holding symlinks failed on Windows without the privilege. The deferred copy moves to DeferredSymlinks, shared with AbstractUnArchiver; copying the resource content instead would write empty files for archived link entries.
slachiewicz
force-pushed
the
agent/symlink-failure-mode-dir
branch
from
October 13, 2026 20:15
2e1b95b to
51ef24c
Compare
slachiewicz
marked this pull request as ready for review
October 13, 2026 20:16
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #507.
DirectoryArchiver(the assemblydirformat) had the same unguardedSymlinkUtils.createSymbolicLinkcall, so it failed the same way on Windows without the symlink privilege. It gets the sameSymlinkFailureMode, defaultCOPY_TARGET, and the second pass moves intoDeferredSymlinks, shared withAbstractUnArchiver.Copying the resource content instead is not enough: a symlink entry from an archived file set has no content, so that would write empty files.
Verified:
mvn verify→ 360 tests, 0 failures; without theresolve()call the copy test fails.