python + XATTRs under cygwin?

Philippe Cerfon philcerf@gmail.com
Tue May 16 21:06:20 GMT 2023


Hey there.

Is there any known way to use XATTRs (which Cygwin seems to support in
some way, at least the standard attr(1) tool seems to work and somehow
map them into the Windows world) with Python?

The `os` module of Python3 (>3.3) comes with:
os.getxattr()
os.listxattr()
os.removexattr()
os.setxattr()
(see https://docs.python.org/3/library/os.html#linux-extended-attributes)
but these seem to be missing from the Cygwin python packages.

There is even an upstream bug
(https://github.com/python/cpython/issues/90026) about this, which has
however been closed (not because it would be fixed, but because Cygwin
is no officially maintained platform).


There are two external python modules that support xattrs:
python-xattr (https://github.com/xattr/xattr)
python-pyxattr (https://pyxattr.k1024.org/)
but neither seems to be available in Cygwin.


Any ideas or change to get one of these (ideally the ones from os) running?

Thanks,
Philippe


More information about the Cygwin mailing list