Xpra: Ticket #2224: win32 python3 vs python2 install mixup

Ended up with a broken installation.

C:\Program Files\Xpra>xpra_cmd
Traceback (most recent call last):
  File "C:/msys64/mingw64/lib/python2.7/site-packages/cx_Freeze/initscripts/__st
artup__.py", line 7, in <module>
    import os
  File "C:/msys64/mingw64/lib/python2.7/os.py", line 400, in <module>
    import UserDict
  File "C:/msys64/mingw64/lib/python2.7/UserDict.py", line 116, in <module>
    import _abcoll
  File "C:/msys64/mingw64/lib/python2.7/_abcoll.py", line 11, in <module>
    from abc import ABCMeta, abstractmethod
  File "C:\Program Files\Xpra/lib/abc.py", line 147
    print(f"Class: {cls.__module__}.{cls.__qualname__}", file=file)
                                                      ^
SyntaxError: invalid syntax
C:\Program Files\Xpra>

That abc.py is the one from python3, not python2! But when we run the installer, we're supposed to remove the existing version before installing so this should not be possible.

Reminds me of #2126.



Tue, 19 Mar 2019 15:36:55 GMT - stdedos:

Replying to totaamwin32:

Hopefully this didn't cause #2224.

I remember @antoine saying that py2 vs py3 is deliberately not handled, so that shouldn't be a problem. However, it should be easy to verify:

in-between step 2 and 4, xpra uninstaller should prompt you to close xpra. If that doesn't work, try the same just before going to the step that will auto-call the uninstaller.

I haven't tried that exact scenario, but, I do remember uninstaller popping up whenever I upgrade/downgrade


Thu, 25 Jul 2019 14:35:48 GMT - Antoine Martin: status changed

Looks like a job for DelTree


Sun, 28 Jul 2019 12:02:22 GMT - Antoine Martin: status changed; resolution set

We can't actually delete the whole tree because we can't be sure where it was / is installed, so r23326 just deletes the python object files to prevent this version clash. This should be enough, and it should be safe to do.


Sat, 23 Jan 2021 05:45:30 GMT - migration script:

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/2224