On 2023-04-05 14:37:45 -0700 (-0700), Clark Boylan wrote: [...]
That said looking more closely init_gi_clipboard() isn't in the current code base. Looking at the history of the project: `git log -p | grep init_gi_clipboard` produces no results either. This makes me wonder where that is coming from and what version/source of pyperclip you are using. If I grab pyperclip 1.8.2 (which is the upper constraints version for wallaby and xena) from pypi this function doesn't appear to exist there either. It is possible they rewrote their git history at some point, but best I can tell your version of pyperclip doesn't share code or history with the version on pypi specified in upper constraints for wallaby and xena. [...]
Tracking this down, it looks like a pyperclip package from a Linux distribution is leaking into that environment. The relevant functions can be found added by Ubuntu's 0001-Switch-from-GTK-2-to-GTK-3-to-avoid-import-of-mutual.patch which references https://bugzilla.gnome.org/show_bug.cgi?id=709183 as the reason for its inclusion. Other distros have copies of this patch into their packages as well (at least Debian does, not sure which others might), but mixing packages of Python libs from a Linux distribution and from PyPI in the same environment is a recipe for disaster. -- Jeremy Stanley