Skip to content

Commit

Permalink
fix small error in pybullet-coffee; able to reproduce the assert self…
Browse files Browse the repository at this point in the history
…._held_obj_to_base_link when there are more than one tasks
  • Loading branch information
yichao-liang committed Jun 29, 2024
1 parent 06e5475 commit 057e25d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion predicators/envs/pybullet_coffee.py
Original file line number Diff line number Diff line change
Expand Up @@ -444,7 +444,8 @@ def _reset_state(self, state: State) -> None:

# Create liquid in cups.
for liquid_id in self._cup_to_liquid_id.values():
p.removeBody(liquid_id, physicsClientId=self._physics_client_id)
if liquid_id is not None:
p.removeBody(liquid_id, physicsClientId=self._physics_client_id)
self._cup_to_liquid_id.clear()

for cup in state.get_objects(self._cup_type):
Expand Down

0 comments on commit 057e25d

Please sign in to comment.