Bug 1278079 - When caja is run, it requires 6quits to end the program
When caja is run, it requires 6quits to end the program
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: xfwm4 (Show other bugs)
23
x86_64 Linux
unspecified Severity high
: ---
: ---
Assigned To: Kevin Fenzi
Fedora Extras Quality Assurance
:
: 1250404 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-11-04 11:35 EST by John Duchek
Modified: 2016-01-07 23:27 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-01-05 16:56:58 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description John Duchek 2015-11-04 11:35:17 EST
Description of problem:

If I run caja, it display a directory. I click on the upper right x to close it, and it reopens. If I reclick the x, it closes and reopens.  This occurs for a total of 6 times until the program closes for good.
Version-Release number of selected component (if applicable):
1.10.4

How reproducible:
Every time it runs

Steps to Reproduce:
1. Click on caja
2.click x to close
3.repeat

Actual results:
reopens 6 times

Expected results:
Close the first time I tell it to.


Additional info:
I am running F23 xfce window manager
Comment 1 Wolfgang Ulbrich 2015-11-04 17:46:04 EST
I can't reproduce this issue in mate session with running marco as WM.
Looks like a issue with xfce.
Let see what xfce maintainer thinks about.
Comment 2 John Duchek 2015-11-07 13:26:18 EST
To add to the above, when I finally get Caja to quit, it wipes out of the background pictures displayed on my dual monitor system and gives a blue-green gradient background.
Comment 3 Wolfgang Ulbrich 2015-11-07 14:13:20 EST
I don't know nothing about xfce-session.
Sounds like xfce-session-management tries to restart caja.
Check if caja is in xfce saved-session.
Comment 4 Kevin Fenzi 2015-11-08 11:29:35 EST
I can confirm the behavior, but not sure why it's doing it. ;( 

I do see:

(caja:30907): Eel-WARNING **: "unique eel_ref_str" hash table still has 4 elements at quit time (keys above)
(caja:30907): Eel-WARNING **: "caja-directory.c: directories" hash table still has 2 elements at quit time

Perhaps that means something to the mate folks?
Comment 5 Wolfgang Ulbrich 2015-11-08 14:12:54 EST
(In reply to Kevin Fenzi from comment #4)
> I can confirm the behavior, but not sure why it's doing it. ;( 
> 
> I do see:
> 
> (caja:30907): Eel-WARNING **: "unique eel_ref_str" hash table still has 4
> elements at quit time (keys above)
> (caja:30907): Eel-WARNING **: "caja-directory.c: directories" hash table
> still has 2 elements at quit time
> 
> Perhaps that means something to the mate folks?

What you see here is the result of an improvement by this commit.
https://github.com/mate-desktop/caja/commit/4b0d231fdf8dfd6d299ec07cc933000a610f0a74
This avoid that that caja hijack the desktop in another enviroment or if you start caja as root.
Normaly caja handles the desktop in mate-session, ie. icons and contextmenus.
This warnings i see in mate-session too if i start caja as root.
So, it's a bit unusual to print such warnings (debuginfos) in a terminal but it's nothing bad and never cause this issue in xfce seesion, imo.
And those are only warnings.
Comment 6 Kevin Fenzi 2015-11-08 14:43:43 EST
The logic there seems a bit wrong to me. 

It says:

if you are running as root and not on mate, exit when the window closes. 
If you are not running as root and not on mate, get the value from gsettings. 

This fails for any user that hasn't set the gsetting value. (Like most Xfce users)

Indeed, if I run caja as root under Xfce it correctly exits on the first close. 

So, I think line 525 there should be shortened to: 

if (running_in_mate ())

Or perhaps it should check if that pref is set no matter what desktop and if it's not set default it to true.
Comment 7 Wolfgang Ulbrich 2015-11-08 15:40:47 EST
Ok, i will forward the issue to github, sorry i'm not a coder.
To fasten the process a pull request is welcome.
Comment 8 Wolfgang Ulbrich 2015-11-09 04:23:14 EST
https://github.com/mate-desktop/caja/issues/481
Please add youself to the report to answer question from upstream or doing testing requests. I don't think that upstream will install xfce for testing ;)
Your cooperation is necessary.
Comment 9 Wolfgang Ulbrich 2015-12-10 19:05:30 EST
Dear reporter,
i'm not really sure that you're in interested of this issue because you never answer here or at upstream report.
Please read https://github.com/mate-desktop/caja/issues/481#issuecomment-163243308
and comments below.
If caja starts, xfce4-session-settings shows caja with 'immediately' in restart column.
If you set this to 'never' caja closes fine until you start caja again.

Caja is a MATE core application and we can't remove
X-MATE-AutoRestart=true
from /usr/share/applications/caja.desktop, otherwise caja don't restart in mate-session.
Set this value to 'false' and everything is fine.

I'm not sure that Kevin agree with me, but for some reasons xfce session management reads 'X-MATE' values in desktop files, and restart caja.

It is really strange that xfce4-session-settings list caja with 'if running' in restart column, if you change this line to 'X-GNOME-AutoRestart=true'.
Than caja close fine too.
And sorry, using 'X-GNOME' breaks caja in mate-session.

So, the question is why xfce4-session-settings reads this values?
Maybe xfce maintainer knows about.
Comment 10 Wolfgang Ulbrich 2015-12-18 07:01:56 EST
*** Bug 1250404 has been marked as a duplicate of this bug. ***
Comment 11 Wolfgang Ulbrich 2015-12-22 11:10:06 EST
Upstream fix it :)
Please try this scratch build http://koji.fedoraproject.org/koji/taskinfo?taskID=12286978
Comment 12 Raphael Groner 2015-12-22 12:01:22 EST
(In reply to Wolfgang Ulbrich from comment #11)
> Upstream fix it :)
> Please try this scratch build
> http://koji.fedoraproject.org/koji/taskinfo?taskID=12286978

Works for me, in both MATE and Xfce4 sessions. But I see the following log in xfce4-terminal only:

$ caja

(caja:1795): GLib-GObject-WARNING **: gsignal.c:2634: instance '0x55f02b50edf0' has no handler with id '1227'

(caja:1795): GLib-GObject-WARNING **: gsignal.c:2634: instance '0x55f02b598f80' has no handler with id '2615'

(caja:1795): GLib-GObject-WARNING **: gsignal.c:2634: instance '0x55f02b521aa0' has no handler with id '119'

(caja:1795): GLib-CRITICAL **: Source ID 123 was not found when attempting to remove it

(caja:1795): GLib-CRITICAL **: Source ID 124 was not found when attempting to remove it

(caja:1795): GLib-CRITICAL **: Source ID 125 was not found when attempting to remove it

--- Hash table keys for warning below:
--> test
--> inode/directory
--> l64768

(caja:1795): Eel-WARNING **: "unique eel_ref_str" hash table still has 3 elements at quit time (keys above)

(caja:1795): Eel-WARNING **: "caja-directory.c: directories" hash table still has 1 element at quit time
Comment 13 Kevin Fenzi 2015-12-22 14:48:46 EST
Yep. Works fine here. Thanks.
Comment 14 Fedora Update System 2015-12-22 15:59:20 EST
caja-1.12.1-2.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2015-f818d79d2d
Comment 15 Fedora Update System 2015-12-24 13:46:34 EST
caja-1.12.2-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2015-0480cf17db
Comment 16 Raphael Groner 2015-12-25 06:47:37 EST
caja-1.12.2-1.fc23 does not show any menu entry in Xfce. 

What's the sense to use Caja in a Xfce session without need to run it from a terminal? I guess the Categories are missing in desktop file cause Caja has its own top level sub menu in MATE panel and is in autostart, right? Also, there's OnlyShowIn=MATE; to prevent it to appear as a menu entry in any other DE. Is that all intentionally?
Comment 17 Wolfgang Ulbrich 2015-12-25 08:14:48 EST
1. this is an xfwm4, because xfce WM manager reads X-Mate entries fom desktop files, see comment 9
2. I do not know why users want to use caja in xfce. But in general caja is a mate component and upstream do not support the usage in other desktops, normaly.
3. I'm the only mate maintainer in fedora and i've a work overload.
I don't work on reports from other desktops.
Feel free to become a co-maintainer of caja and i will add XFCE to OnlyShowIn entry in caja-browser.desktop ;)
Comment 18 Wolfgang Ulbrich 2015-12-25 08:15:30 EST
s/1. this is an xfwm4/ 1. this is an xfwm4 issue/g
Comment 19 Wolfgang Ulbrich 2015-12-25 08:17:22 EST
i meant...
I don't want to work on reports from other desktops, because of my work overload.
Comment 20 John Duchek 2015-12-25 09:19:27 EST
If I knew enough to help, I would.  Fact is caja was installed in fedora 23 xfce spin when I updated from 22.  I had never heard of it.  I found it to be an interesting program that did some things thunar didn't.  When I found a bug, I reported it.  

If you don't want users to report bugs, that is fine.  We all have lots to do.  I have always found I get more done when I don't spend time talking about how much I have to do.  I hope you can find some free time to 'smell the roses' soon.

John
Comment 21 Wolfgang Ulbrich 2015-12-25 10:32:41 EST
I did some typos in comment 17 and you did not understand what i wanted to say.

Again.
1. this is an xfwm4 issue, because xfce WM manager reads X-Mate entries fom desktop files, see comment 9
2. I do not know why users want to use caja in xfce. But in general caja is a mate component and upstream do not support the usage in other desktops, normal.
3. I'm the only mate maintainer in fedora and i've a work overload.
I don't want work on reports from other desktops in general, because the day has only 24h and i do that in my free time.
Feel free to become a co-maintainer of caja and i will add XFCE to OnlyShowIn entry in caja-browser.desktop ;)

Anyways, upstream and me have fix your issue, so please don't say that i don't want that users reports bugs, this isn't true.
But adding XFCE to OnlyShowIn entry will bring me in a situation where i have to work on more bug reports, but i don't have the time for it, in result xfce user are pissed.

I hope that you understand that.

PS: you can edit /usr/share/applications/caja-browser.desktop to
OnlyShowIn=MATE;XFCE;
and you will see caja in menu.
Comment 22 Kevin Fenzi 2015-12-26 12:40:01 EST
(In reply to Wolfgang Ulbrich from comment #21)
> 1. this is an xfwm4 issue, because xfce WM manager reads X-Mate entries fom
> desktop files, see comment 9

Not quite. caja reads it's own .desktop file on start and based on X-Mate-Autostart sets a Xsm X session property to always restart it or not. This is now fixed to not do this in non MATE sessions. 
(ie thats this bug and it's solved as far as I can tell with the caja updates submitted above. 

> 2. I do not know why users want to use caja in xfce. But in general caja is
> a mate component and upstream do not support the usage in other desktops,
> normal.
> 3. I'm the only mate maintainer in fedora and i've a work overload.
> I don't want work on reports from other desktops in general, because the day
> has only 24h and i do that in my free time.
> Feel free to become a co-maintainer of caja and i will add XFCE to
> OnlyShowIn entry in caja-browser.desktop ;)

I'd be happy to look into caja / Xfce interaction issues. Just cc me on such reports... 
I don't know if thats enough to allow you to show it in Xfce or not, thats up to you. ;)
Comment 23 Wolfgang Ulbrich 2015-12-27 12:30:28 EST
(In reply to Kevin Fenzi from comment #22)
> 
> I'd be happy to look into caja / Xfce interaction issues. Just cc me on such
> reports... 
> I don't know if thats enough to allow you to show it in Xfce or not, thats
> up to you. ;)

Yeap, cool.
I've updated caja and edited
https://bodhi.fedoraproject.org/updates/FEDORA-2015-0480cf17db
https://bodhi.fedoraproject.org/updates/FEDORA-2015-59afd09f25
Comment 24 Fedora Update System 2015-12-28 19:57:20 EST
caja-1.12.2-2.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-0480cf17db
Comment 25 Fedora Update System 2015-12-30 15:55:43 EST
caja-1.12.2-2.fc22 has been pushed to the Fedora 22 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-59afd09f25
Comment 26 John Duchek 2016-01-02 09:41:37 EST
I just checked the currently installed version of caja under xfce 1.12.1.  The problem no longer exists on my computers.  Thank you. I am not certain as to whether the problem has been fixed in caja or in xfce.  Anyway I am no longer seeing the problem.  Again, thank you.


John
Comment 27 John Duchek 2016-01-02 18:40:51 EST
Boy was I wrong in comment 26.  I installed Mate as an alternative to XFCE and I am finding that Mate isn't playing nice.  When I boot up the computer into XFCE, several of the Mate programs override the XFCE programs.  In particular the Desktop wallpaper is now Mate's wallpaper rather than my personal Pwallpaper selections.  My wallpaper comes up first and then Mate overwrites it.  Apparently in doing that, caja begins to work properly.  It doesn't until Mate does a hostile screen takeover.  It is too bad that one cannot have these different spins installed and choose the one you want.  They don't cleanly go away when they are not the choice.
John
Comment 28 Wolfgang Ulbrich 2016-01-02 19:02:37 EST
(In reply to John Duchek from comment #27)
> Boy was I wrong in comment 26.  I installed Mate as an alternative to XFCE
> and I am finding that Mate isn't playing nice.  When I boot up the computer
> into XFCE, several of the Mate programs override the XFCE programs.  In
> particular the Desktop wallpaper is now Mate's wallpaper rather than my
> personal Pwallpaper selections.  My wallpaper comes up first and then Mate
> overwrites it.  Apparently in doing that, caja begins to work properly.  It
> doesn't until Mate does a hostile screen takeover.  It is too bad that one
> cannot have these different spins installed and choose the one you want. 
> They don't cleanly go away when they are not the choice.
> John
Please check if caja is in 'saved session' and clean it.

@ nirik
Can you reproduce this?
Comment 29 Wolfgang Ulbrich 2016-01-02 19:35:24 EST
Sorry, i can't reproduce it.
I don't see the wallpaper which i use in MATE session in XFCE session in f23.
Also, if i closed xfce session with session-save enable and caja window is open,
with next xfce session start caja doesn't start automaticly or handle xfce destop.
Comment 30 John Duchek 2016-01-02 23:03:01 EST
I was unable to stop it from doing it for 6 days.  When I finally realized I was seeing MATE screen backgrounds (all the pics were new and not mine, so I knew something was screwy).  I finally clicked on desktop settings and the mate software came up not the xfce software I am familiar with.  It displayed the icons for the pics I had been seeing.  When the computer booted, it would show the normal background pics for a few seconds, then the mate pictures.  


The only way I could stop it was to use dnf to remove the entire Mate package. 

Mate was installed as the entire package using dnf last week.  

As background info, I have a dual monitor setup that displays different pics on each monitor, and changes them every 2 hours.   Mate did none of that, but did display its picture on both monitors.
Comment 31 Kevin Fenzi 2016-01-03 12:22:22 EST
This is likely due to how you have the caja/MATE prefs set... 

If you start caja with: 

caja --no-desktop

it should not try and manage your desktop. If you just start it with 'caja' it will check it's prefs to see if it should try and manage your desktop or not. I'm not sure off hand how to launch the MATE prefs to set this...
Comment 32 Wolfgang Ulbrich 2016-01-03 12:26:09 EST
[rave@mother ~]$ gsettings get org.mate.background show-desktop-icons
true
Comment 33 Wolfgang Ulbrich 2016-01-03 12:28:06 EST
btw. to disable use
[rave@mother ~]$ gsettings set org.mate.background show-desktop-icons false
Comment 34 Wolfgang Ulbrich 2016-01-03 12:33:02 EST
I use desktop icons in Mate, but this doesn't have any effect if i start XFCE session. With latest caja version from updates-testing caja don't handle the desktop from other DEs.
Comment 35 Fedora Update System 2016-01-05 16:56:55 EST
caja-1.12.2-2.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.
Comment 36 Fedora Update System 2016-01-07 22:23:38 EST
caja-1.12.2-2.fc22 has been pushed to the Fedora 22 stable repository. If problems still persist, please make note of it in this bug report.
Comment 37 John Duchek 2016-01-07 23:27:24 EST
It seems to be working ok.  No more 6 exits.  It is a very nice program!

John

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