Cinnamon Menu completely empty of applications

Please post suggestions for improvement of Cinnamon on:
https://github.com/linuxmint/Cinnamon
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
ouloecr

Cinnamon Menu completely empty of applications

Post by ouloecr »

Up until recently, my menu was working completely normally, no problems at all. However, I tried to edit the menu, but the editor seemed to crash when I tried to change something, after which the menu is entirely blank except for the power, restart, and lock buttons, and the launcher applets I had disappeared. I've tried restarting cinnamon, resetting the menu to defaults, editing other applets, etc., but nothing seems to change it. I've tried googling for solutions, but the only other instance of this problem I found had the poster just give up entirely when no one responded, so I'm hoping I'll have better luck than he did.

Here's a screenshot of the menu for reference.
User avatar
karlchen
Level 23
Level 23
Posts: 18209
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Cinnamon Menu completely empty of applications

Post by karlchen »

Hello, ouloecr.

OK. We do not want you to give up and jump off the Talahassilassi bridge in despair. :-)
Please, verify that there are lots of *.desktop files in these 2 locations still:
(1) /usr/share/applications
(2) ~/.local/share/applications
If there are .desktop files in these locations then the problem should be resolvable.

I assume a corrupt Cinnamon related file will have been left behind in your personal profile somewhere. All we have to do is finding out how to reset your personal Cinnamon menu settings to default, logoff and log back in. Should be as simple as that. Hopefully.

But I admit I will have to look around on my Cinnamon system a bit to get an idea what to delete. Maybe someone else already knows and chimes in while I'll be still searching ...

Cheers,
Karl
Image
The people of Alderaan have been bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine for 771 days now.
Lifeline
kelebek333
Level 4
Level 4
Posts: 419
Joined: Sat Jun 25, 2011 11:57 am

Re: Cinnamon Menu completely empty of applications

Post by kelebek333 »

You can try to reset menu applets with following command.

Code: Select all

rm -rf ~/.cinnamon/configs/menu@cinnamon.org
ouloecr

Re: Cinnamon Menu completely empty of applications

Post by ouloecr »

karlchen wrote: Please, verify that there are lots of *.desktop files in these 2 locations still:
(1) /usr/share/applications
(2) ~/.local/share/applications
If there are .desktop files in these locations then the problem should be resolvable.
There are still plenty of .desktop files there. If it is, as you suspect, a corrupt cinnamon file, then do you think reinstalling cinnamon might fix it?
kelebek333 wrote:You can try to reset menu applets with following command.

Code: Select all

rm -rf ~/.cinnamon/configs/menu@cinnamon.org
Unfortunately this didn't seem to do anything.

It might be worth mentioning that I upgraded this system from LM 15 to 16 a little while ago. It seems unlikely to me, but perhaps there's some sort of conflict or issue caused by that?
User avatar
karlchen
Level 23
Level 23
Posts: 18209
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Cinnamon Menu completely empty of applications

Post by karlchen »

Hello, ouloecr.

You have logged off and logged on after removing the suggested folder content?
Actually, as the problem seems to be inside your profile, I do not think that re-installing Cinnamon will fix the problem, because it just re-installs the systemwide binaries and the systemwide configuration, but does not touch your profile.

Cheers,
Karl
Image
The people of Alderaan have been bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine for 771 days now.
Lifeline
User avatar
karlchen
Level 23
Level 23
Posts: 18209
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Cinnamon Menu completely empty of applications

Post by karlchen »

Hello, ouloecr.

As I am finally logged in to a Cinnamon desktop again, I can give another filename to you. I think it is worth checking this name and verify the file is not 0-bytes e.g.:

Code: Select all

~/.config/menus/cinnamon-applications.menu
This is the content of the file here where the Cinnamon 2.0.14 menu works correctly. The file content might look differently on your machine. But a totally empty or missing file might give a hint what the root cause of your empty menu might be.

Code: Select all

<?xml version="1.0" ?>
<!DOCTYPE Menu
  PUBLIC '-//freedesktop//DTD Menu 1.0//EN'
  'http://standards.freedesktop.org/menu-spec/menu-1.0.dtd'>
<Menu>
	<Name>Applications</Name>
	<MergeFile type="parent">/etc/xdg/menus/cinnamon-applications.menu</MergeFile>
	<Menu>
		<Name>Preferences</Name>
		<Exclude>
			<Filename>alacarte.desktop</Filename>
		</Exclude>
		<AppDir>/home/karl/.local/share/applications</AppDir>
		<Include>
			<Filename>gnome-mouse-panel.desktop</Filename>
		</Include>
		<Exclude>
			<Filename>session-properties.desktop</Filename>
		</Exclude>
		<Include>
			<Filename>cinnamon-menu-editor.desktop</Filename>
		</Include>
	</Menu>
	<Menu>
		<Name>Accessories</Name>
		<Include>
			<Filename>nemo-folder-handler.desktop</Filename>
		</Include>
		<AppDir>/home/karl/.local/share/applications</AppDir>
		<Exclude>
			<Filename>nemo.desktop</Filename>
		</Exclude>
	</Menu>
</Menu>
And a final piece of advice for the moment:
If checking the named file does not help, you might press <Alt><F2> and type cinnamon-menu-editor and press enter. Inside the cinnamon-menu-editor there should be a button [Restore System Configuration]. Please, click this button. Then click [Close]. This should give you a funtional menu again, though any modifications done by you might be reverted. (Hm, telling from your initial post you have already tried the [Restore System Configuration] button without too much success.)

HTH,
Karl
Image
The people of Alderaan have been bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine for 771 days now.
Lifeline
User avatar
karlchen
Level 23
Level 23
Posts: 18209
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Cinnamon Menu completely empty of applications

Post by karlchen »

Any news? (Reads better than just writing "bump")
Image
The people of Alderaan have been bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine for 771 days now.
Lifeline
blumf
Level 1
Level 1
Posts: 10
Joined: Thu Aug 08, 2013 7:38 pm

Re: Cinnamon Menu completely empty of applications

Post by blumf »

Just run into the same problem, using the menu editor removes all menu content.

A little clue:

Code: Select all

$ cinnamon-menu-editor 
Traceback (most recent call last):
  File "/usr/bin/cinnamon-menu-editor", line 19, in <module>
    main()
  File "/usr/bin/cinnamon-menu-editor", line 15, in main
    app = MainWindow.MainWindow(datadir, version)
  File "/usr/lib/cinnamon-menu-editor/cme/MainWindow.py", line 43, in __init__
    self.editor = MenuEditor()
  File "/usr/lib/cinnamon-menu-editor/cme/MenuEditor.py", line 31, in __init__
    self.load()
  File "/usr/lib/cinnamon-menu-editor/cme/MenuEditor.py", line 44, in load
    if not self.tree.load_sync():
gi._glib.GError: Error on line 1 char 1: Document was empty or contained only whitespace
No idea what file that may be.

Major problem that the menu editor can do this without warning.

EDIT:

Fixed:

Code: Select all

rm -r ~/.config/menus
Then, <alt>+<f2>, type 'r' and <enter> to restart Cinnamon (or use the 'troubleshoot/restart cinnamon' option in the setting tool on the panel)
avigreen75

Re: Cinnamon Menu completely empty of applications

Post by avigreen75 »

Hi,
I had the same issue just yesterday. When using the menu editor and trying to hide items with non ascii characters in it, like öäü, the menu structure got corrupt.
A workaround could be to modify the menu data instead. Where is it stored?
Certainly better is to improve the menu editor. Any Ideas?
Cheers,
Ralph
User avatar
karlchen
Level 23
Level 23
Posts: 18209
Joined: Sat Dec 31, 2011 7:21 am
Location: Germany

Re: Cinnamon Menu completely empty of applications

Post by karlchen »

avigreen75 wrote:A workaround could be to modify the menu data instead. Where is it stored?
answer => here
Image
The people of Alderaan have been bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine for 771 days now.
Lifeline
Gmood
Level 1
Level 1
Posts: 1
Joined: Wed Feb 04, 2015 12:11 pm

Re: Cinnamon Menu completely empty of applications

Post by Gmood »

Hi,
I had the same issue just yesterday. When using the menu editor, and trying to move and delete items, it removed all menu content.
Finally i came to this post and blumf's solution solved it! :D
Thank's for that!
yoramdavid

Re: Cinnamon Menu completely empty of applications

Post by yoramdavid »

I had the exact same problem today, my "~/.config/menus/cinnamon-applications.menu" file was 0 bytes.
I deleted it and restarted cinnamon and problem solved!
Thanks a lot.

David.

PS- I rebooted the computer, it is still fine but the file was not recreated...
PS2 - OK, it gets recreated once I edit the menu. Good to keep a backup of a working file after editing.

After all, it is not solved at all. Anything I do to edit the menu results in a corrupted file and I cannot edit it any more.
both
(1) /usr/share/applications
(2) ~/.local/share/applications
are populated with ".desktop" files, some are present on both locations, but some are not.

At the moment I am trying the following: I deleted all the files created with name similar to "alacarte-made-0585536e-b3d8-11e4-a4e1-7824afc86a91.desktop"
After that I have been editing the menus again without crashes :)
Let see if it continues that way.

Hope it helps someone.
byildiz

Re: Cinnamon Menu completely empty of applications

Post by byildiz »

Thank you very much. It solved the problem like a charm.
blumf wrote: Sun Mar 09, 2014 1:07 pm Just run into the same problem, using the menu editor removes all menu content.

A little clue:

Code: Select all

$ cinnamon-menu-editor 
Traceback (most recent call last):
  File "/usr/bin/cinnamon-menu-editor", line 19, in <module>
    main()
  File "/usr/bin/cinnamon-menu-editor", line 15, in main
    app = MainWindow.MainWindow(datadir, version)
  File "/usr/lib/cinnamon-menu-editor/cme/MainWindow.py", line 43, in __init__
    self.editor = MenuEditor()
  File "/usr/lib/cinnamon-menu-editor/cme/MenuEditor.py", line 31, in __init__
    self.load()
  File "/usr/lib/cinnamon-menu-editor/cme/MenuEditor.py", line 44, in load
    if not self.tree.load_sync():
gi._glib.GError: Error on line 1 char 1: Document was empty or contained only whitespace
No idea what file that may be.

Major problem that the menu editor can do this without warning.

EDIT:

Fixed:

Code: Select all

rm -r ~/.config/menus
Then, <alt>+<f2>, type 'r' and <enter> to restart Cinnamon (or use the 'troubleshoot/restart cinnamon' option in the setting tool on the panel)
Locked

Return to “Cinnamon”