# Hier\_blocks2 error

**URL:** <https://www.ruby-forum.com/t/hier-blocks2-error/242987>\
**Category:** GNU Radio\
**Created:** [August 13, 2015, 8:39am UTC](https://www.ruby-forum.com/t/hier-blocks2-error/242987 "2015-08-13T08:39:33Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rafa\_F](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/958977/32.png) [@Rafa\_F](https://www.ruby-forum.com/u/Rafa_F)\
**Post date:** [August 13, 2015, 8:39am UTC](https://www.ruby-forum.com/t/hier-blocks2-error/242987/1 "2015-08-13T08:39:33Z")

</div>

I am using gnruadio 3.7.8. I have a module (python) which is working  
well  
for version 3.6.3. In made necessary changes so that it can work with  
gnuradio 3.7.8. However I am getting following error

File  
“/usr/local/lib/python2.7/dist-packages/gnuradio/gr/hier\_block2.py”,  
line 92, in **getattr**  
return getattr(self.\_impl, name)  
AttributeError: ‘hier\_block2\_sptr’ object has no attribute ‘\_hb’

I spent a lot of time to figure out this but could not resolve it, so I  
thought to get help from mailing list.

Is this a bug or I am doing something wrong?

---

<div class="post-metadata">

**Author:** ![bob\_wole](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/b4bc9f/32.png) [@bob\_wole](https://www.ruby-forum.com/u/bob_wole)\
**Post date:** [August 13, 2015, 9:18am UTC](https://www.ruby-forum.com/t/hier-blocks2-error/242987/2 "2015-08-13T09:18:41Z")

</div>

On 08/13/2015 08:38 AM, bob wole wrote:

> I spent a lot of time to figure out this but could not resolve it, so  
> I thought to get help from mailing list.
> 
> Is this a bug or I am doing something wrong?

What your seeing is the interface wrapper looking for an attribute in  
the wrapped instance ‘self.\_impl’ which used to be called ‘self.\_hb’. So  
it tries to lookup that first - and fails. Since both \_impl and \_hb are  
marked protected they should not be accessed from outside the wrapper  
directly (I remember some WXGUI code did that, but that has been fixed).  
In the gnuradio tree I can’t seem to find anything like this.

Can you check and see from where this Exception is raised from?

Sebastian
