Your message dated Thu, 6 Aug 2009 07:31:58 +0200
with message-id <8b2d7b4d0908052231u4c7063cdw5495cab076085...@mail.gmail.com>
and subject line Re: [Python-modules-team] Bug#540136: python-matplotlib: 
'import  pylab' depends on python-tk package
has caused the Debian Bug report #540136,
regarding python-matplotlib: 'import pylab' depends on python-tk package
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)


-- 
540136: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=540136
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: python-matplotlib
Version: 0.98.5.3-2
Severity: grave
Justification: renders package unusable


'import pylab' fails on ipython. It seems to work fine after install python-tk, 
as
mentioned in the ImportError.

Please check out the ipython output below showing the failure:

In [2]: import pylab
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)

/home/junior/<ipython console> in <module>()

/usr/lib/pymodules/python2.5/pylab.py in <module>()
----> 1 from matplotlib.pylab import *
      2 import matplotlib.pylab
      3 __doc__ = matplotlib.pylab.__doc__

/usr/lib/pymodules/python2.5/matplotlib/pylab.py in <module>()
    251 
    252 
--> 253 from matplotlib.pyplot import *
    254 
    255 # provide the recommended module abbrevs in the pylab namespace

/usr/lib/pymodules/python2.5/matplotlib/pyplot.py in <module>()
     73 
     74 from matplotlib.backends import pylab_setup
---> 75 new_figure_manager, draw_if_interactive, show = pylab_setup()
     76 
     77 

/usr/lib/pymodules/python2.5/matplotlib/backends/__init__.pyc in pylab_setup()
     23         backend_name = 'matplotlib.backends.%s'%backend_name.lower()
     24     backend_mod = __import__(backend_name,
---> 25                              globals(),locals(),[backend_name])
     26 
     27     # Things we pull in from all backends

/usr/lib/pymodules/python2.5/matplotlib/backends/backend_tkagg.py in <module>()
      5 import os, sys, math
      6 
----> 7 import Tkinter as Tk, FileDialog
      8 import tkagg                 # Paint image to Tk photo blitter extension
      9 from backend_agg import FigureCanvasAgg

/usr/lib/python2.5/lib-tk/Tkinter.py in <module>()
     39     import _tkinter
     40 except ImportError, msg:
---> 41     raise ImportError, str(msg) + ', please install the python-tk 
package'
     42 tkinter = _tkinter # b/w compat for export
     43 TclError = _tkinter.TclError

ImportError: No module named _tkinter, please install the python-tk package


-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (990, 'unstable'), (500, 'testing'), (500, 'stable'), (1, 
'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.30-1-amd64 (SMP w/1 CPU core)
Locale: LANG=pt_BR.UTF-8, LC_CTYPE=pt_BR.UTF-8 (charmap=UTF-8) (ignored: LC_ALL 
set to pt_BR.UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages python-matplotlib depends on:
ii  libatk1.0-0            1.26.0-1          The ATK accessibility toolkit
ii  libc6                  2.9-23            GNU C Library: Shared libraries
ii  libcairo2              1.8.8-2           The Cairo 2D vector graphics libra
ii  libfontconfig1         2.6.0-4           generic font configuration library
ii  libfreetype6           2.3.9-5           FreeType 2 font engine, shared lib
ii  libgcc1                1:4.4.1-1         GCC support library
ii  libglib2.0-0           2.20.4-1          The GLib library of C routines
ii  libgtk2.0-0            2.16.5-1          The GTK+ graphical user interface 
ii  libpango1.0-0          1.24.5-1          Layout and rendering of internatio
ii  libpng12-0             1.2.38-1          PNG library - runtime
ii  libstdc++6             4.4.1-1           The GNU Standard C++ Library v3
ii  python                 2.5.4-2           An interactive high-level object-o
ii  python-cairo           1.8.6-1           Python bindings for the Cairo vect
ii  python-dateutil        1.4.1-3           powerful extensions to the standar
ii  python-excelerator     0.6.3a-4          module for reading/writing Excel s
ii  python-glade2          2.14.1-3          GTK+ bindings: Glade support
ii  python-gobject         2.16.1-1          Python bindings for the GObject li
ii  python-gtk2            2.14.1-3          Python bindings for the GTK+ widge
ii  python-matplotlib-data 0.98.5.3-2        Python based plotting system (data
ii  python-numpy           1:1.2.1-1.1       Numerical Python adds a fast array
ii  python-pyparsing       1.5.2-1           Python parsing module
ii  python-qt3             3.18.1-1          Qt3 bindings for Python
ii  python-support         1.0.3             automated rebuilding support for P
ii  python-tz              2009g-1           Python version of the Olson timezo
ii  python-wxgtk2.8        2.8.7.1-1.1       wxWidgets Cross-platform C++ GUI t
ii  tcl8.5                 8.5.7-1           Tcl (the Tool Command Language) v8
ii  tk8.5                  8.5.7-1           Tk toolkit for Tcl and X11, v8.5 -
ii  zlib1g                 1:1.2.3.3.dfsg-14 compression library - runtime

python-matplotlib recommends no packages.

Versions of packages python-matplotlib suggests:
pn  dvipng                     <none>        (no description available)
ii  ipython                    0.9.1-3       enhanced interactive Python shell
ii  python-configobj           4.5.2-2       a simple but powerful config file 
pn  python-matplotlib-doc      <none>        (no description available)
pn  python-scipy               <none>        (no description available)
pn  python-traits              <none>        (no description available)
ii  texlive-extra-utils        2007.dfsg.2-6 TeX Live: TeX auxiliary programs
pn  texlive-latex-extra        <none>        (no description available)

-- no debconf information



--- End Message ---
--- Begin Message ---
Hi junior,
thanks for your report

On Thu, Aug 6, 2009 at 06:27, junior<edjun...@gmail.com> wrote:
> Package: python-matplotlib
> Version: 0.98.5.3-2
> Severity: grave
> Justification: renders package unusable
>
>
> 'import pylab' fails on ipython. It seems to work fine after install 
> python-tk, as
> mentioned in the ImportError.

It is explained in the documentation files included in the package:

/usr/share/doc/python-matplotlib/NEWS.Debian.gz
/usr/share/doc/python-matplotlib/README.Debian

We set the default to tk, but given the depend line is:

python-tk | python-gtk2 | python-wxgtk2.8 | python-qt3 | python-qt4

if any other binding is present, python-tk is not installed (there is
no easy/elegant solution to this, and we have discuss a lot about it
before implementing it), and so you'll be facing the problem you
described.

Solutions are:

- install python-tk
- configure matplotlib (either via /etc/matplotlibrc or in
~/.matplotlib) to use the backend for the bindings you have installed
(I'd say GtkAGG, from the package you have installed).

That said, I close this report

Regards,
-- 
Sandro Tosi (aka morph, morpheus, matrixhasu)
My website: http://matrixhasu.altervista.org/
Me at Debian: http://wiki.debian.org/SandroTosi


--- End Message ---

Reply via email to