Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

python 3.7 support #1878

Closed
totaam opened this issue Jun 14, 2018 · 6 comments
Closed

python 3.7 support #1878

totaam opened this issue Jun 14, 2018 · 6 comments

Comments

@totaam
Copy link
Collaborator

totaam commented Jun 14, 2018

Python 3.7 is due to be released soon: Python 3.7.0rc1, there are a number of things we can take advantage of, some may allow us to drop existing workarounds.

The most interesting features:

@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2018

Eventually, it would be nice to be able to compile with the new buffer interface and avoid deprecation warnings like #1884.

In the meantime:

  • r19908 silences the deprecation warnings
  • r19909 switches to python 3.7 on win32 (now the default with msys2)

New problem: OpenGL_accelerate doesn't build - see #1883.

@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2018

There's a major blocker with cx_freeze, once again falling flat on its face.
Looks like it does not support python 3.7 yet, and this also affects pyinstaller: zipimport.ZipImportError: can't find module 'encodings'.

$ ./Xpra_cmd.exe attach tcp:192.168.1.5:10000
Fatal Python error: init_sys_streams: can't initialize sys standard streams
zipimport.ZipImportError: can't find module 'io'

Moving the missing modules by hand into the "library.zip" doesn't really help and the resulting executable still fails with:

$ ./Xpra_cmd.exe attach tcp:192.168.1.5:10000
zipimport.ZipImportError: can't find module '__startup__'

BTW, those modules were already hard-coded in setup.py to workaround existing cx_freeze breakage:

            #hopefully, cx_Freeze will fix this horror:
            #(we shouldn't have to deal with DLL dependencies)
            import site
            lib_python = os.path.dirname(site.getsitepackages()[0])
            lib_dynload_dir = os.path.join(lib_python, "lib-dynload")
            add_data_files('', glob.glob("%s/zlib*dll" % lib_dynload_dir))
            for x in ("io", "codecs", "abc", "_weakrefset", "encodings"):
                add_data_files("lib/", glob.glob("%s/%s*" % (lib_python, x)))

That's amongst a few other workarounds (base_prefix, numpy, etc)

@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2018

cx_freeze can be fixed with this patch: Compilation correct .pyc files for Python 3.7.0

Created a mingw ticket for this: cx_Freeze for python3.7 needs a patch - bytecode is unusable

@totaam
Copy link
Collaborator Author

totaam commented Aug 9, 2018

The MSYS2 package has been updated with the patch and we have workarounds for the rest.

@totaam totaam closed this as completed Aug 9, 2018
@totaam
Copy link
Collaborator Author

totaam commented Sep 21, 2018

One of the few noisy deprecation warnings left is from [https://github.com/pyparsing/] (fixed in 2.2.1 - Fix collections ABCs deprecation warning).

@totaam
Copy link
Collaborator Author

totaam commented Sep 23, 2018

For websockify, see #1568

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant