Author Topic: [Solved] Obmenu problems  (Read 944 times)

Offline cynclida

  • Newbie
  • *
  • Posts: 16
[Solved] Obmenu problems
« on: February 17, 2015, 11:05:44 am »
Hi, first of all thanks for this nice and well-done linux distro.

Installed base-version with openbox. To configure a customized openbox menu, I installed obmenu. But obmenu works just with root privileges, and -the real problem- it opens the file /root/.config/openbox/menu.xml, no way to open the flie I wanted to edit, which is /home/myuser/.config/menu.xml.

Finally I configured the menu editing menu.xml manually, but it is really strange. On another machine I run Debian testing, and there obmenu runs without root privileges and accesses the correct menu.xml. What is the problem?
« Last Edit: March 24, 2015, 01:51:41 pm by cynclida »

Online pavroo

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1462
    • SparkyLinux
Re: Obmenu problems
« Reply #1 on: February 17, 2015, 04:59:06 pm »
Hi
Check who is the owner of the menu.xml file:
Code: [Select]
ls -l /home/you/.confg/openbox/menu.xmlIf not you, change it, as root:
Code: [Select]
su
chown you:you /home/you/.confg/openbox/menu.xml
Nothing is easy as it looks.

Offline cynclida

  • Newbie
  • *
  • Posts: 16
Re: Obmenu problems
« Reply #2 on: February 17, 2015, 08:07:34 pm »
Thanks for your reply.

Onwer of the /home/petra/.config/openbox/menu.xml file is me:
Code: [Select]
petra@jft00:~$ ls -l /home/petra/.config/openbox/menu.xml
-rwxr-xr-x 1 petra petra 36788 Feb 15 23:47 /home/petra/.config/openbox/menu.xml

The problem remains unchanged. If it helps, this is the output of the obmenu command (without root privileges):
Code: [Select]
petra@jft00:~$ obmenu
Traceback (most recent call last):
  File "/usr/bin/obmenu", line 617, in <module>
    app.init()
  File "/usr/bin/obmenu", line 610, in init
    self.createTree(None, None)
  File "/usr/bin/obmenu", line 41, in createTree
    if self.menu.getMenu(it["id"]) and it["action"] == "":
  File "/usr/lib/pymodules/python2.7/obxml.py", line 334, in getMenu
    d = self._get_menu_props(i)
  File "/usr/lib/pymodules/python2.7/obxml.py", line 137, in _get_menu_props
    if mnu: lb = mnu.attributes["label"].nodeValue
  File "/usr/lib/python2.7/xml/dom/minidom.py", line 522, in __getitem__
    return self._attrs[attname_or_tuple]
KeyError: 'label'

But don't worry, I can edit the  /home/petra/.config/openbox/menu.xml manually, just sometimes it's good to have the gui as well. And I really don't understand why it behaves like that.

Online pavroo

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1462
    • SparkyLinux
Re: Obmenu problems
« Reply #3 on: February 17, 2015, 09:13:30 pm »
I remember now.
I saw the problem time ago and it came from Debian package.
That's why I removed it from Sparky's Openbox iso.
Somebody should reported it to Debian devs already I think.
Nothing is easy as it looks.

Offline cynclida

  • Newbie
  • *
  • Posts: 16
Re: Obmenu problems
« Reply #4 on: February 18, 2015, 08:37:01 am »
Ok, and I installed it right from the debian repo.

Thanks for the info. Maybe some upadate will repair it.

Offline cynclida

  • Newbie
  • *
  • Posts: 16
Re: [Solved] Obmenu problems
« Reply #5 on: March 24, 2015, 02:02:09 pm »
Just could solve the problem: replace in ~/.config/openbox/menu.xml the lines
Code: [Select]
<menu id="/Debian">
</menu>
by
Code: [Select]
<menu id="/Debian" />

Then obmenu works as it should, also for general user.