Skip to content

[start_ursim] Offer updating g5 urcap - #543

Merged
urfeex merged 4 commits into
UniversalRobots:masterfrom
urfeex:update_urcap
Aug 3, 2026
Merged

[start_ursim] Offer updating g5 urcap#543
urfeex merged 4 commits into
UniversalRobots:masterfrom
urfeex:update_urcap

Conversation

@urfeex

@urfeex urfeex commented Jul 31, 2026

Copy link
Copy Markdown
Member

Before that change, the script would automatically pull the latest version putting it aside the currently existing one. That would have unexpected side-effects.

With this change we check whether there is an externalcontrol urcap with a different version present already. In that case the user is prompted for updating it which will remove the old version.


Note

Low Risk
Changes only affect the local start_ursim.sh URCap download path for non-PolyScopeX URSim; no production robot or auth logic is touched.

Overview
PolyScope 5 / CB3 URSim startup no longer downloads a newer externalcontrol-*.jar alongside an existing jar when the resolved version file is missing. It now detects other externalcontrol-*.jar files in URCAP_STORAGE and asks whether to remove them and install the target version.

A new prompt_urcap_update helper drives that choice with a [y/N] prompt, URCAP_PROMPT_TIMEOUT (default 10s), and timeout behavior that keeps the installed URCap. Declining skips the download; accepting removes matching jars before/after a successful curl fetch.

Bats tests cover the prompt (yes/no/empty/timeout) and main -t flows for fresh install, decline, and accept.

Reviewed by Cursor Bugbot for commit 8ee78ad. Bugbot is set up for automated code reviews on this repo. Configure here.

Before that change, the script would automatically pull the latest
version putting it aside the currently existing one. That would have
unexpected side-effects.

With this change we check whether there is an externalcontrol urcap with
a different version present already. In that case the user is prompted
for updating it which will remove the old version.
@urfeex
urfeex requested a review from a team July 31, 2026 09:53
@urfeex urfeex added the bugfix label Jul 31, 2026
@codecov

codecov Bot commented Jul 31, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.06%. Comparing base (c5d1e26) to head (8ee78ad).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #543      +/-   ##
==========================================
- Coverage   79.14%   79.06%   -0.09%     
==========================================
  Files         115      115              
  Lines        6776     6801      +25     
  Branches     3000     3000              
==========================================
+ Hits         5363     5377      +14     
- Misses       1042     1051       +9     
- Partials      371      373       +2     
Flag Coverage Δ
check_version_ur10-3.15.8 11.31% <ø> (-0.36%) ⬇️
check_version_ur10e-10.11.0 11.12% <ø> (-0.05%) ⬇️
check_version_ur10e-5.15.2 11.17% <ø> (-0.36%) ⬇️
check_version_ur12e-10.12.1 11.12% <ø> (ø)
check_version_ur12e-5.25.1 11.31% <ø> (-0.05%) ⬇️
check_version_ur15-10.12.1 11.12% <ø> (ø)
check_version_ur15-5.25.1 11.31% <ø> (ø)
check_version_ur16e-10.12.1 11.12% <ø> (-0.05%) ⬇️
check_version_ur16e-5.25.1 11.12% <ø> (ø)
check_version_ur18-10.12.1 11.12% <ø> (ø)
check_version_ur18-5.25.1 11.12% <ø> (-0.24%) ⬇️
check_version_ur20-10.12.1 11.12% <ø> (-0.05%) ⬇️
check_version_ur20-5.25.1 11.31% <ø> (-0.05%) ⬇️
check_version_ur3-3.14.3 11.57% <ø> (-1.33%) ⬇️
check_version_ur30-10.12.1 11.12% <ø> (-0.05%) ⬇️
check_version_ur30-5.25.1 11.12% <ø> (-0.47%) ⬇️
check_version_ur3e-10.11.0 11.12% <ø> (-0.10%) ⬇️
check_version_ur3e-5.9.4 11.31% <ø> (-0.63%) ⬇️
check_version_ur5-3.15.8 11.35% <ø> (-1.55%) ⬇️
check_version_ur5e-10.11.0 11.21% <ø> (+0.04%) ⬆️
check_version_ur5e-5.12.8 11.17% <ø> (-0.41%) ⬇️
check_version_ur7e-10.11.0 11.17% <ø> (ø)
check_version_ur7e-5.22.2 11.12% <ø> (-0.24%) ⬇️
check_version_ur8long-10.12.1 11.12% <ø> (-0.10%) ⬇️
check_version_ur8long-5.25.1 11.12% <ø> (-0.24%) ⬇️
python_scripts 75.90% <ø> (ø)
start_ursim 85.00% <100.00%> (-0.10%) ⬇️
ur5-3.14.3 74.40% <ø> (-0.33%) ⬇️
ur5e-10.11.0 69.16% <ø> (-0.30%) ⬇️
ur5e-10.12.0 70.36% <ø> (-0.15%) ⬇️
ur5e-10.7.0 68.57% <ø> (-0.25%) ⬇️
ur5e-5.9.4 75.21% <ø> (-0.22%) ⬇️
ur7e-10.13.0 70.44% <ø> (-0.08%) ⬇️

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

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

Comment thread scripts/start_ursim.sh

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

Reviewed by Cursor Bugbot for commit c228b87. Configure here.

Comment thread scripts/start_ursim.sh Outdated
@mergify

mergify Bot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Tick the box to add this pull request to the merge queue (same as @mergifyio queue).

  • Queue this pull request

@urfeex
urfeex merged commit 3ca5f04 into UniversalRobots:master Aug 3, 2026
53 of 64 checks passed
@urfeex
urfeex deleted the update_urcap branch August 3, 2026 12:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants