# Gr\_modtool makexml bugs

**URL:** <https://www.ruby-forum.com/t/gr-modtool-makexml-bugs/239037>\
**Category:** GNU Radio\
**Created:** [February 9, 2014, 8:40am UTC](https://www.ruby-forum.com/t/gr-modtool-makexml-bugs/239037 "2014-02-09T08:40:16Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![musicdenotation](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ea666f/32.png) [@musicdenotation](https://www.ruby-forum.com/u/musicdenotation)\
**Post date:** [February 9, 2014, 8:40am UTC](https://www.ruby-forum.com/t/gr-modtool-makexml-bugs/239037/1 "2014-02-09T08:40:16Z")

</div>

Dear guru,  
This happens intermittently. Is this a bug?

Command: gr\_modtool makexml integer\_sink2  
Output: as below

Regards,  
activecat

$ gr\_modtool makexml integer\_sink2  
GNU Radio module name identified: activecat  
Warning: This is an experimental feature. Don’t expect any magic.  
Searching for matching files in lib/:  
Making GRC bindings for lib/integer\_sink2\_impl.cc…  
Traceback (most recent call last):  
File “/usr/local/bin/gr\_modtool”, line 41, in   
main()  
File “/usr/local/bin/gr\_modtool”, line 37, in main  
modtool.run()  
File  
“/usr/local/lib/python2.7/dist-packages/gnuradio/modtool/modtool\_makexml.py”,  
line 66, in run  
(params, iosig, blockname) = self.\_parse\_cc\_h(f)  
File  
“/usr/local/lib/python2.7/dist-packages/gnuradio/modtool/modtool\_makexml.py”,  
line 157, in \_parse\_cc\_h  
return (parser.read\_params(), parser.read\_io\_signature(), blockname)  
File  
“/usr/local/lib/python2.7/dist-packages/gnuradio/modtool/parser\_cc\_block.py”,  
line 82, in read\_io\_signature  
iosig\_match.group(‘intype’))  
File  
“/usr/local/lib/python2.7/dist-packages/gnuradio/modtool/parser\_cc\_block.py”,  
line 47, in \_figure\_out\_iotype\_and\_vlen  
return {‘type’: [\_typestr\_to\_iotype(x) for x in typestr.split(’,’)],  
File  
“/usr/local/lib/python2.7/dist-packages/gnuradio/modtool/parser\_cc\_block.py”,  
line 55, in \_typestr\_to\_iotype  
return self.type\_trans(type\_match.group(1))  
File  
“/usr/local/lib/python2.7/dist-packages/gnuradio/modtool/modtool\_makexml.py”,  
line 132, in \_type\_translate  
if p\_type in (‘int’,) and default\_v[:2].lower() == ‘0x’:  
TypeError: ‘NoneType’ object has no attribute ‘ **getitem** ’

---

<div class="post-metadata">

**Author:** ![activecat\_k](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/c57346/32.png) [@activecat\_k](https://www.ruby-forum.com/u/activecat_k)\
**Post date:** [February 9, 2014, 6:20pm UTC](https://www.ruby-forum.com/t/gr-modtool-makexml-bugs/239037/2 "2014-02-09T18:20:49Z")

</div>

On 08.02.2014 23:38, Activecat wrote:

> Dear guru,  
> This happens intermittently. Is this a bug?

Probably. That said, makexml is the most tricky part of modtool. This  
might be triggered by invalid code, although the error message suggests  
otherwise.

Can you please post GNU Radio version, the include file and the \_impl.cc  
file that triggers this.

MB

---

<div class="post-metadata">

**Author:** ![activecat\_k](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/c57346/32.png) [@activecat\_k](https://www.ruby-forum.com/u/activecat_k)\
**Post date:** [February 10, 2014, 2:25am UTC](https://www.ruby-forum.com/t/gr-modtool-makexml-bugs/239037/3 "2014-02-10T02:25:43Z")

</div>

Dear Martin,

Let’s refer related files as attached, thanks.

List of attached files:  
integer\_source.h  
integer\_source\_impl.h  
integer\_source\_impl.cc  
error\_message (text file)

Regards,  
activecat
