flathub / net.lutris.Lutris

https://flathub.org/apps/details/net.lutris.Lutris
127 stars 26 forks source link

Exits after a few seconds #341

Open Seneral opened 1 year ago

Seneral commented 1 year ago

Bug description

WARNING: I found evidence that this also happens with other packages, but not necessarily the same for each user: https://discourse.flathub.org/t/debugging-flatpak-early-exit-issues/4345/4 So this might not be related to Lutris at all. But it only happens for lutris for me, so here I am. I also opened a flatpak issue since this might be a more widespread problem.

This flatpak exits after several dozen seconds, with or without interaction. Trying to debug it with flatpak reveals that the whole flatpak environment exits, without the lutris binary within even running.

How to Reproduce

Steps to reproduce the behavior:

  1. Run flatpak run --command=sh --devel net.lutris.Lutris (install required dependencies)
  2. Wait several dozen seconds.
  3. Notice console exits and improperly returns control to the top level console (I can't write anything), without any output

Or:

  1. flatpak run net.lutris.Lutris and wait several dozen seconds

Log output

Nothing relevant, without any interaction it exits without further logs after the initial three:

2023-05-30 21:50:22,086: Starting Lutris 0.5.13
2023-05-30 21:50:22,093: Running Intel Mesa driver 23.0.2 on Mesa Intel(R) UHD Graphics 620 (KBL GT2) (0x5917)
2023-05-30 21:50:22,094: GPU: 8086:5917 1991:5593 (i915 drivers)

System Information

[System]
OS:              GNOME 44 Flatpak runtime
Arch:            x86_64
Kernel:          5.19.0-42-generic
Desktop:         KDE
Display Server:  wayland
Seneral commented 1 year ago

In my attempts to debug this, I have tried to build the flatpak from scratch. However I encountered two issues:

  1. I needed to use the flatpak version of flatpak-builder, there seems to be a bug in the ubuntu 22.04 version of it, failing to download glu. A notice in the Readme would be great. Command becomes flatpak run org.flatpak.Builder --repo=lutris --force-clean --install-deps-from=flathub build-dir net.lutris.Lutris.yml
  2. It failed to build the first module it attempted, qt5-qtbase, with the following log:
    
    Starting build of net.lutris.Lutris
    ========================================================================
    Building module qt5-qtbase in /mnt/data/DEVELOPMENT/BUILD/net.lutris.Lutris/.flatpak-builder/build/qt5-qtbase-1
    ========================================================================
    Updated Git hooks.
    Git LFS initialized.
    Updating files: 100% (23228/23228), done.
    Note: switching to 'e894b8945c607b4c188a178ae0554139f877a061'.

You are in 'detached HEAD' state. You can look around, make experimental changes and commit them, and you can discard any commits you make in this state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may do so (now or later) by using -c with the switch command. Example:

git switch -c

Or undo this operation with:

git switch -

Turn off this advice by setting config variable advice.detachedHead to false

HEAD is now at e894b894 Update bundled zlib to version 1.2.12 Checking out LFS objects: 100% (170/170), 0 B | 0 B/s, done.
Applying patch qtbase-avoid-hardcoding-kernel-version.patch patching file src/corelib/configure.json Hunk #1 succeeded at 636 (offset 135 lines). Hunk #2 succeeded at 778 (offset 149 lines). Hunk #3 succeeded at 788 (offset 149 lines). Applying patch qtbase-use-wayland-on-gnome.patch patching file src/gui/kernel/qguiapplication.cpp Hunk #1 succeeded at 1409 (offset 33 lines). Applying patch qtbase-revert-qstandardpaths-dont-change-permissions-on-xdg-runtime-dir.patch patching file src/corelib/io/qstandardpaths_unix.cpp patching file tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp Applying patch qtbase-filechooser-portal-send-window-id-in-hex.patch patching file src/plugins/platformthemes/xdgdesktopportal/qxdgdesktopportalfiledialog.cpp

= /run/build/qt5-qtbase = /run/build/qt5-qtbase = /run/build/qt5-qtbase QtCore: created fwd-include header(s) for /src/corelib/animation/ { qabstractanimation.h (1), qabstractanimation_p.h (1), qanimationgroup.h (1), qanimationgroup_p.h (1), qparallelanimationgroup.h (1), qparallelanimationgroup_p.h (1), qpauseanimation.h (1), qpropertyanimation.h (1), qpropertyanimation_p.h (1), qsequentialanimationgroup.h (1), qsequentialanimationgroup_p.h (1), qvariantanimation.h (1), qvariantanimation_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/codecs/ { cp949codetbl_p.h (1), qbig5codec_p.h (1), qeucjpcodec_p.h (1), qeuckrcodec_p.h (1), qgb18030codec_p.h (1), qiconvcodec_p.h (1), qicucodec_p.h (1), qisciicodec_p.h (1), qjiscodec_p.h (1), qjpunicode_p.h (1), qlatincodec_p.h (1), qsimplecodec_p.h (1), qsjiscodec_p.h (1), qtextcodec.h (1), qtextcodec_p.h (1), qtsciicodec_p.h (1), qutfcodec_p.h (1), qwindowscodec_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/global/ { minimum-linux_p.h (1), qcompilerdetection.h (1), qconfig-bootstrapped.h (1), qendian.h (2), qendian_p.h (1), qflags.h (1), qfloat16.h (1), qglobal.h (2), qglobal_p.h (1), qglobalstatic.h (1), qhooks_p.h (1), qisenum.h (1), qlibraryinfo.h (1), qlogging.h (1), qlogging_p.h (1), qmemory_p.h (1), qnamespace.h (2), qnumeric.h (2), qnumeric_p.h (1), qoperatingsystemversion.h (1), qoperatingsystemversion_p.h (1), qoperatingsystemversion_win_p.h (1), qprocessordetection.h (1), qrandom.h (1), qrandom_p.h (1), qsysinfo.h (1), qsystemdetection.h (1), qt_pch.h (1), qt_windows.h (1), qtrace_p.h (1), qtypeinfo.h (1), qtypetraits.h (1), qversiontagging.h (1) } QtCore: created fwd-include header(s) for /src/corelib/io/ { qabstractfileengine_p.h (1), qbuffer.h (1), qdataurl_p.h (1), qdebug.h (2), qdebug_p.h (1), qdir.h (1), qdir_p.h (1), qdiriterator.h (1), qfile.h (1), qfile_p.h (1), qfiledevice.h (1), qfiledevice_p.h (1), qfileinfo.h (1), qfileinfo_p.h (1), qfileselector.h (1), qfileselector_p.h (1), qfilesystemengine_p.h (1), qfilesystementry_p.h (1), qfilesystemiterator_p.h (1), qfilesystemmetadata_p.h (1), qfilesystemwatcher.h (1), qfilesystemwatcher_fsevents_p.h (1), qfilesystemwatcher_inotify_p.h (1), qfilesystemwatcher_kqueue_p.h (1), qfilesystemwatcher_p.h (1), qfilesystemwatcher_polling_p.h (1), qfilesystemwatcher_win_p.h (1), qfsfileengine_iterator_p.h (1), qfsfileengine_p.h (1), qiodevice.h (1), qiodevice_p.h (1), qipaddress_p.h (1), qlockfile.h (1), qlockfile_p.h (1), qloggingcategory.h (1), qloggingregistry_p.h (1), qnoncontiguousbytedevice_p.h (1), qprocess.h (1), qprocess_p.h (1), qresource.h (1), qresource_iterator_p.h (1), qresource_p.h (1), qsavefile.h (1), qsavefile_p.h (1), qsettings.h (1), qsettings_p.h (1), qstandardpaths.h (1), qstorageinfo.h (1), qstorageinfo_p.h (1), qtemporarydir.h (1), qtemporaryfile.h (1), qtemporaryfile_p.h (1), qtldurl_p.h (1), qurl.h (1), qurl_p.h (1), qurlquery.h (1), qurltlds_p.h (1), qwindowspipereader_p.h (1), qwindowspipewriter_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/itemmodels/ { qabstractitemmodel.h (1), qabstractitemmodel_p.h (1), qabstractproxymodel.h (1), qabstractproxymodel_p.h (1), qconcatenatetablesproxymodel.h (1), qidentityproxymodel.h (1), qitemselectionmodel.h (1), qitemselectionmodel_p.h (1), qsortfilterproxymodel.h (1), qstringlistmodel.h (1), qtransposeproxymodel.h (1), qtransposeproxymodel_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/kernel/ { qabstracteventdispatcher.h (1), qabstracteventdispatcher_p.h (1), qabstractnativeeventfilter.h (1), qbasictimer.h (1), qcfsocketnotifier_p.h (1), qcore_mac_p.h (1), qcore_unix_p.h (1), qcoreapplication.h (1), qcoreapplication_p.h (1), qcorecmdlineargs_p.h (1), qcoreevent.h (1), qcoreglobaldata_p.h (1), qdeadlinetimer.h (1), qdeadlinetimer_p.h (1), qelapsedtimer.h (1), qeventdispatcher_cf_p.h (1), qeventdispatcher_glib_p.h (1), qeventdispatcher_unix_p.h (1), qeventdispatcher_win_p.h (1), qeventdispatcher_winrt_p.h (1), qeventloop.h (1), qeventloop_p.h (1), qfunctions_fake_env_p.h (1), qfunctions_nacl.h (1), qfunctions_p.h (1), qfunctions_vxworks.h (1), qfunctions_winrt.h (1), qjni_p.h (1), qjnihelpers_p.h (1), qmath.h (1), qmetaobject.h (1), qmetaobject_moc_p.h (1), qmetaobject_p.h (1), qmetaobjectbuilder_p.h (1), qmetatype.h (1), qmetatype_p.h (1), qmetatypeswitcher_p.h (1), qmimedata.h (1), qobject.h (1), qobject_impl.h (1), qobject_p.h (1), qobjectcleanuphandler.h (1), qobjectdefs.h (1), qobjectdefs_impl.h (1), qpointer.h (1), qpoll_p.h (1), qppsattribute_p.h (1), qppsattributeprivate_p.h (1), qppsobject_p.h (1), qppsobjectprivate_p.h (1), qsharedmemory.h (1), qsharedmemory_p.h (1), qsignalmapper.h (1), qsocketnotifier.h (1), qsystemerror_p.h (1), qsystemsemaphore.h (1), qsystemsemaphore_p.h (1), qtestsupport_core.h (1), qtimer.h (1), qtimerinfo_unix_p.h (1), qtranslator.h (1), qtranslator_p.h (1), qvariant.h (4), qvariant_p.h (1), qwineventnotifier.h (1), qwineventnotifier_p.h (1), qwinregistry_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/mimetypes/ { qmimedatabase.h (1), qmimedatabase_p.h (1), qmimeglobpattern_p.h (1), qmimemagicrule_p.h (1), qmimemagicrulematcher_p.h (1), qmimeprovider_p.h (1), qmimetype.h (1), qmimetype_p.h (1), qmimetypeparser_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/plugin/ { qelfparser_p.h (1), qfactoryinterface.h (1), qfactoryloader_p.h (1), qlibrary.h (1), qlibrary_p.h (1), qmachparser_p.h (1), qplugin.h (2), qplugin_p.h (1), qpluginloader.h (1), qsystemlibrary_p.h (1), quuid.h (1) } QtCore: created fwd-include header(s) for /src/corelib/serialization/ { qbinaryjson_p.h (1), qbinaryjsonarray_p.h (1), qbinaryjsonobject_p.h (1), qbinaryjsonvalue_p.h (1), qcborarray.h (1), qcborcommon.h (1), qcborcommon_p.h (1), qcbormap.h (1), qcborstream.h (1), qcborstreamreader.h (1), qcborstreamwriter.h (1), qcborvalue.h (1), qcborvalue_p.h (1), qdatastream.h (1), qdatastream_p.h (1), qjson_p.h (1), qjsonarray.h (1), qjsondocument.h (1), qjsonobject.h (1), qjsonparser_p.h (1), qjsonvalue.h (1), qjsonwriter_p.h (1), qtextstream.h (1), qtextstream_p.h (1), qxmlstream.h (1), qxmlstream_p.h (1), qxmlutils_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/statemachine/ { qabstractstate.h (1), qabstractstate_p.h (1), qabstracttransition.h (1), qabstracttransition_p.h (1), qeventtransition.h (1), qeventtransition_p.h (1), qfinalstate.h (1), qfinalstate_p.h (1), qhistorystate.h (1), qhistorystate_p.h (1), qsignaleventgenerator_p.h (1), qsignaltransition.h (1), qsignaltransition_p.h (1), qstate.h (1), qstate_p.h (1), qstatemachine.h (1), qstatemachine_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/text/ { qbytearray.h (1), qbytearray_p.h (1), qbytearraylist.h (1), qbytearraymatcher.h (1), qbytedata_p.h (1), qchar.h (1), qcollator.h (1), qcollator_p.h (1), qdoublescanprint_p.h (1), qharfbuzz_p.h (1), qlocale.h (1), qlocale_data_p.h (1), qlocale_p.h (1), qlocale_tools_p.h (1), qregexp.h (1), qregularexpression.h (1), qstring.h (1), qstringalgorithms.h (1), qstringalgorithms_p.h (1), qstringbuilder.h (1), qstringiterator_p.h (1), qstringlist.h (1), qstringliteral.h (1), qstringmatcher.h (1), qstringview.h (1), qtextboundaryfinder.h (1), qunicodetables_p.h (1), qunicodetools_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/thread/ { qatomic.h (1), qatomic_bootstrap.h (1), qatomic_cxx11.h (1), qatomic_msvc.h (1), qbasicatomic.h (1), qexception.h (1), qfutex_p.h (1), qfuture.h (1), qfutureinterface.h (1), qfutureinterface_p.h (1), qfuturesynchronizer.h (1), qfuturewatcher.h (1), qfuturewatcher_p.h (1), qgenericatomic.h (1), qlocking_p.h (1), qmutex.h (1), qmutex_p.h (1), qorderedmutexlocker_p.h (1), qreadwritelock.h (1), qreadwritelock_p.h (1), qresultstore.h (1), qrunnable.h (1), qsemaphore.h (1), qthread.h (1), qthread_p.h (1), qthreadpool.h (1), qthreadpool_p.h (1), qthreadstorage.h (1), qwaitcondition.h (1), qwaitcondition_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/time/ { qcalendar.h (1), qcalendarbackend_p.h (1), qcalendarmath_p.h (1), qdatetime.h (1), qdatetime_p.h (1), qdatetimeparser_p.h (1), qgregoriancalendar_p.h (1), qhijricalendar_data_p.h (1), qhijricalendar_p.h (1), qislamiccivilcalendar_p.h (1), qjalalicalendar_data_p.h (1), qjalalicalendar_p.h (1), qjuliancalendar_p.h (1), qmilankoviccalendar_p.h (1), qromancalendar_data_p.h (1), qromancalendar_p.h (1), qtimezone.h (1), qtimezoneprivate_data_p.h (1), qtimezoneprivate_p.h (1) } QtCore: created fwd-include header(s) for /src/corelib/tools/ { qalgorithms.h (2), qarraydata.h (1), qarraydataops.h (1), qarraydatapointer.h (1), qbitarray.h (1), qcache.h (1), qcommandlineoption.h (1), qcommandlineparser.h (1), qcontainerfwd.h (2), qcontainertools_impl.h (1), qcontiguouscache.h (1), qcryptographichash.h (1), qduplicatetracker_p.h (1), qeasingcurve.h (1), qfreelist_p.h (1), qhash.h (1), qhashfunctions.h (1), qiterator.h (1), qline.h (1), qlinkedlist.h (1), qlist.h (1), qmakearray_p.h (1), qmap.h (1), qmargins.h (1), qmessageauthenticationcode.h (1), qoffsetstringarray_p.h (1), qpair.h (1), qpoint.h (1), qqueue.h (1), qrect.h (1), qrefcount.h (1), qringbuffer_p.h (1), qscopedpointer.h (1), qscopedpointer_p.h (1), qscopedvaluerollback.h (1), qscopeguard.h (1), qset.h (1), qshareddata.h (1), qsharedpointer.h (1), qsharedpointer_impl.h (1), qsimd_p.h (1), qsimd_x86_p.h (1), qsize.h (1), qstack.h (1), qtimeline.h (1), qtools_p.h (1), qvarlengtharray.h (1), qvector.h (1), qversionnumber.h (1) } QtCore: created fwd-include header(s) for /src/corelib/platform/wasm/ { qstdweb_p.h (1) } Creating qmake... .............Error: module qt5-qtbase: Child process exited with code 137 ```
strycore commented 1 year ago

If you want to test a build, you shoud be able to remove the Qt5 dependency (but runners such as Dolphin and MAME will not work).

I've never seen the build process fail on Qt5 so there is maybe something wrong with your local flatpak-builder

Seneral commented 1 year ago

Well I'm using the flatpak version of flatpak-builder, which according to the first bug I faced, is a sort of "reference", the most up to date one. I've never dabbled in anything flatpak beyond flatseal before, could you tell me how to remove the QT5 dependency? (nvm just removing - modules/qt5-15.yaml might be working, usually removing a dependency isn't that easy)

strycore commented 1 year ago

In net.lutris.Lutris.yml remove the line pointing to the qt5 libraries:

- modules/qt5-15.yaml

Seneral commented 1 year ago

This really isn't easy. Now I get Error: module gtk2: Child process exited with code 137, tried multiple times again. Not OOM, closed all apps and only used ~2.5GB/(8+16GB) of memory+swap Not timeout/background killed, made sure org.flatpak.Builder is allowed to run in the background, AND constantly interacted with it so that no background warning popped up, still died like this.

Not sure what kills it tbh, but something does. Tested if org.flatpak.Builder suffers from the same exit-after-dozens-of-seconds bug I want to debug in the first place, and so far, no indication of that either.

strycore commented 1 year ago

There's some weird stuff going on for sure.... Do you have another system to test this on? Even a VM would do.

Seneral commented 1 year ago

Will have to do it on the weekend on another PC, where I want to set up Lutris for retro gaming anyway. Just to make sure my understanding is correct, installing lutris and gamescope flatpaks together should in theory work and it should detect gamescope, correct? Will try different distros if it happens to not work on a fresh install of my current distro (KDE Neon).

strycore commented 1 year ago

I'm not sure Gamescope will work... The only case where I run the Lutris Flatpak is on the Steam Deck and this already runs Gamescope as its base compositor.

I have yet to find the documentation that explains Flatpak extensions...

Seneral commented 1 year ago

Oh great, getting the flatpak to work is my only hope for gamescope. Trying to compile it on ubuntu 22.04 is almost impossible, tried a while back, apart from plenty of dependency problems I had to compile meson myself, and even after all that there are more problems. Never had this much trouble trying to compile anything, and I'm a programmer.

strycore commented 1 year ago

There's a PPA available: https://launchpad.net/~ar-lex/+archive/ubuntu/gamescope

I also attempted to build it on Pop 22.04 and abandoned...

Seneral commented 1 year ago

Ok so flatpak gamescope+lutris works technically on a fresh Manjaro+KDE install, same hardware. Not sure what caused it to not work on my system. Flatpak lutris does recognise flatpak gamescope, which is nice. Unfortunately I always get a black screen (at best a flickering screen with a squashed, single frame of the game, when using a lutris GE proton backend instead of a normal wine one). But I do know the game is running, sound and interaction work fine. Saving grace is that the games do go properly fullscreen even without gamescope for some reason, so I don't necessarily need gamescope, where on my current system I need it because the games occupy a tiny, unscaled corner of the screen only. Weird stuff....

Will try the gamescope PPA on this system, thanks for the help

Seneral commented 1 year ago

Tried PPA, and it seems I did before, but I cannot install it (I remember trying with aptitude to fix problems, no luck).

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Starting pkgProblemResolver with broken count: 1
Starting 2 pkgProblemResolver with broken count: 1
Investigating (0) libwlroots11:amd64 < none -> 0.16.1-2~jammy @un puN Ib >
Broken libwlroots11:amd64 Depends on libseat1:amd64 < none | 0.6.4-1 @un uH > (>= 0.5.0)
  Considering libseat1:amd64 0 as a solution to libwlroots11:amd64 0
  Re-Instated libseat1:amd64
Broken libwlroots11:amd64 Depends on libwayland-server0:amd64 < 1.20.0-1ubuntu0.1 @ii pK > (>= 1.20.92)
  Considering libwayland-server0:amd64 44 as a solution to libwlroots11:amd64 0
  Considering libwayland-server0:amd64 44 as a solution to libwlroots11:amd64 0
  Considering libwayland-server0:amd64 44 as a solution to libwlroots11:amd64 0
  Considering libwayland-server0:amd64 44 as a solution to libwlroots11:amd64 0
  Considering libwayland-server0:amd64 44 as a solution to libwlroots11:amd64 0
Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies.
 libwlroots11 : Depends: libwayland-server0 (>= 1.20.92) but 1.20.0-1ubuntu0.1 is to be installed
E: Unable to correct problems, you have held broken packages.