Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 2049621 - renderdoc fails to build with Python 3.11: error: 'struct _frame' has no member named 'f_globals'
Summary: renderdoc fails to build with Python 3.11: error: 'struct _frame' has no memb...
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: renderdoc
Version: 37
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: kb1000
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: F38FTBFS F39FTBFS F40FTBFS PYTHON3.11 F37FTBFS 2242058
TreeView+ depends on / blocked
 
Reported: 2022-02-02 13:25 UTC by Tomáš Hrnčiar
Modified: 2023-12-13 18:23 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-12-05 21:03:43 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Tomáš Hrnčiar 2022-02-02 13:25:49 UTC
renderdoc fails to build with Python 3.11.0a4.

In file included from /builddir/build/BUILD/renderdoc-1.17/qrenderdoc/Code/pyrenderdoc/pyconversion.h:909,
                 from /builddir/build/BUILD/renderdoc-1.17/redhat-linux-build/qrenderdoc/renderdoc_python.cxx:4379:
/builddir/build/BUILD/renderdoc-1.17/qrenderdoc/Code/pyrenderdoc/function_conversion.h: In function 'funcType ConvertFunc(const char*, PyObject*, ExceptionHandler)':
/builddir/build/BUILD/renderdoc-1.17/qrenderdoc/Code/pyrenderdoc/function_conversion.h:306:60: error: 'struct _frame' has no member named 'f_globals'
  306 |       global_internal_handle = PyDict_GetItemString(frame->f_globals, "_renderdoc_internal");
      |                                                            ^~~~~~~~~
In file included from ../../qrenderdoc/Code/pyrenderdoc/pyconversion.h:909,
                 from renderdoc_python.cxx:4379:
../../qrenderdoc/Code/pyrenderdoc/function_conversion.h: In function 'funcType ConvertFunc(const char*, PyObject*, ExceptionHandler)':
../../qrenderdoc/Code/pyrenderdoc/function_conversion.h:306:60: error: 'struct _frame' has no member named 'f_globals'
  306 |       global_internal_handle = PyDict_GetItemString(frame->f_globals, "_renderdoc_internal");
      |                                                            ^~~~~~~~~
gmake[2]: *** [qrenderdoc/Code/pyrenderdoc/CMakeFiles/_renderdoc.dir/build.make:79: qrenderdoc/Code/pyrenderdoc/CMakeFiles/_renderdoc.dir/__/__/renderdoc_python.cxx.o] Error 1
gmake[2]: Leaving directory '/builddir/build/BUILD/renderdoc-1.17/redhat-linux-build'
gmake[1]: *** [CMakeFiles/Makefile2:650: qrenderdoc/Code/pyrenderdoc/CMakeFiles/_renderdoc.dir/all] Error 2
gmake[1]: *** Waiting for unfinished jobs....
compiling qrenderdoc_python.cxx
At global scope:
cc1plus: note: unrecognized command-line option '-Wno-unknown-warning' may have been intended to silence earlier diagnostics
gmake[3]: *** [Makefile:3672: .obj/renderdoc_python.o] Error 1
gmake[3]: *** Waiting for unfinished jobs....
In file included from ../../qrenderdoc/Code/pyrenderdoc/pyconversion.h:909,
                 from qrenderdoc_python.cxx:4036:
../../qrenderdoc/Code/pyrenderdoc/function_conversion.h: In function 'funcType ConvertFunc(const char*, PyObject*, ExceptionHandler)':
../../qrenderdoc/Code/pyrenderdoc/function_conversion.h:306:60: error: 'struct _frame' has no member named 'f_globals'
  306 |       global_internal_handle = PyDict_GetItemString(frame->f_globals, "_renderdoc_internal");
      |    

Changes of the PyFrameObject structure members:
    f_code: removed, use PyFrame_GetCode() instead. Warning: the function returns a strong reference, need to call Py_DECREF().
    f_back: changed, use PyFrame_GetBack().
    f_builtins: removed, use PyObject_GetAttrString(frame, "f_builtins").
    f_globals: removed, use PyObject_GetAttrString(frame, "f_globals").
    f_locals: removed, use PyObject_GetAttrString(frame, "f_locals").
    f_lasti: removed, use PyObject_GetAttrString(frame, "f_lasti").
    f_valuesstack: removed.
    f_stackdepth: removed.
    f_gen: removed.
    f_iblock: removed.
    f_state: removed.
    f_blockstack: removed.
    f_localsplus: removed.

The Python frame object is now created lazily. A side effect is that the f_back member must not be accessed directly, since its value is now also computed lazily. The PyFrame_GetBack() function must be called instead.

https://docs.python.org/3.11/whatsnew/3.11.html

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.11/fedora-rawhide-x86_64/03273054-renderdoc/

For all our attempts to build renderdoc with Python 3.11, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.11/package/renderdoc/

Testing and mass rebuild of packages is happening in copr. You can follow these instructions to test locally in mock if your package builds with Python 3.11:
https://copr.fedorainfracloud.org/coprs/g/python/python3.11/

Let us know here if you have any questions.

Python 3.11 is planned to be included in Fedora 37. To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.11.
A build failure prevents us from testing all dependent packages (transitive [Build]Requires), so if this package is required a lot, it's important for us to get it fixed soon.
We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side.

Comment 1 Ben Cotton 2022-02-08 20:20:42 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 36 development cycle.
Changing version to 36.

Comment 2 Ben Cotton 2022-08-09 13:12:38 UTC
This bug appears to have been reported against 'rawhide' during the Fedora Linux 37 development cycle.
Changing version to 37.

Comment 3 Miro Hrončok 2022-09-14 13:45:56 UTC
Hey, Christian. Could you please fix and rebuild the package?

Comment 4 Miro Hrončok 2022-09-28 22:34:04 UTC
Is it realistic to have this fixed in time for Fedora 37 GA?

Comment 5 Christian Kellner 2022-09-29 08:55:57 UTC
I don't have enough information but it seems that this is a bigger change and I don't have much time myself. I would lean towards a no. I wonder what that means? We pull it for F37 and re-introduce it once it is fixed upstream?

Comment 6 Miro Hrončok 2022-09-29 09:07:14 UTC
That would be my preferred option, yes.

Comment 7 Christian Kellner 2022-09-29 11:22:29 UTC
Sounds good to me.

Comment 9 nanotwerp 2022-11-08 04:11:32 UTC
This issue was fixed in this commit:
https://github.com/baldurk/renderdoc/commit/9df7d402417d8068d3e0f3550635182875646b66

I tested it out by grabbing the old .spec file, changing Source0 to the latest HEAD tarball of RenderDoc, and compiling. No other changes were necessary to compile successfully. I would also suggest that LTO can be considered for enabling again if the toolchain is set to use Clang's ThinLTO, as I'm experiencing no crashing with this setup.

Comment 10 Fedora Admin user for bugzilla script actions 2023-01-06 12:11:10 UTC
This package has changed maintainer in Fedora. Reassigning to the new maintainer of this component.

Comment 11 kb1000 2023-01-06 22:25:37 UTC
Renderdoc 1.23 (as well as 1.24), incorporating that commit, has been released since (about a month ago).
Could this package please get restored? renderdoc is really useful for graphics development, and it's quite handy to have a distribution package available.

Comment 12 kb1000 2023-02-27 18:11:33 UTC
I've made a copr for my personal use at https://copr.fedorainfracloud.org/coprs/kb1000/renderdoc, which proves newer versions do build and run with Python 3.11, on Fedora 37 (that's 1.25 now, and I made no other changes than changing version/release).
Since there hasn't been any activity by the package maintainer since, I assume that means the package is unmaintained now? Is it possible to get the changes in through a different way?

Comment 13 Fedora Admin user for bugzilla script actions 2023-05-17 12:08:59 UTC
This package has changed maintainer in Fedora. Reassigning to the new maintainer of this component.

Comment 14 Aoife Moloney 2023-11-23 00:08:16 UTC
This message is a reminder that Fedora Linux 37 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora Linux 37 on 2023-12-05.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
'version' of '37'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, change the 'version' 
to a later Fedora Linux version. Note that the version field may be hidden.
Click the "Show advanced fields" button if you do not see it.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora Linux 37 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora Linux, you are encouraged to change the 'version' to a later version
prior to this bug being closed.

Comment 15 Mikhail 2023-11-23 07:06:04 UTC
Maybe it's time to return renderdoc to official repo?

Comment 16 Marc-Andre Lureau 2023-11-28 07:36:40 UTC
+1

Comment 17 Marc-Andre Lureau 2023-12-04 07:19:46 UTC
@kaeptmblaubaer1000 are you going to unretire the package? thanks

Comment 18 kb1000 2023-12-04 10:54:32 UTC
I'd love to, but I'm not even in the packagers group or anything like that, so not sure if I can even?

Comment 19 Marc-Andre Lureau 2023-12-04 11:14:05 UTC
(In reply to kb1000 from comment #18)
> I'd love to, but I'm not even in the packagers group or anything like that,
> so not sure if I can even?

Well, it's a good time to get involved then :)

Apparently you have to open a releng issue, similar to
https://pagure.io/releng/issue/11818

with a fresh package review bug, since renderdoc was retired for >8weeks.

And make this new bug depend on https://bugzilla.redhat.com/show_bug.cgi?id=FE-NEEDSPONSOR, to get sponsored.

(I am assigning this bug to you, but I think we could also close it)

Comment 20 Aoife Moloney 2023-12-05 21:03:43 UTC
Fedora Linux 37 entered end-of-life (EOL) status on None.

Fedora Linux 37 is no longer maintained, which means that it
will not receive any further security or bug fix updates. As a result we
are closing this bug.

If you can reproduce this bug against a currently maintained version of Fedora Linux
please feel free to reopen this bug against that version. Note that the version
field may be hidden. Click the "Show advanced fields" button if you do not see
the version field.

If you are unable to reopen this bug, please file a new report against an
active release.

Thank you for reporting this bug and we are sorry it could not be fixed.

Comment 21 Marc-Andre Lureau 2023-12-11 11:05:41 UTC
@kaeptmblaubaer1000 are you making progress?

Comment 22 kb1000 2023-12-13 18:23:05 UTC
I've opened https://bugzilla.redhat.com/show_bug.cgi?id=2254392 now.


Note You need to log in before you can comment on or make changes to this bug.