Summary
The Webots bridge imports teleop.utils.jacobi_robot.JacobiRobot. That module imports matplotlib.pyplot at module import time, even though the Webots path does not use plotting.
On the current machine, user-site NumPy was upgraded to 2.5.0 while system Matplotlib was compiled against NumPy 1.x. The eager Matplotlib import caused the bridge to crash before any robot logic started.
Observed error
A module that was compiled using NumPy 1.x cannot be run in NumPy 2.5.0
ImportError: numpy.core.multiarray failed to import
Stack:
File ".../webots/controllers/ur3e_teleop_bridge/ur3e_teleop_bridge.py", line 17, in <module>
from teleop.utils.jacobi_robot import JacobiRobot
File ".../teleop/teleop/utils/jacobi_robot.py", line 3, in <module>
import matplotlib.pyplot as plt
Expected behavior
Importing JacobiRobot for non-visual servoing should not import Matplotlib.
Acceptance criteria
- Move
matplotlib.pyplot import into the visualization methods that actually use it.
from teleop.utils.jacobi_robot import JacobiRobot works without Matplotlib being importable.
- The Webots bridge starts without requiring a NumPy downgrade solely because of Matplotlib.
- Add or update a lightweight import test in
teleop if practical.
Temporary workaround
Downgrading user-site NumPy to <2 unblocked the local run:
python3 -m pip install --user --break-system-packages "numpy<2"
Summary
The Webots bridge imports
teleop.utils.jacobi_robot.JacobiRobot. That module importsmatplotlib.pyplotat module import time, even though the Webots path does not use plotting.On the current machine, user-site NumPy was upgraded to
2.5.0while system Matplotlib was compiled against NumPy 1.x. The eager Matplotlib import caused the bridge to crash before any robot logic started.Observed error
Stack:
Expected behavior
Importing
JacobiRobotfor non-visual servoing should not import Matplotlib.Acceptance criteria
matplotlib.pyplotimport into the visualization methods that actually use it.from teleop.utils.jacobi_robot import JacobiRobotworks without Matplotlib being importable.teleopif practical.Temporary workaround
Downgrading user-site NumPy to
<2unblocked the local run:python3 -m pip install --user --break-system-packages "numpy<2"