You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

树莓派Ubuntu Server中Code-Server的ROS扩展激活失败及rclpy报错求助

Code-Server中ROS2扩展激活失败及rclpy导入错误问题

环境信息

  • 硬件:树莓派4
  • 系统:Ubuntu Server
  • 已验证:ROS2 Iron安装完成并可正常运行
  • IDE:Code-Server(因VSCode SSH连接不稳定改用)

问题描述

  1. 由于Code-Server扩展库无官方ROS扩展,从MarketPlace下载ms-iot.vscode-ros-0.9.5.vsix并成功安装,但激活时弹出错误提示:

    cannot activate the 'ros' extension because it depends on an unknown 'ms-vscode.cpptools' extension. on code server

  2. 尽管ROS扩展已显示安装并启用,编写Python ROS2节点时导入rclpy仍报错:
    No module named 'rclpy'
    

已尝试的无效解决方案

  • 卸载并重新安装ROS扩展
  • 多次重载Code-Server页面
  • 安装微软C/C++扩展的V1.17.5和V1.18.0版本

求可行的解决方法。

内容的提问来源于stack exchange,提问作者Navid Moghtaderi

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.07 23:34:56