Xpra: Ticket #481: ImportError: No Numeric module present: No module named Numeric

Version: 0.10.10+dfsg-1
Severity: normal
$ xpra attach ssh:server.example.com:7
xpra client version 0.10.10
    Could not find one or both of '/usr/bin/python' and '/usr/bin/xpra'
    Perhaps your environment has changed since the xpra server was started?
    I'll just try executing 'xpra' with current PATH, and hope...
2013-12-26 12:46:32,746 No OpenGL_accelerate module loaded: No module named OpenGL_accelerate
2013-12-26 12:46:32,794 Unable to load registered array format handler numeric:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/OpenGL/arrays/formathandler.py", line 44, in loadPlugin
    plugin_class = entrypoint.load()
  File "/usr/lib/python2.7/dist-packages/OpenGL/plugins.py", line 14, in load
    return importByName( self.import_path )
  File "/usr/lib/python2.7/dist-packages/OpenGL/plugins.py", line 28, in importByName
    module = __import__( ".".join(moduleName), {}, {}, moduleName)
  File "/usr/lib/python2.7/dist-packages/OpenGL/arrays/numeric.py", line 15, in <module>
    raise ImportError( """No Numeric module present: %s"""%(err))
ImportError: No Numeric module present: No module named Numeric
2013-12-26 12:46:32,919 OpenGL Version: 2.1 Mesa 9.2.2
2013-12-26 12:46:33,075 GL Extension GL_ARB_shader_objects available
2013-12-26 12:46:33,198 GL Extension GL_ARB_framebuffer_object available
2013-12-26 12:46:33,206 GL Extension GL_ARB_fragment_program available
2013-12-26 12:46:33,223 GL Extension GL_ARB_texture_rectangle available
2013-12-26 12:46:33,232 GL Extension GL_ARB_vertex_program available
2013-12-26 12:46:34,294 Attached to ssh:server.example.com:7 (press Control-C to detach)
2013-12-26 12:46:35,118 TrayBacking does not have any pixels / format!
-- System Information:
Debian Release: jessie/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Kernel: Linux 3.2.0-4-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages xpra depends on:
ii  libavcodec54              6:9.10-1
ii  libc6                     2.17-97
ii  libgtk2.0-0               2.24.22-1
ii  libswscale2               6:9.10-1
ii  libvpx1                   1.3.0-1
ii  libx11-6                  2:1.6.2-1
ii  libx264-133               2:0.133.2339+git585324f-2+b1
ii  libxcomposite1            1:0.4.4-1
ii  libxdamage1               1:1.1.4-1
ii  libxfixes3                1:5.0.1-1
ii  libxrandr2                2:1.4.1-1
ii  libxtst6                  2:1.2.2-1
ii  python                    2.7.5-5
ii  python-gtk2               2.24.0-3+b1
ii  x11-xserver-utils         7.7+1
ii  xserver-xorg-input-void   1:1.4.0-1+b2
ii  xserver-xorg-video-dummy  1:0.3.7-1+b1
Versions of packages xpra recommends:
ii  openssh-client                   1:6.4p1-2
ii  python-gtkglext1                 1.1.0-9.1
ii  python-imaging                   2.2.1-3
ii  python-webm                      0.2.2-2
ii  ssh-askpass                      1:1.2.4.1-9
ii  ssh-askpass-gnome [ssh-askpass]  1:6.4p1-2
Versions of packages xpra suggests:
ii  gstreamer0.10-plugins-bad   0.10.23-7.1
ii  gstreamer0.10-plugins-good  0.10.31-3+nmu2
pn  openssh-server              <none>
ii  pulseaudio                  4.0-6+b1
ii  pulseaudio-utils            4.0-6+b1
ii  python-dbus                 1.2.0-2+b1
ii  python-gst0.10              0.10.22-3


Thu, 26 Dec 2013 14:19:21 GMT - Antoine Martin: owner, description changed

This is a harmless warning indicating that python-numeric is not present - which is fine on jessie/sid since it has python-numpy instead. This is covered in the FAQ: wiki/FAQ

If it bothers you, apply the silence-pyopengl-formathandler-warnings.patch.


The only things I see that would be a cause for concern are:

This should not happen, but perhaps you had an old/new session from a different environment? (source install vs package)

That's an odd one. Again, it shouldn't happen. What application is using the tray and causing this? Do you have all pixel formats supported? To verify, please post the output of:

python xpra/codecs/loader.py

Thu, 26 Dec 2013 14:45:41 GMT - Timo Juhani Lindfors:

Hmm, could the FAQ and the patch be included in the package? If backtraces are part of normal operation it is difficult to know which ones are normal and which ones are not. I did try searching for an existing bug report about this particular backtrace but didn't find any, could the search maybe also look at the FAQ entries?

Could not find one or both of '/usr/bin/python' and '/usr/bin/xpra'

This is probably caused by ~/bin/xpra being a script that runs xpra from an unstable chroot.

TrayBacking does not have any pixels / format!

I don't know which applications use the tray and loader.py does not seem to be part of the xpra package. I'm using chromium, quassel, gnome-terminal and iceweasel.

I did apt-get source xpra on the client but even that didn't come with loader.py -- is it maybe only part of some newer version?


Thu, 26 Dec 2013 14:53:44 GMT - Antoine Martin:

Hmm, could the FAQ and the patch be included in the package? Version: 0.10.10+dfsg-1


This is not one of our packages. Our packages *should* have it included.


loader.py does not seem to be part of the xpra package


Ah, sorry - this is in v0.11.x only. For v0.10.x, this is the best you can get:

xpra attach --encoding=help

But looking at the code, we should be seeing a tray pixel paint error before this message anyway, odd. Please run xpra with:

XPRA_TRAY_DEBUG=1 xpra attach ...

This should tell us more about what is going on, and why we don't have any pixels after a tray paint request.


Thu, 26 Dec 2013 15:01:27 GMT - Antoine Martin:

could the search maybe also look at the FAQ entries?


It does, but this particular variant of the error message was not present yet, I have added it now: wiki/FAQ


Thu, 26 Dec 2013 16:25:59 GMT - Timo Juhani Lindfors:

Ok, should I report a separate bug against the debian package in bugs.debian.org or would you like to do that, you probably already know how the packaging should include it?

$ xpra attach --encoding=help
xpra client version 0.10.10
gtk2 xpra client supports the following encodings:
 * x264        H.264 video codec
 * vpx         VPx video codec
 * webp        WebP compression (lossless or lossy)
 * png         Portable Network Graphics (24 or 32bpp for transparency)
 * png/P       Portable Network Graphics (8bpp colour)
 * png/L       Portable Network Graphics (8bpp grayscale)
 * rgb         Raw RGB pixels, lossless, compressed using zlib (24 or 32bpp for transparency)
 * jpeg        JPEG lossy compression
$ sid env XPRA_TRAY_DEBUG=1 /usr/bin/xpra attach ssh:server.example.com:7
xpra client version 0.10.10
2013-12-26 16:23:10,114 No OpenGL_accelerate module loaded: No module named OpenGL_accelerate
    Could not find one or both of '/usr/bin/python' and '/usr/bin/xpra'
    Perhaps your environment has changed since the xpra server was started?
    I'll just try executing 'xpra' with current PATH, and hope...
2013-12-26 16:23:10,173 Unable to load registered array format handler numeric:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/OpenGL/arrays/formathandler.py", line 44, in loadPlugin
    plugin_class = entrypoint.load()
  File "/usr/lib/python2.7/dist-packages/OpenGL/plugins.py", line 14, in load
    return importByName( self.import_path )
  File "/usr/lib/python2.7/dist-packages/OpenGL/plugins.py", line 28, in importByName
    module = __import__( ".".join(moduleName), {}, {}, moduleName)
  File "/usr/lib/python2.7/dist-packages/OpenGL/arrays/numeric.py", line 15, in <module>
    raise ImportError( """No Numeric module present: %s"""%(err))
ImportError: No Numeric module present: No module named Numeric
2013-12-26 16:23:10,342 OpenGL Version: 2.1 Mesa 9.2.2
2013-12-26 16:23:10,481 GL Extension GL_ARB_shader_objects available
2013-12-26 16:23:10,574 GL Extension GL_ARB_framebuffer_object available
2013-12-26 16:23:10,582 GL Extension GL_ARB_fragment_program available
2013-12-26 16:23:10,585 GL Extension GL_ARB_texture_rectangle available
2013-12-26 16:23:10,591 GL Extension GL_ARB_vertex_program available
2013-12-26 16:23:10,901 get_tray_icon_filename using default: /usr/bin/../share/xpra/icons/xpra.png
2013-12-26 16:23:10,903 get_tray_icon_filename using default: /usr/bin/../share/xpra/icons/xpra.png
2013-12-26 16:23:11,270 Attached to ssh:server.example.com:7 (press Control-C to detach)
2013-12-26 16:23:11,271 bell_toggled((<gtk.CheckMenuItem object at 0x382ceb0 (GtkCheckMenuItem at 0x20f0300)>,)) bell_enabled=True
2013-12-26 16:23:11,273 cursors_toggled((<gtk.CheckMenuItem object at 0x382ce10 (GtkCheckMenuItem at 0x20f03c0)>,)) cursors_enabled=True
2013-12-26 16:23:11,274 notifications_toggled((<gtk.CheckMenuItem object at 0x382cfa0 (GtkCheckMenuItem at 0x20f0480)>,)) notifications_enabled=True
2013-12-26 16:23:11,274 clipboard_toggled((<gtk.CheckMenuItem object at 0x382cf50 (GtkCheckMenuItem at 0x20f0540)>,)) clipboard_enabled=True, new_state=True
2013-12-26 16:23:11,275 gl_set((<XpraClient object at 0x2fdf4b0 (xpra+client+gtk2+client+XpraClient at 0x2361140)>,)) opengl_enabled=True, window_unmap=True
2013-12-26 16:23:11,276 make_encodingsmenu(..) encoding=x264, current=x264, active=True
2013-12-26 16:23:11,277 make_encodingsmenu(..) encoding=vpx, current=x264, active=False
2013-12-26 16:23:11,278 make_encodingsmenu(..) encoding=webp, current=x264, active=False
2013-12-26 16:23:11,279 make_encodingsmenu(..) encoding=png, current=x264, active=False
2013-12-26 16:23:11,279 make_encodingsmenu(..) encoding=png/P, current=x264, active=False
2013-12-26 16:23:11,280 make_encodingsmenu(..) encoding=png/L, current=x264, active=False
2013-12-26 16:23:11,281 make_encodingsmenu(..) encoding=rgb, current=x264, active=False
2013-12-26 16:23:11,282 make_encodingsmenu(..) encoding=jpeg, current=x264, active=False
2013-12-26 16:23:11,286 keyboard_sync_toggled((<gtk.CheckMenuItem object at 0x38bfb90 (GtkCheckMenuItem at 0x39b1540)>,)) keyboard_sync=True
2013-12-26 16:23:11,369 get_tray_icon_filename using default: /usr/bin/../share/xpra/icons/xpra.png
2013-12-26 16:23:11,660 GTKStatusIconTray.get_geometry() <gtk.StatusIcon object at 0x3a2e8c0 (GtkStatusIcon at 0x3a60b00)>.get_geometry()=(<gtk.gdk.ScreenX11 object at 0x3a370f0 (GdkScreenX11 at 0x26eeb10)>, gtk.gdk.Rectangle(0, 0, 200, 200), <enum GTK_ORIENTATION_HORIZONTAL of type GtkOrientation>)
2013-12-26 16:23:11,663 ClientTray(4).draw_region[0, 0, 48, 48, 'png', '4703 bytes', 0, 1, {}, [<function record_decode_time at 0x3a32398>]]
2013-12-26 16:23:11,739 GTKStatusIconTray.get_geometry() <gtk.StatusIcon object at 0x3a2e8c0 (GtkStatusIcon at 0x3a60b00)>.get_geometry()=(<gtk.gdk.ScreenX11 object at 0x7f5f5c01ce60 (GdkScreenX11 at 0x26eeb10)>, gtk.gdk.Rectangle(0, 0, 48, 48), <enum GTK_ORIENTATION_HORIZONTAL of type GtkOrientation>)
2013-12-26 16:23:11,742 ClientTray(4).after_draw_update_tray(True)
2013-12-26 16:23:11,743 TrayBacking does not have any pixels / format!
2013-12-26 16:23:13,797 ClientTray(4).draw_region[0, 0, 48, 48, 'png', '4703 bytes', 0, 2, {}, [<function record_decode_time at 0x7f5f5c029de8>]]
2013-12-26 16:23:13,853 ClientTray(4).after_draw_update_tray(True)
2013-12-26 16:23:13,854 ClientTray(4).set_tray_icon() format=('rgb32', 48, 48, 192)
2013-12-26 16:23:13,953 GTKStatusIconTray.get_geometry() <gtk.StatusIcon object at 0x3a2e8c0 (GtkStatusIcon at 0x3a60b00)>.get_geometry()=(<gtk.gdk.ScreenX11 object at 0x7f5f5c02b3c0 (GdkScreenX11 at 0x26eeb10)>, gtk.gdk.Rectangle(0, 0, 48, 48), <enum GTK_ORIENTATION_HORIZONTAL of type GtkOrientation>)

Thu, 26 Dec 2013 16:48:09 GMT - Antoine Martin: status changed; cc, resolution set

should I report a separate bug against the debian package in bugs.debian.org or would you like to do that, you probably already know how the packaging should include it?


I've added the maintainer to the CC list for this ticket. The only thing needed is to apply the patch at build time.


As for the tray issue - the important part is this:

GTKStatusIconTray.get_geometry() <gtk.StatusIcon object at 0x3a2e8c0 (GtkStatusIcon at 0x3a60b00)>.get_geometry()=\
    (<gtk.gdk.ScreenX11 object at 0x3a370f0 (GdkScreenX11 at 0x26eeb10)>, \
     gtk.gdk.Rectangle(0, 0, 200, 200), \
     <enum GTK_ORIENTATION_HORIZONTAL of type GtkOrientation>)
ClientTray(4).draw_region[0, 0, 48, 48, 'png', '4703 bytes', 0, 1, {}, [<function record_decode_time at 0x3a32398>]]
GTKStatusIconTray.get_geometry() <gtk.StatusIcon object at 0x3a2e8c0 (GtkStatusIcon at 0x3a60b00)>.get_geometry()=\
    (<gtk.gdk.ScreenX11 object at 0x7f5f5c01ce60 (GdkScreenX11 at 0x26eeb10)>, \
     gtk.gdk.Rectangle(0, 0, 48, 48), \
     <enum GTK_ORIENTATION_HORIZONTAL of type GtkOrientation>)
ClientTray(4).after_draw_update_tray(True)
TrayBacking does not have any pixels / format!

So it may be because the tray is still in its default size (200x200) when we get the first paint. The second one succeeds and this belongs in a separate (low priority) bug. So I am closing this one. Thanks!


Sat, 23 Jan 2021 04:56:53 GMT - migration script:

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/481