linux wayland segfault
Segfault in SDL as it tries to initialize the wayland display. There is very chance this could just be a setup issue, but might be useful to investigate. I am running it in a fedora 40 toolbox environment. I've confirmed I can run other GL based applications (glmark2-wayland) without issue.
repro:
$ git clone git@gitlab.steamos.cloud:devkit/steamos-devkit.git
$ cd steamos-devkit
$ pipenv shell
$ pip install -r requirements.txt
$ cd client
$ ./devkit-gui.py
UserWarning: Using SDL2 binaries from pysdl2-dll 2.30.10
Force no_proxy: localhost,127.0.0.0/8
Loaded settings: '/var/home/bob/.devkit-client-gui/settings.pickle'
Valve devkit client UI <undefined>
Python 3.12.7
Using pyimgui 2.0.0
Using imgui 1.82
Using SDL2 2.30.10
Segmentation fault (core dumped)
stack trace:
$ coredumpctl debug
...
(gdb) bt
#0 0x0000000000000000 in ?? ()
#1 0x00007f6718d9f79f in Wayland_VideoInit () from /var/home/bob/.local/share/virtualenvs/steamos-devkit-HoP-0bn_/lib/python3.12/site-packages/sdl2dll/dll/libSDL2-2.0.so
#2 0x00007f6718d482b3 in SDL_VideoInit_REAL () from /var/home/bob/.local/share/virtualenvs/steamos-devkit-HoP-0bn_/lib/python3.12/site-packages/sdl2dll/dll/libSDL2-2.0.so
#3 0x00007f6718c2c180 in SDL_InitSubSystem_REAL.part.0 () from /var/home/bob/.local/share/virtualenvs/steamos-devkit-HoP-0bn_/lib/python3.12/site-packages/sdl2dll/dll/libSDL2-2.0.so
#4 0x00007f671aeba056 in ffi_call_unix64 () at ../src/x86/unix64.S:104
#5 0x00007f671aeb66a0 in ffi_call_int (cif=cif@entry=0x7fff5ff63270, fn=<optimized out>, rvalue=<optimized out>, avalue=<optimized out>, closure=closure@entry=0x0) at ../src/x86/ffi64.c:673
#6 0x00007f671aeb94ee in ffi_call (cif=cif@entry=0x7fff5ff63270, fn=fn@entry=0x7f6718c52a10 <SDL_Init>, rvalue=rvalue@entry=0x7fff5ff631d0, avalue=avalue@entry=0x7fff5ff631c0) at ../src/x86/ffi64.c:710
#7 0x00007f671aec842b in _call_function_pointer (flags=<optimized out>, pProc=0x7f6718c52a10 <SDL_Init>, avalues=0x7fff5ff631c0, atypes=<optimized out>, restype=<optimized out>, resmem=<optimized out>, argcount=1, argtypecount=<optimized out>)
at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Modules/_ctypes/callproc.c:931
#8 _ctypes_callproc (pProc=<optimized out>, argtuple=argtuple@entry=0x7f671b597760, flags=<optimized out>, argtypes=<optimized out>, restype=<optimized out>, checker=<optimized out>) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Modules/_ctypes/callproc.c:1273
#9 0x00007f671aed2562 in PyCFuncPtr_call (self=self@entry=0x7f6718f76f90, inargs=inargs@entry=0x7f671b597760, kwds=kwds@entry=0x0) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Modules/_ctypes/_ctypes.c:4173
#10 0x00007f672956a516 in _PyObject_MakeTpCall (tstate=0x7f67299cef50 <_PyRuntime+458992>, callable=0x7f6718f76f90, args=0x7f6729b59290, nargs=1, keywords=0x0) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Objects/call.c:240
#11 0x00007f6729573225 in _PyEval_EvalFrameDefault (tstate=<optimized out>, frame=<optimized out>, throwflag=<optimized out>) at Python/bytecodes.c:2715
#12 0x00007f67295fe3b4 in PyEval_EvalCode (co=0x7f671b531830, globals=<optimized out>, locals=0x7f671b5f5900) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Python/ceval.c:578
#13 0x00007f6729623ada in run_eval_code_obj (tstate=tstate@entry=0x7f67299cef50 <_PyRuntime+458992>, co=co@entry=0x7f671b531830, globals=globals@entry=0x7f671b5f5900, locals=locals@entry=0x7f671b5f5900) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Python/pythonrun.c:1722
#14 0x00007f672961e10e in run_mod (mod=mod@entry=0x555bea2d6240, filename=filename@entry=0x7f671b549b50, globals=globals@entry=0x7f671b5f5900, locals=locals@entry=0x7f671b5f5900, flags=flags@entry=0x7fff5ff63830, arena=arena@entry=0x7f671b51be10)
at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Python/pythonrun.c:1743
#15 0x00007f6729638b53 in pyrun_file (fp=fp@entry=0x555bea25a230, filename=filename@entry=0x7f671b549b50, start=start@entry=257, globals=globals@entry=0x7f671b5f5900, locals=locals@entry=0x7f671b5f5900, closeit=closeit@entry=1, flags=0x7fff5ff63830)
at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Python/pythonrun.c:1643
#16 0x00007f672963842c in _PyRun_SimpleFileObject (fp=0x555bea25a230, filename=0x7f671b549b50, closeit=1, flags=0x7fff5ff63830) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Python/pythonrun.c:433
#17 0x00007f672963800f in _PyRun_AnyFileObject (fp=0x555bea25a230, filename=0x7f671b549b50, closeit=1, flags=0x7fff5ff63830) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Python/pythonrun.c:78
#18 0x00007f6729630213 in pymain_run_file_obj (program_name=0x7f671b5fc060, filename=0x7f671b549b50, skip_source_first_line=0) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Modules/main.c:360
#19 pymain_run_file (config=0x7f6729971b30 <_PyRuntime+77008>) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Modules/main.c:379
#20 pymain_run_python (exitcode=0x7fff5ff63804) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Modules/main.c:633
#21 Py_RunMain () at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Modules/main.c:713
#22 0x00007f67295e7e6c in Py_BytesMain (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/python3.12-3.12.7-1.fc40.x86_64/Modules/main.c:767
#23 0x00007f6729238088 in __libc_start_call_main (main=main@entry=0x555bb9b8e160 <main>, argc=argc@entry=2, argv=argv@entry=0x7fff5ff63a98) at ../sysdeps/nptl/libc_start_call_main.h:58
#24 0x00007f672923814b in __libc_start_main_impl (main=0x555bb9b8e160 <main>, argc=2, argv=0x7fff5ff63a98, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fff5ff63a88) at ../csu/libc-start.c:360
#25 0x0000555bb9b8e095 in _start ()
also tried X11 display
$ SDL_VIDEODRIVER=x11 ./devkit-gui.py
UserWarning: Using SDL2 binaries from pysdl2-dll 2.30.10
Force no_proxy: localhost,127.0.0.0/8
Loaded settings: '/var/home/bob/.devkit-client-gui/settings.pickle'
Valve devkit client UI <undefined>
Python 3.12.7
Using pyimgui 2.0.0
Using imgui 1.82
Using SDL2 2.30.10
Traceback (most recent call last):
File "/var/home/bob/development/valve/steamos-devkit/client/./devkit-gui.py", line 4, in <module>
devkit_client.gui2.main()
File "/var/home/bob/development/valve/steamos-devkit/client/devkit_client/gui2/gui2.py", line 3476, in main
viewport.setup()
File "/var/home/bob/development/valve/steamos-devkit/client/devkit_client/gui2/gui2.py", line 3167, in setup
raise Exception('SDL_Init failed: %d'.format(sdl2.SDL_GetError()))
Exception: SDL_Init failed: %d
Saved settings '/var/home/bob/.devkit-client-gui/settings.pickle'