Skip to content

Fix mapped volume-root backups on Windows - #83

Merged
john-behm-bertelsmann merged 1 commit into
masterfrom
fix/mapped-volume-root
Oct 9, 2026
Merged

john-behm-bertelsmann merged 1 commit into
masterfrom
fix/mapped-volume-root

Conversation

@john-behm-bertelsmann

Copy link
Copy Markdown
Collaborator

Summary

  • Ensure copyDir creates mapped root directories with MkdirAll, while still skipping root permission, ownership, and timestamp updates.
  • Add TestCopyRootDirectoryCreatesMappingWithoutChangingMetadata and record the invariant in SPEC.md.

Cause

PrefixFS maps Windows drive roots to directories inside its prefix. The previous root-directory early return skipped creating that mapped directory. Backing up a drive-root file such as D:\config.env therefore failed because its snapshot parent did not exist. Ensuring the directory exists fixes this without changing real OS-root metadata.

Verification

  • New regression failed before the fix and passed afterward without changes.
  • Full race suite and go vet ./... passed.
  • golangci-lint run: 0 issues.
  • Builds passed for Linux, macOS, and Windows on amd64 and arm64.
  • Windows test binaries compile. Native Windows test execution remains for CI.

Scope: only fs_utils.go, fs_utils_test.go, and the spec bug/invariant record; no dependencies, public APIs, or workflow changes.

PrefixFS maps Windows volume roots inside the backup directory.
Create that mapping before copying drive-root files, without
changing root permissions, ownership, or timestamps.
@john-behm-bertelsmann
john-behm-bertelsmann merged commit fc1e91a into master Oct 9, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant