TypeError: 'NoneType' object is not iterable ( Path Planning Basics Course ( RRT))

Hi All,

Below error was thrown once I try to run artificial potential field in path planning (RRT) course. I am referring to the same code provided by the team construct. What could have been gone wrong?

[ERROR] [1626873692.543203, 101.326000]: bad callback: <function new_goal_callback at 0x7f5e241bd940>
Traceback (most recent call last):
File “/opt/ros/noetic/lib/python3/dist-packages/rospy/topics.py”, line 750, in _invoke_callback
cb(msg)
File “/home/user/catkin_ws/src/path_planning_course/unit5/scripts/unit5_exercise.py”, line 51, in new_goal_callback
attractive_field.data = [100 if x > 100 else int(x) for x in unbounded_attractive_field]
TypeError: ‘NoneType’ object is not iterable

nvm. I was naive. Solved.

Thanks