sugarlabs / sugar

Sugar GTK shell
GNU General Public License v3.0
255 stars 241 forks source link

sugar-control-panel harmless traceback #793

Open quozl opened 6 years ago

quozl commented 6 years ago

Using sugar-control-panel command generates a harmless but emotionally disruptive traceback;

guest@guest:~$ sugar-control-panel -g timezone
/usr/lib/python2.7/dist-packages/jarabe/journal/model.py:33: PyGIWarning: SugarExt was imported without specifying a version first. Use gi.require_version('SugarExt', '1.0') before import to ensure that the right version gets loaded.
  from gi.repository import SugarExt
/usr/lib/python2.7/dist-packages/jarabe/frame/eventarea.py:19: PyGIWarning: Wnck was imported without specifying a version first. Use gi.require_version('Wnck', '3.0') before import to ensure that the right version gets loaded.
  from gi.repository import Wnck
ERROR:root:Exception while loading extension:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/jarabe/controlpanel/cmd.py", line 68, in load_modules
    globals(), locals(), ['model'])
  File "/usr/share/sugar/extensions/cpsection/frame/model.py", line 17, in <module>
    from jarabe.frame import get_view
  File "/usr/lib/python2.7/dist-packages/jarabe/frame/__init__.py", line 16, in <module>
    from jarabe.frame.frame import Frame
  File "/usr/lib/python2.7/dist-packages/jarabe/frame/frame.py", line 31, in <module>
    from jarabe.frame.friendstray import FriendsTray
  File "/usr/lib/python2.7/dist-packages/jarabe/frame/friendstray.py", line 20, in <module>
    from jarabe.view.buddymenu import BuddyMenu
  File "/usr/lib/python2.7/dist-packages/jarabe/view/buddymenu.py", line 37, in <module>
    import jarabe.desktop.homewindow
  File "/usr/lib/python2.7/dist-packages/jarabe/desktop/homewindow.py", line 28, in <module>
    from jarabe.desktop.meshbox import MeshBox
  File "/usr/lib/python2.7/dist-packages/jarabe/desktop/meshbox.py", line 35, in <module>
    from jarabe.view.buddyicon import BuddyIcon
  File "/usr/lib/python2.7/dist-packages/jarabe/view/buddyicon.py", line 19, in <module>
    from jarabe.view.buddymenu import BuddyMenu
ImportError: cannot import name BuddyMenu
/usr/share/sugar/extensions/cpsection/keyboard/model.py:19: PyGIWarning: Xkl was imported without specifying a version first. Use gi.require_version('Xkl', '1.0') before import to ensure that the right version gets loaded.
  from gi.repository import Xkl

guest@guest:~$ █

Return status is zero, which indicates success. Actual output is the blank line before the shell prompt.

holta commented 6 years ago

Perhaps this is a known issue, but FWIW the following legacy commands[*] do not appear to work in OLPC OS 13.2.9:

   sugar-control-panel -s timezone America/Port-au-Prince
   sugar-control-panel -s languages French/France

(@quozl has clarified that TZ command should not be run with sudo, as Sugar timezone is not a system-wide configuration setting; it is local to the user.)

[*] Originally documented at: http://wiki.laptop.org/go/Sugar_Control_Panel#Setting_The_Timezone

quozl commented 6 years ago

Please don't post off-topic noise or steal the issue? As you will have seen in my introduction on this issue, it is about the harmless traceback in the scenario where the commands do work.