I am using ros 2 humble in ubuntu 22.04.
I got this error while trying to update the rosdep
autosys5@autosys5-Latitude-5430:~$ rosdep update
reading in sources list data from /etc/ros/rosdep/sources.list.d
ERROR: unable to process source [file:///usr/share/python3-rosdep2/debian.yaml]:
<urlopen error [Errno 2] No such file or directory: '/usr/share/python3-rosdep2/debian.yaml'> (file:///usr/share/python3-rosdep2/debian.yaml)
Hit https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/osx-homebrew.yaml
Hit https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/base.yaml
Hit https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/python.yaml
Hit https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/ruby.yaml
Hit https://raw.githubusercontent.com/ros/rosdistro/master/releases/fuerte.yaml
ERROR: Rosdep experienced an error: module 'rosdistro' has no attribute 'get_index_url'
Please go to the rosdep page [1] and file a bug report with the stack trace below.
[1] : http://www.ros.org/wiki/rosdep
rosdep version: 0.22.2
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/rosdep2/main.py", line 146, in rosdep_main
exit_code = _rosdep_main(args)
File "/usr/lib/python3/dist-packages/rosdep2/main.py", line 444, in _rosdep_main
return _no_args_handler(command, parser, options, args)
File "/usr/lib/python3/dist-packages/rosdep2/main.py", line 453, in _no_args_handler
return command_handlers[command](options)
File "/usr/lib/python3/dist-packages/rosdep2/main.py", line 665, in command_update
update_sources_list(success_handler=update_success_handler,
File "/usr/lib/python3/dist-packages/rosdep2/sources_list.py", line 489, in update_sources_list
print('Query rosdistro index %s' % get_index_url())
File "/usr/lib/python3/dist-packages/rosdep2/rosdistrohelper.py", line 62, in get_index_url
_check_cache()
File "/usr/lib/python3/dist-packages/rosdep2/rosdistrohelper.py", line 55, in _check_cache
if _RDCache.index_url != rosdistro.get_index_url():
AttributeError: module 'rosdistro' has no attribute 'get_index_url'
I am not sure why I am getting this error. Could someone help me resolve this issue?
I tried to removing rm -r ~/.ros/rosdep and updating rosdep update.
I also tried rm -r ~/.ros/rosdep
`