Python 3.8?

Given that 3.8 is slated for a 2019-10-21 release, anyone willing to hazard a guess as to when Blender will use it? I badly need the new shared memory stuff new in 3.8

Thanks to any brave souls willing to guess :slight_smile: I have not been in the community long enough to have seen such a cycle…

Donald

Typically we follow the latest Python releases, although there is sometimes delay in adopting them for official builds - if upgrading Python too soon before a release.

That’s good to know. Thank you.

So I’m curious what you’re doing that shared memory will be useful? It’s only for multiprocessing, which I’ve rarely seen in python addons.

One downside of moving to the latest python available is compatibility of course. Say you’re doing an addon that relies on some PIP module that hasn’t moved to 3.8 what then? Or if your addon uses c-extensions to python, you have to have a version of the c-extension for each python version unless you stick to the limited ABI https://docs.python.org/3/c-api/stable.html which usually will negate some of the features.

I’m just saying there’s often a reasonable stability/compatibility reason to trail the bleeding edge.

It is for a Live Link between Blender and Daz Studio. Right now I use a local socket to transfer the data, but even with the localhost optimization, the data is still copied from one process to the other. So an already subdivided character model with mesh hair is huge and can still take a minute and a half per frame. With shared memory, there is no copying, and my tests (at least on Linux) show the transfer is virtually instantaneous (as it should be).

I am a professional developer as well, and so your point about the bleeding edge versus stability is well received; not knowing the dev’s position on that same point, I decided to ask and was prepared for something other than the answer I wanted :slight_smile: I’m rather new to Python, but if it follows the strict Unix-y convention for version numbers (and I see so much of Unix in Python), a minor version upgrade should not break compatibility, making trivial whatever upgrades should be necessary. I can already hear you saying “That’s a really nice theory, Donald…” but sometimes when the planets align, it does work that way in practice, too. Thanks for your thoughtful points.

Interesting.

Generally Python code is forward compatible across 3.x versions. Like I said though… c-extensions get a little more sticky.

The pros of updating Python 3.8:

  • ???

The cons of updating to Python 3.8

  • Breaking compatibility with https://vfxplatform.com/ CY2020
  • Making the life of anyone who wants to use compiled Python modules in Blender a lot harder.

Just to add: Pybind11 and Numpy make it very easy to pick and existing C++ computer graphics project (which there are countless), and integrate it into Blender with an easy to use UI. Here’s as an example: https://github.com/amb/QuadriFlow

The trouble being that Pybind11 targets a specific Python version and needs recompilation if the version changes.

Well as the guy above stated, shared memory for multiprocressing, if that’s your thing.

Plus, I guess you get to use walrus operators? :man_shrugging: