Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork34k
Open
Description
Bug report
Bug description:
On bcachefs create case insensitive directory with some file inside:
mkdir ncschattr +F ncstouch ncs/something.txt
then do this
importshutilshutil.copytree("ncs/","target/")
fails with
Traceback (most recent call last): File "<string>", line 1, in <module> import shutil; shutil.copytree("ncs/", "target/") ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.14/shutil.py", line 654, in copytree return _copytree(entries=entries, src=src, dst=dst, symlinks=symlinks, ignore=ignore, copy_function=copy_function, ignore_dangling_symlinks=ignore_dangling_symlinks, dirs_exist_ok=dirs_exist_ok) File "/usr/lib/python3.14/shutil.py", line 608, in _copytree raise Error(errors)shutil.Error: [('ncs/', 'target/', "[Errno 39] Directory not empty: 'target/'")]This is because of
listxattr("ncs/", "bcachefs.casefold\0bcachefs_effec"..., 256) = 46getxattr("ncs/", "bcachefs.casefold", "1", 128) = 1setxattr("target/", "bcachefs.casefold", "1", 1, 0) = -1 ENOTEMPTY (Directory not empty)getcwd("/home/user/_x", 1024) = 14happening after contents were copied and case insensitivity can't be enabled afterwards.
Note: On ext4 copytree results in a directory without casefolding flag.
CPython versions tested on:
3.14
Operating systems tested on:
Linux