RoboMaster-SDK icon indicating copy to clipboard operation
RoboMaster-SDK copied to clipboard

KeyError: 'broadcast' when update to sdk robomaster-0.1.1.65

Open tianb03 opened this issue 3 years ago • 3 comments

I have updated to robomaster-0.1.1.65, in ubuntu 20.04 through pip3 install --upgrade robomaster

And also git pull the source code to test the examples.

Seems now I cannot execute all the scripts in multi_drone cos it will report KeyError: 'broadcast' when retrieve the broadcast address from ipinfo. In tool.py line 106.

So I downgraded to robomaster-0.1.1.63.

tianb03 avatar Nov 01 '21 10:11 tianb03

In Ubuntu 21.10 and robomaster-0.1.1.65 I also got the same error:

Traceback (most recent call last): File "/home/drezew/tmp/drones/main.py", line 86, in multi_drone.initialize(robot_num=2) File "/home/drezew/.pyenv/versions/drones/lib/python3.8/site-packages/multi_robomaster/multi_robot.py", line 272, in initialize self._robot_host_list = self._client.scan_multi_robot(robot_num) File "/home/drezew/.pyenv/versions/drones/lib/python3.8/site-packages/multi_robomaster/tool.py", line 320, in scan_multi_robot return self._conn.scan_multi_robot(num) File "/home/drezew/.pyenv/versions/drones/lib/python3.8/site-packages/multi_robomaster/tool.py", line 266, in scan_multi_robot robot_host_list = self._scan_host(num) File "/home/drezew/.pyenv/versions/drones/lib/python3.8/site-packages/multi_robomaster/tool.py", line 232, in _scan_host subnets, address = get_subnets() File "/home/drezew/.pyenv/versions/drones/lib/python3.8/site-packages/multi_robomaster/tool.py", line 106, in get_subnets broadcast = ipinfo['broadcast'] KeyError: 'broadcast'

drezew avatar Dec 05 '21 18:12 drezew

I have updated to robomaster-0.1.1.65, in ubuntu 20.04 through pip3 install --upgrade robomaster

And also git pull the source code to test the examples.

Seems now I cannot execute all the scripts in multi_drone cos it will report KeyError: 'broadcast' when retrieve the broadcast address from ipinfo. In tool.py line 106.

So I downgraded to robomaster-0.1.1.63.

@tianb03 So now,rmtt_ros can not use?

2197808908a avatar Nov 23 '22 14:11 2197808908a

I have updated to robomaster-0.1.1.65, in ubuntu 20.04 through pip3 install --upgrade robomaster And also git pull the source code to test the examples. Seems now I cannot execute all the scripts in multi_drone cos it will report KeyError: 'broadcast' when retrieve the broadcast address from ipinfo. In tool.py line 106. So I downgraded to robomaster-0.1.1.63.

@tianb03 So now,rmtt_ros can not use?

Simply downgrade to 0.1.1.63 and everything will be fine for rmtt_ros

tianb03 avatar Nov 24 '22 03:11 tianb03