bitbots_main icon indicating copy to clipboard operation
bitbots_main copied to clipboard

deploy_robots.py cannot remove build folder

Open val-ba opened this issue 1 year ago • 1 comments

Summary

When trying to use the deploy_robots.py script with the following command ./scripts/deploy_robots.py donna -sb -p bitbots_quintic_walk the build directory cannot be removed. The command run is rm -rf ~/colcon_ws/build ~/colcon_ws/install ~/colcon_ws/log' exited=1> and if you run it directly on the robot it does not cause an error.

Expected behavior

It should just remove the directory.

Current behavior

This is the error message:

rm: cannot remove '/home/bitbots/colcon_ws/build/biped_interfaces' : Directory not empty Traceback (most recent call last): File "/homes/17vahl/colcon_ws/src/bitbots_meta/scripts/deploy/tasks/build.py", line 55, in _clean results = connections.run(cmd_clean, hide=hide_output()) File "/homes/17vahl/.local/lib/python3.10/site-packages/fabric/group.py", line 116, in run return self._do("run", *args, **kwargs) File "/homes/17vahl/.local/lib/python3.10/site-packages/fabric/group.py", line 282, in _do raise GroupException(results) fabric.exceptions.GroupException: {<Connection host=172.20.1.14 user=bitbots>: <UnexpectedExit: cmd='rm -rf ~/colcon_ws/build ~/colcon_ws/install ~/colcon_ws/log' exited=1>}

Steps to Reproduce

  1. Run ./scripts/deploy_robots.py donna -sb -p bitbots_quintic_walk

Possible Solution

val-ba avatar Jan 20 '25 11:01 val-ba

Note this only happens sometimes

Flova avatar Jan 20 '25 15:01 Flova

I also had this issue on my machine, it might not be due to the script, but general ubuntu things.

val-ba avatar Apr 17 '25 09:04 val-ba

This seems like an upstream issue.

Flova avatar Jun 03 '25 09:06 Flova

May it be because some things are build with sudo and we try to remove it without it?

val-ba avatar Jun 03 '25 13:06 val-ba

Should be a different error then

Flova avatar Jun 04 '25 12:06 Flova

@Flova Upstream of what?

jaagut avatar Jun 04 '25 16:06 jaagut

Us. I mostly think this might be some Ubuntu bug,

Flova avatar Jun 04 '25 18:06 Flova