discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Discuss-gnuradio] Change Hierarchical Blocks Import Method?


From: Dan CaJacob
Subject: [Discuss-gnuradio] Change Hierarchical Blocks Import Method?
Date: Fri, 14 Jun 2013 23:22:22 -0400

Would it be possible to change the way hierarchical blocks get imported?

Currently, they get called by execfile with their absolute file path, which makes sharing them brittle.  Since hierarchical blocks are expected to be in the .grc_gnuradio folder, would it be possible to add that to the PYTHONPATH (if it is not already) and treat the Hier blocks as modules in a Python Package like HierBlocks?  That way, importing a Hier block could be done like:

from HierBlocks import myHierBlock

GRC could generate import statements like the above instead of the current execfile, which is system/user specific.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]