GRC and dynamically created message ports

Hi all,

I am working on a simple network stack like block, or call it message
multiplexer. I want to dynamically create message ports of different
types (think unicast and broadcast connections).

As for as I see, the current implementation does not allow this as

  • the keys to uniquely identify message ports are their names, in
    contrast to numbers as for the other ports. The algorithm to remove and
    insert, however, expects numbers as in

def insert_port(get_ports, get_port, key):
prev_port = get_port(str(int(key)-1))

  • Multiple varying ports are not working. The first one is OK the others
    get deleted. This is due to the ‘master_ports’ selection and the
    insertion logic.

I made some changes and, at least for me, everything is working, but I
don’t know if this is supposed to be fixed like this.

It would be great if someone could have a look at it

I used this block definition for testing

and I don’t experience this issue


Dipl.-Inform. Bastian B.
Institute of Computer Science
University of Innsbruck, Austria
Phone: +43 512 507-53288 / Fax: -53079