TwoWheelDev / gns3-converter

GNS3 Topology Converter
GNU General Public License v3.0
14 stars 13 forks source link

'NOTE' and 'SHAPE' elements of topology.net files are processed as devices #1

Closed anotherlousytag closed 10 years ago

anotherlousytag commented 10 years ago

The keys 'NOTE and 'SHAPE' do not exist in the dictionary dev_type so when device_typename() is passed either of these values it causes the below error.

_Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.4/bin/gns3-converter", line 9, in load_entry_point('gns3-converter==0.1.0', 'console_scripts', 'gns3-converter')() File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/gns3converter/main.py", line 42, in main (devices, conf) = gns3_conv.process_topology(sections, old_top) File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/gns3converter/converter.py", line 115, in process_topology topo.add_physical_item(instance, item) File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/gns3converter/topology.py", line 59, in add_physical_item (device_name, device_type) = self.device_typename(item) File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/gns3converter/topology.py", line 118, in device_typename name = item.replace('%s ' % dev_type[itemtype]['from'], '') KeyError: 'NOTE'