John,

Thank you for the fix. I created a patch for the gnuradio.SlackBuild and re-built gnuradio. No more strange menus. Everything else seems to be working just fine. The patch was added to the SlackBuild just after the line:
cd $PRGNAM-$VERSION

with the following line:
patch -p0 <$CWD/BlockTreeWindow.py.patch

Sorry for the weird patch.  It works, that's all.

Thanks again!

Fred

On 11/11/2015 08:49 PM, John Coppens wrote:
On Wed, 11 Nov 2015 13:42:35 -0800
Johnathan Corgan <[email protected]> wrote:

On Wed, Nov 11, 2015 at 6:07 AM, Frederick E. Stevens <[email protected]
wrote:

As I recall, this behavior has cropped up in 3.6 and 3.7 of gnuradio for
me but it wasn't much of an issue at the time.

This afternoon, I had some time to trace where the problem originated. It
seems that on some systems (mine ;) the test for isinstance(category, str)
doesn't work, as the type of category is actually 'unicode'. (This is
on Slackware 14.1 + some mods from -current).

I changed to isinstance(category, basestring), which captures both str
and unicode.

(This is around line 130 in BlockTreeWindow.py)

I've submitted a bug report for this - which was accepted.

John

_______________________________________________
Discuss-gnuradio mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

--- grc/gui/BlockTreeWindow.py	2015-10-31 12:33:23.000000000 -0500
+++ grc/gui/BlockTreeWindow.py.new	2015-11-12 10:15:51.272620638 -0600
@@ -125,7 +125,8 @@
         if treestore is None: treestore = self.treestore
         if categories is None: categories = self._categories
 
-        if isinstance(category, str): category = category.split('/')
+#        if isinstance(category, str): category = category.split('/')
+        if isinstance(category, basestring): category = category.split('/')
         category = tuple(filter(lambda x: x, category)) #tuple is hashable
         #add category and all sub categories
         for i, cat_name in enumerate(category):
_______________________________________________
Discuss-gnuradio mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Reply via email to