Unable to get list of available modules in python's online help.

Bug #189109 reported by Kim
6
Affects Status Importance Assigned to Milestone
gnome-btdownload (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

I'm not able to get a list of available modules in the python online help, instead error messages are displayed and python exits.
I'm logged in using ssh on the machine and haven't got X11 forwarded, error messages are printed out telling that a display
can't be opened - the question is why a X display is needed at all...

/etc/lsb-release:
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=7.10
DISTRIB_CODENAME=gutsy
DISTRIB_DESCRIPTION="Ubuntu 7.10"

Versions for packages seen in the log further down:
python 2.5.1-1ubuntu2
python-apt 0.7.3.1ubuntu4
python-gtk2 2.12.0-0ubuntu2

Below is what happens when I try to get a list of available modules:

user@test:~$ python
Python 2.5.1 (r251:54863, Oct 5 2007, 13:50:07)
[GCC 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> help()

Welcome to Python 2.5! This is the online help utility.

If this is your first time using Python, you should definitely check out
the tutorial on the Internet at http://www.python.org/doc/tut/.

Enter the name of any module, keyword, or topic to get help on writing
Python programs and using Python modules. To quit this help utility and
return to the interpreter, just type "quit".

To get a list of available modules, keywords, or topics, type "modules",
"keywords", or "topics". Each module also comes with a one-line summary
of what it does; to list the modules whose summaries contain a given word
such as "spam", type "modules spam".

help> modules

Please wait a moment while I gather a list of all available modules...

/var/lib/python-support/python2.5/gtk-2.0/gtk/__init__.py:72: GtkWarning: could not open display
  warnings.warn(str(e), _gtk.Warning)
/usr/lib/python2.5/site-packages/apt/__init__.py:18: FutureWarning: apt API not stable yet
  warnings.warn("apt API not stable yet", FutureWarning)
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: GtkWarning: gdk_keymap_get_for_display: assertion `GDK_IS_DISPLAY (display)' failed
  from _keybinder import *
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: GtkWarning: gdk_screen_get_root_window: assertion `GDK_IS_SCREEN (screen)' failed
  from _keybinder import *

** (.:5355): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed

** (.:5355): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed

** (.:5355): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: Warning: invalid (NULL) pointer instance
  from _keybinder import *
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: Warning: g_signal_connect_data: assertion `G_TYPE_CHECK_INSTANCE (instance)' failed
  from _keybinder import *
/usr/lib/python2.5/site-packages/deskbar/core/Utils.py:10: GtkWarning: gtk_icon_theme_get_for_screen: assertion `GDK_IS_SCREEN (screen)' failed
  ICON_THEME = gtk.icon_theme_get_default()
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
/usr/lib/python2.5/site-packages/gnomebtdownload/client.py:51: GtkWarning: cannot open display:
  gnome_program = gnome.program_init(app_name, app_version)
user@test:~$

Revision history for this message
David Futcher (bobbo) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. This bug did not have a package associated with it, which is important for ensuring that it gets looked at by the proper developers. You can learn more about finding the right package at [WWW] https://wiki.ubuntu.com/Bugs/FindRightPackage.

Thanks

Revision history for this message
pete (pete-jobster) wrote :
Download full text (4.2 KiB)

Same here...and do you really need the package as attachment? Looks like all the information you need is in the stack trace.

$ python
Python 2.5.1 (r251:54863, Mar 7 2008, 04:10:12)
[GCC 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> modules
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
NameError: name 'modules' is not defined
>>> help()

Welcome to Python 2.5! This is the online help utility.

If this is your first time using Python, you should definitely check out
the tutorial on the Internet at http://www.python.org/doc/tut/.

Enter the name of any module, keyword, or topic to get help on writing
Python programs and using Python modules. To quit this help utility and
return to the interpreter, just type "quit".

To get a list of available modules, keywords, or topics, type "modules",
"keywords", or "topics". Each module also comes with a one-line summary
of what it does; to list the modules whose summaries contain a given word
such as "spam", type "modules spam".

help> modules

Please wait a moment while I gather a list of all available modules...

/var/lib/python-support/python2.5/gtk-2.0/gtk/__init__.py:72: GtkWarning: could not open display
  warnings.warn(str(e), _gtk.Warning)
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: GtkWarning: gdk_keymap_get_for_display: assertion `GDK_IS_DISPLAY (display)' failed
  from _keybinder import *
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: GtkWarning: gdk_screen_get_root_window: assertion `GDK_IS_SCREEN (screen)' failed
  from _keybinder import *

** (.:12806): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed

** (.:12806): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed

** (.:12806): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: Warning: invalid (NULL) pointer instance
  from _keybinder import *
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: Warning: g_signal_connect_data: assertion `G_TYPE_CHECK_INSTANCE (instance)' failed
  from _keybinder import *
/usr/lib/python2.5/site-packages/deskbar/core/Utils.py:10: GtkWarning: gtk_icon_theme_get_for_screen: assertion `GDK_IS_SCREEN (screen)' failed
  ICON_THEME = gtk.icon_theme_get_default()
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_icon')
ERROR:root:load_icon:Icon Load Error:'NoneType' object has no attribute 'load_icon' (or 'NoneType' object has no attribute 'load_ico...

Read more...

Revision history for this message
Jayson Rowe (jayson.rowe) wrote :

Since it's been a very long time since any additional info was added to this bug, I'm just checking to see if this is still an issue, and find out what additional work should be done on this bug.

Revision history for this message
Kim (kim-backstrom) wrote :
Download full text (4.4 KiB)

python still seems to crash when trying to list the modules without access to X display.
Seems to be due to /usr/lib/python2.5/site-packages/gnomebtdownload/client.py ( line 50), which belongs to gnome-btdownload version 0.0.30-2, see log below.

log:

$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=8.10
DISTRIB_CODENAME=intrepid
DISTRIB_DESCRIPTION="Ubuntu 8.10"

$ xedit
Error: Can't open display:
$ python
Python 2.5.2 (r252:60911, Oct 5 2008, 19:24:49)
[GCC 4.3.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> help()

Welcome to Python 2.5! This is the online help utility.

If this is your first time using Python, you should definitely check out
the tutorial on the Internet at http://www.python.org/doc/tut/.

Enter the name of any module, keyword, or topic to get help on writing
Python programs and using Python modules. To quit this help utility and
return to the interpreter, just type "quit".

To get a list of available modules, keywords, or topics, type "modules",
"keywords", or "topics". Each module also comes with a one-line summary
of what it does; to list the modules whose summaries contain a given word
such as "spam", type "modules spam".

help> modules

Please wait a moment while I gather a list of all available modules...

/var/lib/python-support/python2.5/gtk-2.0/gtk/__init__.py:72: GtkWarning: could not open display
warnings.warn(str(e), _gtk.Warning)
/usr/lib/python2.5/site-packages/Ft/Lib/ImportUtil.py:362: UserWarning: Module test was already imported from /usr/lib/python2.5/test/__init__.pyc, but /var/lib/python-support/python2.5 is being added to sys.path
from pkg_resources import get_provider, resource_filename
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: GtkWarning: gdk_keymap_get_for_display: assertion `GDK_IS_DISPLAY (display)' failed
from _keybinder import *
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: GtkWarning: gdk_screen_get_root_window: assertion `GDK_IS_SCREEN (screen)' failed
from _keybinder import *

** (.:15099): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed

** (.:15099): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed

** (.:15099): CRITICAL **: egg_keymap_resolve_virtual_modifiers: assertion `GDK_IS_KEYMAP (keymap)' failed
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: Warning: invalid (NULL) pointer instance
from _keybinder import *
/usr/lib/python2.5/site-packages/deskbar/core/keybinder/__init__.py:1: Warning: g_signal_connect_data: assertion `G_TYPE_CHECK_INSTANCE (instance)' failed
from _keybinder import *
GConf Error: Failed to contact configuration server; some possible causes are that you need to enable TCP/IP networking for ORBit, or you have stale NFS locks due to a system crash. See http://www.gnome.org/projects/gconf/ for information. (Details - 1: Not running within active session)
GConf Error: Failed to contact configuration server; some possible causes are that you need to enable TCP/IP networking for ORBit, or you have stale NFS locks due to a system crash. See http://www.gnome.org/...

Read more...

Revision history for this message
Kim (kim-backstrom) wrote :

According to log this seems to be due to /usr/lib/python2.5/site-packages/gnomebtdownload/client.py ( line 50), which belongs to gnome-btdownload.

Revision history for this message
Victor Vargas (kamus) wrote :

We are closing this bug report because it lacks the information we need to investigate the problem, as described in the previous comments. Please reopen it if you can give us the missing information, and don't hesitate to submit bug reports in the future. To reopen the bug report you can click on the current status, under the Status column, and change the Status back to "New". Thanks again!

Changed in gnome-btdownload (Ubuntu):
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.