Skip to content

fix(manip): judge gripper arrival by the open band, not the stillness threshold - #3870

Open
mustafab0 wants to merge 1 commit into
mb/grasp-02-no-motion-on-launchfrom
mb/grasp-03-gripper-open-band
Open

fix(manip): judge gripper arrival by the open band, not the stillness threshold#3870
mustafab0 wants to merge 1 commit into
mb/grasp-02-no-motion-on-launchfrom
mb/grasp-03-gripper-open-band

Conversation

@mustafab0

Copy link
Copy Markdown
Contributor

await_gripper_settle used settle_tolerance for two different questions: how little the jaws moved between polls, and how near the commanded target they stopped. A gripper driven to its mechanical stop always halts short of the extreme — the real xArm rests at 0.988 of a nominal 850 count — so opening an already-open gripper moved nothing, could never "arrive", and timed out with gripper did not settle within 3.00s.

Arrival is now its own tolerance. The open path passes open_tolerance, the band that already decides whether where the jaws stopped counts as open. The close path keeps settle_tolerance, where an exact arrival at closed_position is precisely the signal that the jaws closed on nothing.

This kills a hack rather than porting it: the branch this stack re-derives from papered over the same bug from the other end with a per-blueprint grasp_verification={"settle_tolerance": 0.01} override, chasing the gap between 0.995 and 1.0 instead of naming it. That override does not exist here and is not reintroduced anywhere in the stack.

Third of nine in the xArm grasping re-landing stack.

… threshold

await_gripper_settle used settle_tolerance for two different questions: how
little the jaws moved between polls, and how near the commanded target they
stopped. A gripper driven to its mechanical stop always halts short of the
extreme -- the real xArm rests at 0.988 of a nominal 850 count -- so opening an
already-open gripper moved nothing, could never "arrive", and timed out with
"gripper did not settle within 3.00s".

Arrival is now its own tolerance. The open path passes open_tolerance, the band
that already decides whether where the jaws stopped counts as open. The close
path keeps settle_tolerance, where an exact arrival at closed_position is
precisely the signal that the jaws closed on nothing.
@greptile-apps

greptile-apps Bot commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This change lets open gripper commands use the configured open band for arrival while keeping the tighter stillness threshold for detecting stopped motion. Direct runtime checks confirmed that a gripper resting at 0.988 for a 1.0 open target now settles and is accepted; a stable 0.800 reading remains rejected, and a close that stops on an object retains its prior successful behavior.

T-Rex validation blocked

Focused pytest collection could not start because the dotenv Python package is missing while importing dimos/conftest.py. The direct runtime harness completed the relevant open and close behavior checks without that dependency.

Confidence Score: 5/5

The gripper settling change is safe to merge based on direct execution of the corrected open-stop behavior and its important boundary and close-command regressions.

No defects were found. The executed harness compared the prior and updated behavior, confirmed the intended 0.988 open-stop acceptance, preserved rejection outside the open band, and preserved held-object close behavior.

Files Needing Attention: No files require changes. Focused pytest coverage remains unavailable until the missing dotenv package is available.

T-Rex T-Rex Logs

What T-Rex did

  • Ran a deterministic gripper settle validation harness against both revisions using recorded readbacks, and observed that before the change the open target 1.0 with stable 0.988 timed out at 0.20s and failed open verification; after the change the same readback settled at 0.10s and open_failure(...) returned None; a stable 0.800 open reading remained unaccepted, and a close sequence ending at held-object position 0.730 remained settled and accepted.
  • Attempted a focused pytest run but could not import dimos/conftest.py because python-dotenv was absent, blocking environment setup for the focused validation.

View all artifacts

T-Rex Ran code and verified through T-Rex

Reviews (1): Last reviewed commit: "fix(manip): judge gripper arrival by the..." | Re-trigger Greptile

@codecov

codecov Bot commented Sep 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

@@                       Coverage Diff                        @@
##           mb/grasp-02-no-motion-on-launch    #3870   +/-   ##
================================================================
  Coverage                            77.65%   77.65%           
================================================================
  Files                                 1323     1323           
  Lines                               125429   125440   +11     
  Branches                             10911    10911           
================================================================
+ Hits                                 97400    97413   +13     
+ Misses                               24886    24885    -1     
+ Partials                              3143     3142    -1     
Flag Coverage Δ
OS-ubuntu-24.04-arm 74.32% <100.00%> (+<0.01%) ⬆️
OS-ubuntu-latest 74.87% <100.00%> (+<0.01%) ⬆️
Py-3.10 74.86% <100.00%> (+<0.01%) ⬆️
Py-3.11 74.86% <100.00%> (?)
Py-3.12 74.86% <100.00%> (+<0.01%) ⬆️
Py-3.13 74.86% <100.00%> (+<0.01%) ⬆️
Py-3.14 74.86% <100.00%> (+0.54%) ⬆️
Py-3.14t 74.86% <100.00%> (?)
SelfHosted-Large 30.21% <15.78%> (-0.01%) ⬇️
SelfHosted-Linux 34.71% <15.78%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
dimos/manipulation/grasp_verification.py 97.64% <100.00%> (+0.02%) ⬆️
dimos/manipulation/pick_and_place_module.py 79.65% <ø> (ø)
dimos/manipulation/test_grasp_verification.py 100.00% <100.00%> (ø)
dimos/manipulation/test_pick_and_place_unit.py 100.00% <100.00%> (ø)

... and 5 files with indirect coverage changes

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions github-actions Bot added the ready-to-merge Required CI checks have passed on this PR label Sep 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-merge Required CI checks have passed on this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant