# Will 9.2 support Python 3.11

**URL:** <https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398>\
**Category:** Development\
**Tags:** python\
**Created:** [September 20, 2022, 2:27am UTC](https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398 "2022-09-20T02:27:07Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![parched](https://discourse.vtk.org/user_avatar/discourse.vtk.org/parched/32/5235_2.png) [@parched](https://discourse.vtk.org/u/parched)\
**Post date:** [September 20, 2022, 2:27am UTC](https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398/1 "2022-09-20T02:27:07Z")

</div>

Python 3.11 is planned to be released in 1 months time and the ABI is stable.  
Will support be added to the 9.2 release?  
Is it just a matter of adding it to the CMake files, or is there breaking changes in the C API?

[Python Release Python 3.11.0rc2 | Python.org](https://www.python.org/downloads/release/python-3110rc2/)

---

<div class="post-metadata">

**Author:** ![ben.boeckel](https://discourse.vtk.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.vtk.org/u/ben.boeckel)\
**Post date:** [September 20, 2022, 11:54am UTC](https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398/2 "2022-09-20T11:54:03Z")

</div>

We can try, but if there are behavior breakages, there’s no guarantee that the fixes will be suitable for 9.2 (3.10 had interpreter init changes that made 9.1 untestable without some invasive patches).

---

<div class="post-metadata">

**Author:** ![dgobbi](https://discourse.vtk.org/user_avatar/discourse.vtk.org/dgobbi/32/18_2.png) [@dgobbi](https://discourse.vtk.org/u/dgobbi)\
**Post date:** [September 20, 2022, 12:35pm UTC](https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398/3 "2022-09-20T12:35:01Z")

</div>

For what it’s worth, I tested Python 3.11b3 with VTK in June (on Linux only) and didn’t encounter any problems.

---

<div class="post-metadata">

**Author:** ![ben.boeckel](https://discourse.vtk.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.vtk.org/u/ben.boeckel)\
**Post date:** [September 21, 2022, 7:25pm UTC](https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398/4 "2022-09-21T19:25:36Z")

</div>

I suspect that us being pinned to a specific Python image doesn’t help this.

I need to get back to [this issue](https://github.com/pypa/manylinux/issues/1310) to figure out why new Python Docker images broke our builds. Once this is done, I can try adding 3.11 builds to see what happens.

---

<div class="post-metadata">

**Author:** ![ben.boeckel](https://discourse.vtk.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.vtk.org/u/ben.boeckel)\
**Post date:** [October 2, 2022, 1:33am UTC](https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398/5 "2022-10-02T01:33:30Z")

</div>

3.11 wheels are currently blocked on dependencies not providing wheels for macOS (building them works on Linux and Windows) because we [relocate `Python.framework`](https://github.com/gregneagle/relocatable-python) for CI, but the framework has lots of hard-coded paths to where it is “supposed” to live, so compilation of sdists for some dependencies fail.

I can at least test VTK proper with 3.11 on ~~macOS and~~ (we use Xcode’s `Python.framework` on macOS) Windows. (I see 3.11 is available in Fedora 35, so that can be done once [this MR](https://gitlab.kitware.com/vtk/vtk/-/merge_requests/9204) gets back to the top of my list.

MR is here: [https://gitlab.kitware.com/vtk/vtk/-/merge\_requests/9588](https://gitlab.kitware.com/vtk/vtk/-/merge_requests/9588)

---

<div class="post-metadata">

**Author:** ![axh](https://discourse.vtk.org/user_avatar/discourse.vtk.org/axh/32/1236_2.png) [@axh](https://discourse.vtk.org/u/axh)\
**Post date:** [December 9, 2022, 7:13am UTC](https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398/6 "2022-12-09T07:13:11Z")

</div>

Would it be possible to at least release the working Linux wheels fro 3.11 and fix the MacOS later?

---

<div class="post-metadata">

**Author:** ![ben.boeckel](https://discourse.vtk.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.vtk.org/u/ben.boeckel)\
**Post date:** [January 1, 2023, 11:59pm UTC](https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398/7 "2023-01-01T23:59:10Z")

</div>

9.2.4 is out with 3.11 wheels on all three platforms.

---

<div class="post-metadata">

**Author:** ![axh](https://discourse.vtk.org/user_avatar/discourse.vtk.org/axh/32/1236_2.png) [@axh](https://discourse.vtk.org/u/axh)\
**Post date:** [January 2, 2023, 7:27am UTC](https://discourse.vtk.org/t/will-9-2-support-python-3-11/9398/8 "2023-01-02T07:27:42Z")

</div>

Fantastic. Thanks!
