Python 3.13 bug: venv created from cvmfs not possible in some cases

Please be aware of the following bug in Python 3.13 and higher: Cannot create venvs on small-xattr filesystems when CPython is installed somewhere with large xattrs (Regression from 3.12) · Issue #127638 · python/cpython · GitHub

From Python 3.13 when creating a venv, python also tries to copy extended attributes from the files to the newly created venv directory.

“When CPython is installed on a filesystem which contains large extended attributes (such as CVMFS, more below), and the venv is created on a filesystem which only supports xattr values one block big (usually 4KiB, such as ext3/4 or btrfs), an error arises” resulting in a broken venv.

There’s a feature that is so far undocumented called CVMFS_MAGIC_XATTRS_VISIBILITY=rootonly that will very likely fix this problem on the cvmfs side.

This is already set as the default in all the main 3 configuration repositories (default, egi, osg).

1 Like

Oh it’s also the default setting since 2.10.0. It was originally developed as a fix for another Python feature, the copy2 function.