You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
TestXattr fails as unsupported on linux tmpfs #8564
bugA problem with current functionality, as opposed to missing functionality (enhancement)frozen-due-to-ageIssues closed and untouched for a long time, together with being locked for discussionskip-changelogBugs that have never been in a released stable version, and as such excluded from the release notes
Running tests on main I get the following failure:
--- FAIL: TestXattr (0.00s)
basicfs_test.go:596: set xattrs /tmp/TestXattr427785272/001/test: Setxattr "user.test-0": operation not supported
FAIL
Looking at the test there's a check for ErrXattrsNotSupported to skip the test, but it's just used for completely unsupported systems. Apparently tmpfs does support xattrs, but not user extended ones:
The tmpfs filesystem supports extended attributes (see xattr(7)),
but user extended attributes are not permitted.
Looks like the random attrs we write in that test are such an extend user attributes. I don't really know much about xattrs, so not sure if this warrants a wider or more elegant fix. A quick fix would be to check for "operation not supported" string in the test and skip too.
I'd assume the quick fix is fine, as getting errors if one activates syncing xattrs on a tmpfs or otherwise unsupported FS seems correct. What do you think @calmh ?
(Also bit confused CI didn't catch this - thought /tmp on tmpfs is pretty standard.)
I guess the build dockers don't have separate /tmp. Maybe we can check something like errors.Is(..., syscall.ENOTSUPP) or something, but if that fails I suppose string checking is the thing
bugA problem with current functionality, as opposed to missing functionality (enhancement)frozen-due-to-ageIssues closed and untouched for a long time, together with being locked for discussionskip-changelogBugs that have never been in a released stable version, and as such excluded from the release notes
Activity
calmh commentedon Sep 30, 2022
I guess the build dockers don't have separate /tmp. Maybe we can check something like errors.Is(..., syscall.ENOTSUPP) or something, but if that fails I suppose string checking is the thing
lib/fs: Skip xattrs test on EOPNOTSUPP (fixes syncthing#8564)
lib/fs: Skip xattrs test on EOPNOTSUPP (fixes #8564) (#8565)
Merge branch 'main' into dockerpool
Merge branch 'release'