https://bugs.kde.org/show_bug.cgi?id=482077

--- Comment #55 from Dāvis <davis...@gmail.com> ---
(In reply to Vlad Zahorodnii from comment #46)
> > It looks like some application is using 
> > ext_idle_notifier_v1::get_idle_notification() with 4294967295ms as timeout 
> > value, it's uint so this is kinda valid...
> 
> can you apply the patch that I've attached to the bug report. it's going to
> be print the executable path and the pid of the offender

I built KWin with that patch but didn't notice any extra log entries, then
realized I didn't build debug build oops
Now with debug build I see same 

> "" 3469 wants an idle notification with too big timeout 4294967295
where 3469 is `org_kde_powerdevil`

But I disagree that this is Powerdevil's bug. KWin should either respect this
and notify after ~50days or ignore it and potentially let application know this
in some way.

Powerdevil doing some stupid shit is just another bug - of course should be
fixed but that doesn't mean KWin shouldn't be fixed aswell because ANY
application can send garbage to it.


(In reply to Vlad Zahorodnii from comment #49)
> 
> Hmm, can you attach gdb to powerdevil and add a breakpoint in
> KIdleTime::addIdleTimeout please?

Here

> #0  KIdleTime::addIdleTimeout (this=0x5e5e8b5506f0, msec=msec@entry=-1) at 
> /usr/src/debug/kidletime/kidletime-6.0.0/src/kidletime.cpp:119
> #1  0x00007092748f3cf4 in KIdleTime::addIdleTimeout 
> (msec=std::chrono::duration = { -1ms }, this=<optimized out>) at 
> /usr/include/c++/13.2.1/bits/chrono.h:587
> #2  PowerDevil::Core::registerActionTimeout (this=0x709258002470, 
> action=<optimized out>, timeout=std::chrono::duration = { <optimized out>ms 
> }) at /usr/src/debug/powerdevil/powerdevil-6.0.1/daemon/powerdevilcore.cpp:848
> #3  0x0000709273790ca9 in QtPrivate::QSlotObjectBase::call (a=0x7ffc048b8890, 
> r=0x5e5e8b4ce400, this=0x5e5e8b4f9b10, this=<optimized out>, r=<optimized 
> out>, a=<optimized out>) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qobjectdefs_impl.h:433
> #4  doActivate<false> (sender=0x5e5e8b4b8a20, signal_index=6, 
> argv=0x7ffc048b8890) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qobject.cpp:4039
> #5  0x000070927490dbe7 in PowerDevil::PolicyAgent::screenLockerActiveChanged 
> (this=<optimized out>, _t1=<optimized out>) at 
> /usr/src/debug/powerdevil/build/daemon/powerdevilcore_autogen/include/moc_powerdevilpolicyagent.cpp:425
> #6  0x0000709274905115 in 
> PowerDevil::PolicyAgent::onScreenLockerActiveChanged (this=0x5e5e8b4b8a20, 
> active=true) at 
> /usr/src/debug/powerdevil/powerdevil-6.0.1/daemon/powerdevilpolicyagent.cpp:577
> #7  0x0000709273790ca9 in QtPrivate::QSlotObjectBase::call (a=0x7ffc048b8ac0, 
> r=0x5e5e8b4b8a20, this=0x5e5e8b5d9ce0, this=<optimized out>, r=<optimized 
> out>, a=<optimized out>) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qobjectdefs_impl.h:433
> #8  doActivate<false> (sender=0x5e5e8b5da460, signal_index=3, 
> argv=0x7ffc048b8ac0) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qobject.cpp:4039
> #9  0x0000709274922bdb in OrgFreedesktopScreenSaverInterface::ActiveChanged 
> (_t1=<optimized out>, this=<optimized out>) at 
> /usr/src/debug/powerdevil/build/daemon/moc_screenlocker_interface.cpp:304
> #10 OrgFreedesktopScreenSaverInterface::qt_static_metacall 
> (_o=_o@entry=0x5e5e8b5da460, _id=_id@entry=0, _a=_a@entry=0x7ffc048b8c88, 
> _c=<optimized out>) at 
> /usr/src/debug/powerdevil/build/daemon/moc_screenlocker_interface.cpp:235
> #11 0x00007092749278b1 in 
> OrgFreedesktopScreenSaverInterface::qt_static_metacall (_a=0x7ffc048b8c88, 
> _id=0, _c=QMetaObject::InvokeMetaMethod, _o=0x5e5e8b5da460) at 
> /usr/src/debug/powerdevil/build/daemon/moc_screenlocker_interface.cpp:229
> #12 OrgFreedesktopScreenSaverInterface::qt_metacall (this=0x5e5e8b5da460, 
> _c=QMetaObject::InvokeMetaMethod, _id=0, _a=0x7ffc048b8c88) at 
> /usr/src/debug/powerdevil/build/daemon/moc_screenlocker_interface.cpp:290
> #13 0x00007092745f70ce in QDBusConnectionPrivate::deliverCall 
> (this=0x7092640016a0, object=0x5e5e8b5da460, msg=..., metaTypes=<optimized 
> out>, slotIdx=6) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/dbus/qdbusintegrator.cpp:977
> #14 0x000070927377c2c7 in QObject::event (this=0x5e5e8b5da460, 
> e=0x709264031bc0) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qobject.cpp:1437
> #15 0x0000709273739818 in QCoreApplication::notifyInternal2 
> (receiver=0x5e5e8b5da460, event=event@entry=0x709264031bc0) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qcoreapplication.cpp:1121
> #16 0x0000709273739b9b in QCoreApplication::sendEvent (event=0x709264031bc0, 
> receiver=<optimized out>) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qcoreapplication.cpp:1539
> #17 QCoreApplicationPrivate::sendPostedEvents (receiver=0x0, event_type=0, 
> data=0x5e5e8b2ac900) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qcoreapplication.cpp:1901
> #18 0x00007092739758a4 in QCoreApplication::sendPostedEvents (receiver=0x0, 
> event_type=0) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qcoreapplication.cpp:1760
> #19 postEventSourceDispatch (s=0x5e5e8b2aeae0) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qeventdispatcher_glib.cpp:243
> #20 0x0000709271f0df69 in g_main_dispatch (context=0x709264000ef0) at 
> ../glib/glib/gmain.c:3476
> #21 0x0000709271f6c3a7 in g_main_context_dispatch_unlocked 
> (context=0x709264000ef0) at ../glib/glib/gmain.c:4284
> #22 g_main_context_iterate_unlocked.isra.0 
> (context=context@entry=0x709264000ef0, block=block@entry=1, 
> dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/glib/gmain.c:4349
> #23 0x0000709271f0c162 in g_main_context_iteration (context=0x709264000ef0, 
> may_block=1) at ../glib/glib/gmain.c:4414
> #24 0x00007092739739c4 in QEventDispatcherGlib::processEvents 
> (this=0x5e5e8b2ae9f0, flags=...) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qeventdispatcher_glib.cpp:393
> #25 0x0000709273743d6e in QEventLoop::processEvents (flags=..., 
> this=0x7ffc048b92a0) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qeventloop.cpp:100
> #26 QEventLoop::exec (this=0x7ffc048b92a0, flags=...) at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/kernel/qeventloop.cpp:182
> #27 0x000070927373c2b8 in QCoreApplication::exec () at 
> /usr/src/debug/qt6-base/qtbase-everywhere-src-6.6.2/src/corelib/global/qflags.h:74
> #28 0x00005e5e8afb673f in main (argc=<optimized out>, argv=<optimized out>) 
> at /usr/src/debug/powerdevil/powerdevil-6.0.1/daemon/powerdevilapp.cpp:165


Another interesting thing I found that if you restart KWin then it doesn't
happen anymore, maybe because Powerdevil stops working?
This is what Powerdevil says after KWin restart

> The Wayland connection broke. Did the Wayland compositor die?
> qt.qpa.wayland: Attempting wayland reconnect
> Failed to write to the pipe: Bad file descriptor.
> qt.qpa.wayland: Creating a fake screen in order for Qt not to crash


But now if I restart Powerdevil (/usr/lib/org_kde_powerdevil --replace) then it
starts happening again.


Also btw I see these messages in Powerdevil aswell

> org.kde.powerdevil: org.kde.powerdevil.chargethresholdhelper.getthreshold 
> failed "Charge thresholds are not supported by the kernel for this hardware"
> org.kde.powerdevil: org.kde.powerdevil.backlighthelper.brightness failed
> org.kde.powerdevil: Handle button events action could not check for screen 
> configuration

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to