From 8bf24dd1a7938caa8fdf1e511ae1dc65f8423e04 Mon Sep 17 00:00:00 2001
From: iohannez <johannes.schmitz1@gmail.com>
Date: Tue, 12 Jan 2016 17:00:05 +0100
Subject: gr-utils: Update error message

Prevent people from running into the problem that "import pylab" doesn't work because python tkinter is not installed.
For example on a fresh Ubuntu or Mint system it is not enough to install python-matplotlib.
However, the true error message:
"ImportError: No module named _tkinter, please install the python-tk package"
is obfuscated towards the user.

Another good option would be to not catch this import error but just show the true error message from python to the user.
---
 gr-utils/python/utils/plot_fft_base.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'gr-utils/python')

diff --git a/gr-utils/python/utils/plot_fft_base.py b/gr-utils/python/utils/plot_fft_base.py
index 4afdc3a360..c4bc484d97 100755
--- a/gr-utils/python/utils/plot_fft_base.py
+++ b/gr-utils/python/utils/plot_fft_base.py
@@ -30,7 +30,7 @@ except ImportError:
 try:
     from pylab import *
 except ImportError:
-    print "Please install Matplotlib to run this script (http://matplotlib.sourceforge.net/)"
+    print "Please install Python Matplotlib (http://matplotlib.sourceforge.net/) and Python TkInter https://wiki.python.org/moin/TkInter to run this script"
     raise SystemExit, 1
 
 from optparse import OptionParser
-- 
cgit v1.2.3