Spectacle circlular dependency

Hey everyone :slight_smile:
short info regarding my system:
endeavouros with x11, kernel 6.8.4-arch1-1, kde 6.0.3 and spectacle 24.02.1.

When launching spectacle -bcnr from the terminal:

  1. I get the following error message, can still select a region, but the image is not being saved in the clipboard: qt.qml.typeresolution.cycle: Cyclic dependency detected between "qrc:/qt/qml/org/kde/desktop/private/TextFieldContextMenu.qml" and "qrc:/qt/qml/org/kde/desktop/MenuItem.qml"

or

  1. it takes a couple of seconds for spectacle to load, just to crash without any message

or

  1. it just works

I explicitly have put Meta+Shift+S to a script shortcut of spectacle -bcnr, as this is my default screenshotting behaviour. Select a region and having the image in my clipboard, but nowhere else. The custom shortcut has the same issue as running it from the terminal, as expected.

It’s a bit confusing as to why it doesnt work and then it just does. There is nothing I can pin-point it to, as it will literally work one second and the other it won’t, just to work again.

This issue persists since my upgrade to KDE6.

Any ideas on how I could try and tackle this? I only found the issue [442876 – Spectacle is quite slow in taking screenshots]* about long loading times for rectangle region screenshotting. Maybe I have just not found the correct bug.

Cheers,
zookee1

* (I am not allowed to post links)

i’ve also has some issues with spectacle saves and websites not accepting the .png for uploading.

i can open the files on my desktop and they look fine in the viewer, but reddit, imgur and even this site would refuse to upload them until i converted them to .jpg or recreated them.

i did just go thru a new kernel update to 6.5.0-27-generic and it seems fine now after i reset my default save directory… but it was perplexing

This is kind of a known issue with the current QML setup in Plasma 6 and it hits many apps but isn’t a crashing problem and shouldn’t prevent the app from functioning. I’m pretty sure you’d see it even in case (3) where it just works.

1 Like

That is correct, I just checked. I get the same error in the terminal, but it still takes a screenshot.

Still wondering why it sometimes just would not (also with the error) and sometimes, but rarely, simply crashes.

With that in mind, I don’t think that specific error is causing spectacle to malfunction, but I can’t wrap my head around why it malfunctions so unpredictably. :thinking:

Since I can’t find anything on the bug tracker and I’ve had this behaviour for a while now, it seems like it’s only a me-problem. Still don’t know where to look for clues on how to fix it tho. :frowning:

When running the command line that you specified, I see that Spectactle is doing some device enumeration that appears to fail:

image

And only then it actually pops the capture UI.

When it fails for you - do you see the VA-API enumeration, and if so - do you get any output after that?

1 Like

The only output I get is the one from the OP:

In this case it worked for the 3rd, 4th and 6ths try. The others just didn’t end up in my clipboard. :frowning:

I didn’t find an obvious way to make spectacle any more verbose as well. :thinking:

Try to run it like this:

QT_LOGGING_RULES="*.debug=true" spectacle -bcnr

If that does not generate enough logs (on my system it produces a few hundred log lines) you can try to replace debug with trace. :wink:

1 Like

This just is a minor QML issue that needs to be fixed in qqc2-desktop-style. It’s not causing any issue you might be seeing in Spectacle itself.

Thanks for the tip :slight_smile:

Are you sure it’s just a couple of hundred lines for you?

I just did both, debug and trace, and for both cases, working and failing and… well, they are HUGE on my end.

The debugs are 14,6MiB and 17,7MiB, the traces are 700KiB and 1.7MiB.

Just wanna check if it’s the same(ish) for you, before I sift through that.

I’ve simply put the the output via &> filename.txt into files.

I didn’t actually count :sweat_smile:

I just did, and the debug log is > 29K and the trace is > 5K (which is weird because I though trace is more logging than debug).