@uipath/skills 1.207.0 → 1.208.0-preview.2389

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (214) hide show
  1. package/.claude-plugin/marketplace.json +1 -1
  2. package/.claude-plugin/plugin.json +1 -1
  3. package/.cursor-plugin/plugin.json +1 -1
  4. package/CODEOWNERS +13 -3
  5. package/README.md +6 -5
  6. package/assets/skill-status.json +10 -2
  7. package/assets/uip-browser-commands-snapshot.json +55 -3
  8. package/assets/uip-browser-host-served.json +2 -1
  9. package/assets/uip-catalog-snapshot.json +83 -3
  10. package/commands/install-permissions.md +8 -10
  11. package/package.json +3 -2
  12. package/skills/uipath-a2a-agents/SKILL.md +111 -0
  13. package/skills/uipath-a2a-agents/references/authentication-guide.md +61 -0
  14. package/skills/uipath-a2a-agents/references/troubleshooting-guide.md +98 -0
  15. package/skills/uipath-a2a-agents/references/updating-agents-guide.md +64 -0
  16. package/skills/uipath-activity-migrator/SKILL.md +31 -27
  17. package/skills/uipath-activity-migrator/references/acquisition-guide.md +91 -35
  18. package/skills/uipath-activity-migrator/references/build-verification-guide.md +1 -1
  19. package/skills/uipath-activity-migrator/references/packages/gsuite-guide.md +2 -2
  20. package/skills/uipath-activity-migrator/references/packages/mail-guide.md +1 -1
  21. package/skills/uipath-activity-migrator/references/packages/uia-guide.md +1 -1
  22. package/skills/uipath-activity-migrator/references/tool-behavior-guide.md +18 -8
  23. package/skills/uipath-activity-migrator/scripts/ensure-migrator.mjs +114 -49
  24. package/skills/uipath-activity-migrator/scripts/summarize-sarif.mjs +6 -0
  25. package/skills/uipath-admin/references/tenant-management.md +3 -3
  26. package/skills/uipath-admin/references/tenants-commands.md +2 -2
  27. package/skills/uipath-agents/SKILL.md +9 -4
  28. package/skills/uipath-agents/references/coded/capabilities/datafabric.md +8 -5
  29. package/skills/uipath-agents/references/coded/lifecycle/setup.md +2 -0
  30. package/skills/uipath-agents/references/coded/quickstart.md +1 -1
  31. package/skills/uipath-agents/references/lowcode/agent-definition.md +11 -1
  32. package/skills/uipath-agents/references/lowcode/capabilities/built-in-tools/analyze-attachments.md +2 -0
  33. package/skills/uipath-agents/references/lowcode/capabilities/built-in-tools/built-in-tools.md +5 -2
  34. package/skills/uipath-agents/references/lowcode/capabilities/escalation/escalation.md +8 -4
  35. package/skills/uipath-agents/references/lowcode/capabilities/guardrails/builtin-examples-guide.md +185 -0
  36. package/skills/uipath-agents/references/lowcode/capabilities/guardrails/byo-guide.md +12 -0
  37. package/skills/uipath-agents/references/lowcode/capabilities/guardrails/escalation-guide.md +6 -4
  38. package/skills/uipath-agents/references/lowcode/capabilities/guardrails/guardrails-recommend.md +2 -2
  39. package/skills/uipath-agents/references/lowcode/capabilities/guardrails/guardrails.md +15 -191
  40. package/skills/uipath-agents/references/lowcode/capabilities/inline-in-flow/inline-in-flow.md +5 -3
  41. package/skills/uipath-agents/references/lowcode/capabilities/integration-service/integration-service.md +12 -2
  42. package/skills/uipath-agents/references/lowcode/capabilities/process/process.md +66 -15
  43. package/skills/uipath-agents/references/lowcode/capabilities/process/solution-files.md +4 -0
  44. package/skills/uipath-agents/references/lowcode/critical-rules/critical-rules.md +2 -2
  45. package/skills/uipath-agents/references/lowcode/evaluations/runtime-eval-run.md +18 -18
  46. package/skills/uipath-agents/references/lowcode/lowcode.md +4 -2
  47. package/skills/uipath-agents/references/lowcode/project-lifecycle.md +8 -3
  48. package/skills/uipath-agents/references/lowcode/solution-resources.md +2 -2
  49. package/skills/uipath-aops/SKILL.md +1 -0
  50. package/skills/uipath-aops/references/discovery-flow.md +1 -1
  51. package/skills/uipath-aops/references/migration-guide.md +2 -1
  52. package/skills/uipath-api-workflow/SKILL.md +6 -4
  53. package/skills/uipath-api-workflow/assets/templates/genai-model-call-example.json +143 -0
  54. package/skills/uipath-api-workflow/references/cli-reference.md +9 -9
  55. package/skills/uipath-api-workflow/references/connector-activity-discovery.md +12 -3
  56. package/skills/uipath-api-workflow/references/troubleshooting.md +1 -1
  57. package/skills/uipath-coded-apps/SKILL.md +20 -12
  58. package/skills/uipath-coded-apps/references/commands-reference.md +25 -2
  59. package/skills/uipath-coded-apps/references/create-action-app.md +28 -0
  60. package/skills/uipath-coded-apps/references/create-web-app.md +33 -1
  61. package/skills/uipath-coded-apps/references/dashboards/plugins/deploy/impl.md +3 -3
  62. package/skills/uipath-coded-apps/references/debug.md +1 -1
  63. package/skills/uipath-coded-apps/references/pack-publish-deploy.md +71 -22
  64. package/skills/uipath-coded-apps/references/public-coded-app.md +1 -1
  65. package/skills/uipath-coded-apps/references/widgets/decisions-and-reasons.md +194 -0
  66. package/skills/uipath-connector-builder/SKILL.md +34 -0
  67. package/skills/uipath-connector-builder/references/community-submit-guide.md +103 -0
  68. package/skills/uipath-connector-builder/references/scripts.md +174 -0
  69. package/skills/uipath-connector-builder/references/v4-flow.md +97 -0
  70. package/skills/uipath-genome/references/build-guide.md +2 -2
  71. package/skills/uipath-genome/references/completion-report-guide.md +7 -5
  72. package/skills/uipath-genome/references/configuration-questions-guide.md +8 -7
  73. package/skills/uipath-genome/references/execution-guide.md +33 -7
  74. package/skills/uipath-genome/references/execution-parts-guide.md +4 -3
  75. package/skills/uipath-genome/references/genome-reading-guide.md +24 -7
  76. package/skills/uipath-genome/references/offline-definition-workarounds-guide.md +1 -1
  77. package/skills/uipath-genome/references/open-items-guide.md +5 -4
  78. package/skills/uipath-genome/references/package-doc-errata-guide.md +21 -0
  79. package/skills/uipath-genome/references/prepare-guide.md +38 -2
  80. package/skills/uipath-genome/references/refactor-guide.md +6 -4
  81. package/skills/uipath-genome/references/selector-translation-desktop-guide.md +8 -62
  82. package/skills/uipath-genome/references/selector-translation-guide.md +51 -51
  83. package/skills/uipath-genome/references/selector-translation-sap-guide.md +22 -39
  84. package/skills/uipath-genome/references/selector-translation-web-guide.md +32 -86
  85. package/skills/uipath-genome/references/source-frameworks-guide.md +1 -1
  86. package/skills/uipath-genome/references/source-migration-guide.md +9 -3
  87. package/skills/uipath-genome/references/test-execution-guide.md +2 -2
  88. package/skills/uipath-genome/references/transactional-execution-guide.md +2 -2
  89. package/skills/uipath-genome/references/ui-target-migration-guide.md +4 -2
  90. package/skills/uipath-governance/SKILL.md +1 -1
  91. package/skills/uipath-governance/references/access-policy/resource-lookup-guide.md +2 -2
  92. package/skills/uipath-governance/references/aops-policy/aops-policy-overview-guide.md +1 -1
  93. package/skills/uipath-governance/references/cli-cheatsheet.md +16 -16
  94. package/skills/uipath-ixp/references/cli-reference.md +3 -1
  95. package/skills/uipath-maestro-bpmn/SKILL.md +1 -1
  96. package/skills/uipath-maestro-bpmn/references/bpmn-runtime.md +1 -1
  97. package/skills/uipath-maestro-bpmn/references/evaluate.md +3 -3
  98. package/skills/uipath-maestro-case/SKILL.md +3 -3
  99. package/skills/uipath-maestro-case/examples/CreditDecision.case.ts +9 -2
  100. package/skills/uipath-maestro-case/references/case-runtime.md +47 -0
  101. package/skills/uipath-maestro-flow/references/author.md +1 -1
  102. package/skills/uipath-maestro-flow/references/evaluate.md +3 -3
  103. package/skills/uipath-maestro-flow/references/event-trigger.md +4 -0
  104. package/skills/uipath-mcp-servers/SKILL.md +28 -7
  105. package/skills/uipath-mcp-servers/references/connections-guide.md +13 -0
  106. package/skills/uipath-mcp-servers/references/guardrails-guide.md +66 -0
  107. package/skills/uipath-mcp-servers/references/troubleshooting-guide.md +23 -0
  108. package/skills/uipath-ontology/SKILL.md +3 -3
  109. package/skills/uipath-ontology/references/artifacts-guide.md +1 -1
  110. package/skills/uipath-ontology/references/owl-patterns-guide.md +1 -1
  111. package/skills/uipath-planner/SKILL.md +17 -7
  112. package/skills/uipath-planner/assets/templates/agent-sdd-template.md +27 -3
  113. package/skills/uipath-planner/assets/templates/api-workflow-sdd-template.md +5 -1
  114. package/skills/uipath-planner/assets/templates/bpmn-sdd-template.md +5 -1
  115. package/skills/uipath-planner/assets/templates/coded-app-sdd-template.md +5 -1
  116. package/skills/uipath-planner/assets/templates/component-genome-template.md +3 -3
  117. package/skills/uipath-planner/assets/templates/flow-sdd-template.md +5 -1
  118. package/skills/uipath-planner/assets/templates/process-genome-template.md +4 -4
  119. package/skills/uipath-planner/assets/templates/rpa-sdd-template.md +5 -1
  120. package/skills/uipath-planner/references/author/author-guide.md +4 -5
  121. package/skills/uipath-planner/references/author/genome-from-sdd-guide.md +3 -3
  122. package/skills/uipath-planner/references/design/case-product-guide.md +1 -1
  123. package/skills/uipath-planner/references/design/case-review-and-conformance-guide.md +4 -1
  124. package/skills/uipath-planner/references/design/design-guide.md +2 -2
  125. package/skills/uipath-planner/references/design/scope-recommendation-guide.md +1 -1
  126. package/skills/uipath-planner/references/design/sdd-writing-guide.md +5 -7
  127. package/skills/uipath-planner/references/edit/edit-guide.md +2 -2
  128. package/skills/uipath-planner/references/extract/extract-guide.md +34 -22
  129. package/skills/uipath-planner/references/extract/uipath-non-rpa-signals-guide.md +12 -5
  130. package/skills/uipath-planner/references/extract/uipath-rpa-signals-guide.md +2 -2
  131. package/skills/uipath-planner/references/extract/uipath-source-guide.md +9 -4
  132. package/skills/uipath-planner/references/interview/interview-guide.md +11 -11
  133. package/skills/uipath-planner/references/shared/defect-verification-guide.md +2 -2
  134. package/skills/uipath-planner/references/shared/extracted-genome-guide.md +16 -11
  135. package/skills/uipath-planner/references/shared/extraction-parts-guide.md +19 -12
  136. package/skills/uipath-planner/references/shared/genome-format-guide.md +19 -85
  137. package/skills/uipath-planner/references/shared/genome-questions-guide.md +51 -0
  138. package/skills/uipath-planner/references/shared/multi-skill-patterns-guide.md +11 -0
  139. package/skills/uipath-planner/references/shared/open-questions-guide.md +1 -1
  140. package/skills/uipath-planner/references/shared/plan-and-tasks-format.md +1 -1
  141. package/skills/uipath-planner/references/shared/process-genome-sections-guide.md +28 -0
  142. package/skills/uipath-planner/references/shared/sdd-from-genome-guide.md +1 -1
  143. package/skills/uipath-planner/references/shared/skill-mapping-guide.md +5 -0
  144. package/skills/uipath-planner/references/shared/tenant-library-search-guide.md +9 -9
  145. package/skills/uipath-planner/references/shared/transactional-shape-guide.md +3 -3
  146. package/skills/uipath-planner/scripts/case-sdd-check.mjs +68 -1
  147. package/skills/uipath-planner/scripts/check-genome.mjs +70 -6
  148. package/skills/uipath-planner/scripts/scope-check.mjs +22 -2
  149. package/skills/uipath-platform/SKILL.md +36 -25
  150. package/skills/uipath-platform/references/cli-freeze-guide.md +61 -0
  151. package/skills/uipath-platform/references/data-fabric/data-fabric.md +7 -3
  152. package/skills/uipath-platform/references/integration-service/integration-service.md +1 -1
  153. package/skills/uipath-platform/references/integration-service/triggers.md +32 -0
  154. package/skills/uipath-platform/references/licensing/folder-outcome-billing.md +121 -0
  155. package/skills/uipath-platform/references/licensing/licensing.md +11 -6
  156. package/skills/uipath-platform/references/licensing/user-usage-topups.md +236 -0
  157. package/skills/uipath-platform/references/llmgateway/custom-connector/custom-connector-guide.md +6 -4
  158. package/skills/uipath-platform/references/orchestrator/api-limits.md +1 -1
  159. package/skills/uipath-platform/references/orchestrator/resources.md +8 -5
  160. package/skills/uipath-platform/references/orchestrator/run-jobs.md +4 -0
  161. package/skills/uipath-platform/references/orchestrator/setup-environment.md +5 -3
  162. package/skills/uipath-platform/references/orchestrator/tenant-admin.md +9 -6
  163. package/skills/uipath-platform/references/orchestrator/triggers-and-webhooks.md +8 -4
  164. package/skills/uipath-platform/references/orchestrator/work-with-storage.md +31 -8
  165. package/skills/uipath-platform/references/traces/decisions.md +2 -0
  166. package/skills/uipath-platform/references/uip-commands.md +7 -5
  167. package/skills/uipath-review/references/rpa/rpa-review-checklist.md +1 -1
  168. package/skills/uipath-rpa/SKILL.md +5 -5
  169. package/skills/uipath-rpa/references/cli-reference.md +3 -3
  170. package/skills/uipath-rpa/references/common-pattern-card.md +7 -1
  171. package/skills/uipath-rpa/references/debugging.md +4 -2
  172. package/skills/uipath-rpa/references/execution-journeys-catalog.md +1 -1
  173. package/skills/uipath-rpa/references/legacy/selector-guide.md +0 -12
  174. package/skills/uipath-rpa/references/library-authoring-guide.md +5 -5
  175. package/skills/uipath-rpa/references/remote-session-guide.md +54 -8
  176. package/skills/uipath-rpa/references/tenant-library-search-guide.md +9 -9
  177. package/skills/uipath-rpa/references/testing-guide.md +2 -2
  178. package/skills/uipath-rpa/references/uia-policies-catalog.md +4 -2
  179. package/skills/uipath-rpa/references/xaml/common-pitfalls.md +2 -21
  180. package/skills/uipath-rpa/references/xaml/xaml-basics-and-rules.md +0 -1
  181. package/skills/uipath-rules/SKILL.md +20 -16
  182. package/skills/uipath-rules/references/drd-guide.md +333 -0
  183. package/skills/uipath-rules/references/failure-modes-guide.md +1 -1
  184. package/skills/uipath-solution/SKILL.md +7 -4
  185. package/skills/uipath-solution/references/activate-and-manage.md +57 -23
  186. package/skills/uipath-solution/references/develop-solution.md +98 -8
  187. package/skills/uipath-solution/references/pack-and-deploy.md +108 -29
  188. package/skills/uipath-solution/references/pack-build-guide.md +151 -0
  189. package/skills/uipath-solution/references/scenarios/failure-modes.md +20 -2
  190. package/skills/uipath-solution/references/scenarios/manual-edits.md +2 -1
  191. package/skills/uipath-solution/references/scenarios/shared-cloud-resource.md +1 -1
  192. package/skills/uipath-solution/references/scenarios.md +2 -1
  193. package/skills/uipath-solution/references/solution-overview.md +5 -4
  194. package/skills/uipath-troubleshoot/references/activity-packages/classic-activities/playbooks/queue-operation-failed.md +2 -2
  195. package/skills/uipath-troubleshoot/references/investigation_guide.md +1 -0
  196. package/skills/uipath-troubleshoot/references/products/agents/playbooks/context-grounding-index-not-found.md +2 -1
  197. package/skills/uipath-troubleshoot/references/products/agents/playbooks/guardrail-violation.md +5 -3
  198. package/skills/uipath-troubleshoot/references/products/agents/playbooks/input-schema-validation-failure.md +2 -1
  199. package/skills/uipath-troubleshoot/references/products/agents/playbooks/is-connection-disabled.md +2 -2
  200. package/skills/uipath-troubleshoot/references/products/agents/playbooks/is-invalid-credentials.md +3 -5
  201. package/skills/uipath-troubleshoot/references/products/agents/playbooks/is-invalid-element-instance.md +2 -2
  202. package/skills/uipath-troubleshoot/references/products/agents/playbooks/llm-insufficient-information.md +2 -3
  203. package/skills/uipath-troubleshoot/references/products/api-workflows/playbooks/never-ran-no-job.md +1 -1
  204. package/skills/uipath-troubleshoot/references/products/api-workflows/playbooks/platform-limits.md +1 -1
  205. package/skills/uipath-troubleshoot/references/products/coded-apps/overview.md +1 -0
  206. package/skills/uipath-troubleshoot/references/products/coded-apps/playbooks/api-401-after-login.md +1 -1
  207. package/skills/uipath-troubleshoot/references/products/coded-apps/playbooks/api-403-folder-permission.md +2 -2
  208. package/skills/uipath-troubleshoot/references/products/coded-apps/playbooks/invalid-scope.md +1 -1
  209. package/skills/uipath-troubleshoot/references/products/coded-apps/playbooks/redirect-uri-mismatch.md +1 -1
  210. package/skills/uipath-troubleshoot/references/products/orchestrator/investigation_guide.md +4 -4
  211. package/skills/uipath-troubleshoot/references/products/orchestrator/overview.md +2 -2
  212. package/skills/uipath-troubleshoot/references/products/orchestrator/playbooks/platform-incident-correlation.md +2 -2
  213. package/version-manifest.json +2 -2
  214. package/skills/uipath-genome/references/selector-matching-guide.md +0 -60
@@ -1,21 +1,58 @@
1
1
  # Acquisition Guide
2
2
 
3
- How the skill obtains, caches, verifies, and updates `UiPath.Upgrade.exe`. The script `scripts/ensure-migrator.mjs` implements this, run with `node`; read here when it fails or the user asks where the tool lives. Nothing is downloaded without the user's choice (SKILL.md Rule 15): a plain run only locates and verifies, `--install` downloads.
3
+ How the skill finds and verifies the Activity Migrator: Helm's, through `uip`, else the standalone `UiPath.Upgrade.exe` from the public archive. The script `scripts/ensure-migrator.mjs` implements this, run with `node`; read here when it fails or the user asks where the tool lives. Nothing is downloaded without the user's choice (SKILL.md Rule 15): a migrator from `uip` needs no download, and for the archive a plain run only locates and verifies, `--install` downloads.
4
4
 
5
5
  ## What ships
6
6
 
7
7
  | Item | Value |
8
8
  |---|---|
9
- | Public download | `https://download.uipath.com/upgrade/UiPath.Upgrade.Cli.zip` |
9
+ | Helm | The migrator ships inside every Windows Helm and runs from Helm's folder with Helm's DLLs: `UiPath.Upgrade.exe analyze\|upgrade\|bulk\|version <args>`, next to `UiPath.Studio.Helm.exe`, is Helm's own apphost under another name, and `uip` runs it (a Helm without it runs the migrator as `UiPath.Studio.Helm.exe migrate <verb> <args>`). `uip` installs Helm with its RPA tool, from the npm packages `@uipath/studio-helm-win32-x64` and `@uipath/studio-helm-win32-arm64`, which are optional dependencies of `@uipath/rpa-tool`. The Studio MSI carries the same Helm |
10
+ | `uip` commands | `uip rpa project migrate analyze\|upgrade\|bulk\|version <args>` hands its arguments to Helm's migrator unchanged. stdout, stderr and the exit code are the migrator's; stdout is SARIF with `--output-format sarif`. The commands take no `uip` options of their own (no `--format`, `--output`, `--verbose`): everything goes to the migrator. There is no install step |
11
+ | Public download | `https://download.uipath.com/upgrade/UiPath.Upgrade.Cli.zip`, the standalone `UiPath.Upgrade.exe`. The fallback when `uip` cannot supply the migrator |
10
12
  | Also available from | Automation Cloud → Help → Resources → Downloads → Activity Migrator Tool; Customer Portal (`https://customerportal.uipath.com/`) |
11
13
  | Archive | Zip with `UiPath.Upgrade.exe` at the archive root and extensions under `Extensions/<Name>/` |
12
- | Runtime | Windows, .NET 8: `Microsoft.NETCore.App 8.x` and `Microsoft.WindowsDesktop.App 8.x` (the .NET Desktop Runtime 8 installer provides both) |
13
- | Version | `UiPath.Upgrade.exe version` prints it (GA line `25.10.x`) |
14
- | Freshness signal | The URL is unversioned. The server's `Last-Modified` header is the only change signal; the script stores it, reports `update: true` when it changes, and re-downloads on an install run |
14
+ | Runtime | Through `uip`: Helm runs on the dotnet of the Robot or Studio install, else on the `dotnet` on `PATH` with `DOTNET_ROLL_FORWARD=LatestMajor`. `uip` resolves it; the script checks nothing. The archive: Windows and the .NET Desktop Runtime of the major version the build targets, recorded in `UiPath.Upgrade.runtimeconfig.json` next to the exe |
15
+ | Version | `uip rpa project migrate version` prints Helm's version as its last stdout line, e.g. `27.0.207-dev` or `26.10.x`; the SARIF `tool.driver.version` carries the same. `UiPath.Upgrade.exe version` prints the archive's own |
16
+ | Freshness signal | Through `uip`: the CLI version. The archive URL is unversioned; the server's `Last-Modified` header is the only change signal. The script stores it, reports `update: true` when it changes, and re-downloads on an install run |
17
+
18
+ Both forms take the same arguments and write the same SARIF and reports: exit code 0 whatever the outcome, extension options bind only as `--name=value`, reports go to `<PROJECT_DIR>/.upgrade` ([tool-behavior-guide.md](tool-behavior-guide.md)).
15
19
 
16
20
  Studio does not need to be installed. Opening the migrated project afterwards needs Studio 2024.10 or later.
17
21
 
18
- ## Cache layout
22
+ ## Helm through uip
23
+
24
+ The script runs `uip rpa project migrate version` without `UIPATH_STUDIO_PID` in its environment, with or without a flag. A version on the last stdout line means the migrator is there: the script reports `source: uip` and the skill runs `uip rpa project migrate <verb>` from then on. No environment variable is needed and nothing is downloaded.
25
+
26
+ | Setup | What to do | Helm comes from |
27
+ |---|---|---|
28
+ | Online | Nothing | The Helm npm package installed with `uip` |
29
+ | Internal npm registry (Artifactory, Nexus, …) | `.npmrc` routes the `@uipath` scope to the registry, as for the CLI itself | The same registry, at `uip` install time; nothing reaches `download.uipath.com` |
30
+ | Air-gapped, CLI installed from its air-gapped archive (Windows) | Nothing: the archive carries Helm | The archive |
31
+ | Studio installed (MSI) | Set `HELM_LOCAL_DIR` to the Studio folder that holds `UiPath.Studio.Helm.exe` | The Studio install, run in place |
32
+
33
+ The first call after a CLI update copies Helm into its run slot under `%LOCALAPPDATA%\UiPath\Helm`, which can take a minute or two; later calls start at once.
34
+
35
+ `uip`'s own failures print one JSON object, on stdout or stderr, and exit 1:
36
+
37
+ ```json
38
+ {"Result":"Failure","Message":"…","Instructions":"…","Code":"helm-missing"}
39
+ ```
40
+
41
+ | `uip` result | Cause | Script |
42
+ |---|---|---|
43
+ | `Code: not-windows` | Not a Windows machine | Fails with `not-windows` |
44
+ | `Code: helm-missing` | `uip` was installed without its optional Helm dependency (`--omit=optional`, `--no-optional`), or `HELM_LOCAL_DIR` names a folder without Helm. The fix: reinstall `uip` with its optional dependencies, or correct `HELM_LOCAL_DIR` | Falls back to the archive |
45
+ | An unknown-command error | A `uip` released before `project migrate`. The fix: update the CLI (`uip update`) | Falls back to the archive |
46
+ | `version` exits non-zero with Helm's own error | A Helm released before the `migrate` verb, typically through `HELM_LOCAL_DIR`. The fix: a newer Helm | Falls back to the archive |
47
+ | `uip` is not found | No CLI on `PATH` | Falls back to the archive |
48
+
49
+ After a fallback every result carries `uipMessage`, the reason above, so the user can fix the `uip` side instead of downloading the archive.
50
+
51
+ ## Archive fallback
52
+
53
+ The script uses the archive when `uip` cannot supply the migrator, and right away when `UIPATH_ACTIVITY_MIGRATOR_DIR` or `UIPATH_ACTIVITY_MIGRATOR_URL` is set.
54
+
55
+ ### Cache layout
19
56
 
20
57
  Default root: `%LOCALAPPDATA%\UiPath\ActivityMigrator` (`$LOCALAPPDATA/UiPath/ActivityMigrator` in Git Bash).
21
58
 
@@ -26,21 +63,22 @@ ActivityMigrator/
26
63
  UiPath.Upgrade.Cli.download.zip transient during download; removed on success, kept on an extraction failure so it can be extracted by hand
27
64
  ```
28
65
 
29
- Resolution order used by the script:
66
+ Resolution order inside the archive fallback:
30
67
 
31
68
  1. `UIPATH_ACTIVITY_MIGRATOR_DIR` when set: use `<dir>/UiPath.Upgrade.exe` if present, else `<dir>/current/UiPath.Upgrade.exe`. Nothing is downloaded into an override dir unless the exe is missing there and the run is an install run.
32
69
  2. Default root, `current/UiPath.Upgrade.exe`.
33
- 3. Nothing found: a plain run reports `missing` with `dir` and `url`, and the skill asks the user. An install run (`--install` or `--force`) downloads and extracts into the default root (or the override dir).
70
+ 3. Nothing found: a plain run reports `missing` with `dir`, `url` and any `uipMessage`, and the skill asks the user ([Install question](#install-question)). An install run (`--install` or `--force`) downloads and extracts into the default root (or the override dir).
34
71
 
35
- ## Environment variables and flags
72
+ ### Environment variables and flags
36
73
 
37
74
  | Variable / flag | Effect |
38
75
  |---|---|
39
- | `UIPATH_ACTIVITY_MIGRATOR_DIR` | Install or cache root. Use for shared tool drives or manual placement |
40
- | `UIPATH_ACTIVITY_MIGRATOR_URL` | Alternate archive URL, for internal mirrors |
41
- | `UIPATH_ACTIVITY_MIGRATOR_OFFLINE=1` | Never touch the network. A cached tool is used as is; a missing tool is an error. Wins over `--install` and `--force` |
42
- | `--install` | Download and extract when nothing is cached; replace the cache when the archive changed. The skill passes it only after the user chose the download |
43
- | `--force` | Re-download and re-extract even when cached. Implies `--install` |
76
+ | `UIPATH_ACTIVITY_MIGRATOR_DIR` | A folder holding `UiPath.Upgrade.exe`, used as is; also the archive's install root. Skips `uip`. Use for shared tool drives or manual placement |
77
+ | `UIPATH_ACTIVITY_MIGRATOR_URL` | Alternate archive URL, for internal mirrors. Skips `uip` |
78
+ | `UIPATH_ACTIVITY_MIGRATOR_OFFLINE=1` | The archive never touches the network: a cached tool is used as is, a missing one is `offline-missing`. Wins over `--install` and `--force`. `uip` is still asked; `migrate version` downloads nothing |
79
+ | `HELM_LOCAL_DIR` | Read by `uip`, not by the script: a Helm folder to use instead of the npm package, such as the Studio install's |
80
+ | `--install` | Archive only: download and extract when nothing is cached; replace the cache when the archive changed. The skill passes it only after the user chose the download. When `uip` supplies the migrator it changes nothing |
81
+ | `--force` | Archive only: re-download and re-extract even when cached. Implies `--install` |
44
82
 
45
83
  Download: the script tries `curl` first, which honors `HTTPS_PROXY` / `HTTP_PROXY`, then PowerShell's WebClient, which uses the system proxy and the signed-in user's credentials. Both run as commands, never as script files. The update check's `HEAD` request falls back the same way, so a machine that reaches the internet only through the system proxy still sees updates. A curl connection that stalls below 1 KB/s for a minute fails instead of hanging. Corporate TLS inspection that breaks both surfaces as `download-failed`, with each downloader's error in the message.
46
84
 
@@ -48,31 +86,45 @@ Extraction: `Expand-Archive`, then Windows `tar.exe`, then `unzip`. An install r
48
86
 
49
87
  ## Managed environments
50
88
 
51
- The skill never downloads without the user's choice. These settings, set machine- or user-wide by an administrator, decide the outcome before the question would be asked, so it never appears.
89
+ The skill never downloads without the user's choice. A `uip` installed with its optional Helm dependency, from the company's npm registry or the CLI's air-gapped archive, needs no setting and no download: see [Helm through uip](#helm-through-uip). For the archive, these settings, set machine- or user-wide by an administrator, decide the outcome before the install question would be asked, so it never appears.
52
90
 
53
91
  | Situation | Set | Effect |
54
92
  |---|---|---|
55
93
  | Binary distributed by desktop engineering or placed on a tool share | `UIPATH_ACTIVITY_MIGRATOR_DIR=<FOLDER>` and `UIPATH_ACTIVITY_MIGRATOR_OFFLINE=1` | The preinstalled tool is used (`source: env`) and the network is never touched. A missing tool is `offline-missing`: the skill gives the manual steps instead of offering a download |
56
94
  | Archive mirrored on an internal server | `UIPATH_ACTIVITY_MIGRATOR_URL=<MIRROR_URL>` | Download and update check go to the mirror. The user's choice is still required; the install question names the mirror |
57
- | No downloads, nothing preinstalled yet | `UIPATH_ACTIVITY_MIGRATOR_OFFLINE=1` | Every run is `offline-missing` until the tool is placed by hand |
95
+ | No downloads, nothing preinstalled yet | `UIPATH_ACTIVITY_MIGRATOR_OFFLINE=1` | Without a `uip` that supplies the migrator, every run is `offline-missing` until the tool is placed by hand |
58
96
 
59
97
  The tool is a zip: placing it needs no installer and no elevation. The `Extensions/` folder must stay next to the exe.
60
98
 
99
+ ## Activity packages offline
100
+
101
+ Whatever the source of the migrator, `upgrade` restores the project's packages and the newer activity packages it migrates to, from the project's `nuget.config` when there is one, else from the machine's NuGet configuration. Offline, add a `nuget.config` next to `project.json` whose only source is a local folder (`<clear />`, then `<add key="offline" value="D:\nuget-offline" />`), holding `.nupkg` files or merged NuGet global packages folders with two sets:
102
+
103
+ - every package at the exact version `project.json` lists (the Legacy versions, e.g. `UiPath.System.Activities 20.10.4`). The migrator looks each one up before moving it to a Windows-compatible version; an online migration only reads their metadata and never downloads them, so take them from the package cache of a machine where the project builds in Studio, or from the feed;
104
+ - the versions the migration moves to: migrate the same projects once online with `NUGET_PACKAGES` set to an empty folder, which then holds them all.
105
+
106
+ A missing package is `RESTORE-MISSING-PACKAGE` in the SARIF, naming the package and version.
107
+
61
108
  ## Script output contract
62
109
 
63
110
  The last stdout line is one JSON object.
64
111
 
65
112
  ```json
66
- {"status":"ok","exe":"C:\\Users\\me\\AppData\\Local\\UiPath\\ActivityMigrator\\current\\UiPath.Upgrade.exe","version":"25.10.0","source":"cached","runtime":"8.0.11"}
113
+ {"status":"ok","source":"uip","command":"uip rpa project migrate","version":"27.0.207-dev"}
114
+ {"status":"ok","source":"cached","command":"C:\\Users\\me\\AppData\\Local\\UiPath\\ActivityMigrator\\current\\UiPath.Upgrade.exe","exe":"C:\\Users\\me\\AppData\\Local\\UiPath\\ActivityMigrator\\current\\UiPath.Upgrade.exe","version":"26.10.0","uipMessage":"uip rpa project migrate version: helm-missing: …"}
115
+ {"status":"missing","dir":"C:\\Users\\me\\AppData\\Local\\UiPath\\ActivityMigrator","url":"https://download.uipath.com/upgrade/UiPath.Upgrade.Cli.zip","uipMessage":"uip rpa project migrate version: helm-missing: …"}
67
116
  ```
68
117
 
69
118
  | Field | Values |
70
119
  |---|---|
71
- | `status` | `ok`, `missing`, `error` |
120
+ | `status` | `ok`, `missing` (archive only), `error` |
121
+ | `source` | `uip` (Helm, through `uip`); for the archive `env` (override dir), `cached`, `downloaded` (first install), `updated` (newer archive replaced the cache) |
122
+ | `command` (`ok`) | What runs the migrator: `uip rpa project migrate` for `uip`, the exe path for the archive. The skill's `<MIGRATOR>` is built from it |
123
+ | `exe` (`ok`, archive only) | The exe path |
124
+ | `update` (`ok`, archive only) | `true` when the server's `Last-Modified` differs from the stamp on a plain run: a newer build exists and the cached tool was kept. Absent otherwise |
72
125
  | `dir`, `url` (`missing` only) | The folder an install run would fill and the archive it would fetch: the facts the skill puts in its install question |
73
- | `update` (`ok` only) | `true` when the server's `Last-Modified` differs from the stamp on a plain run: a newer build exists and the cached tool was kept. Absent otherwise |
74
- | `source` | `env` (override dir), `cached`, `downloaded` (first install), `updated` (newer archive replaced the cache) |
75
- | `code` (errors) | `not-windows`, `runtime-missing`, `download-failed`, `extract-failed`, `verify-failed`, `offline-missing`, `telemetry-flag` |
126
+ | `uipMessage` (archive only) | Why `uip` could not supply the migrator, when it was asked: `helm-missing`, an unknown command, Helm's error, or `uip` not found |
127
+ | `code` (errors) | `not-windows` (from `uip` or the script); for the archive `download-failed`, `extract-failed`, `verify-failed`, `offline-missing`, `runtime-missing`, `telemetry-flag` |
76
128
  | `env` (`telemetry-flag` only) | The assignment the tool starts with, `UIPATH_TELEMETRY_DISABLED=true` or `=false` |
77
129
  | `message` | Human-readable detail, including the manual steps for the failing stage |
78
130
 
@@ -80,22 +132,24 @@ Exit codes: `0` ok, `1` error, `3` missing.
80
132
 
81
133
  ## Install question
82
134
 
83
- SKILL.md Step 0 sends the agent here when the script reports `missing`. `<URL>` and `<DIR>` are the `url` and `dir` values of that object. Use the host's structured question tool when it has one, otherwise ask in text. Offer exactly these two options, the first as the recommended one, and no other:
135
+ SKILL.md Step 0 sends the agent here when the script reports `missing`: `uip` could not supply the migrator and no archive copy is installed. `<URL>` and `<DIR>` are the `url` and `dir` values of that object; `<UIP_REASON>` is its `uipMessage`, put in plain words (for example "`uip` is installed without its Helm component", "this `uip` is too old to have `project migrate`", "`uip` is not installed"). Use the host's structured question tool when it has one, otherwise ask in text. Offer exactly these two options, the first as the recommended one, and no other:
84
136
 
85
- > The Activity Migrator (`UiPath.Upgrade.exe`) is not installed. UiPath distributes it as a zip of a few hundred MB for Windows.
137
+ > The Activity Migrator is not available: <UIP_REASON>. Updating `uip` (`uip update`), or reinstalling it with its optional Helm dependency, makes `uip rpa project migrate` provide it with no separate download. Otherwise UiPath distributes the standalone `UiPath.Upgrade.exe` as a zip for Windows.
86
138
  >
87
139
  > 1. **Download it now** (recommended). I fetch `<URL>`, extract it into `<DIR>` and run the tool from there.
88
- > 2. **You provide it.** Download `UiPath.Upgrade.Cli.zip` yourself from `<URL>`, from Automation Cloud → Help → Resources → Downloads → Activity Migrator Tool, or from the Customer Portal. Extract it so `UiPath.Upgrade.exe` and the `Extensions/` folder sit directly in one folder, then tell me that folder or set `UIPATH_ACTIVITY_MIGRATOR_DIR` to it.
140
+ > 2. **You provide it.** Fix `uip` as above, or download `UiPath.Upgrade.Cli.zip` yourself from `<URL>`, from Automation Cloud → Help → Resources → Downloads → Activity Migrator Tool, or from the Customer Portal. Extract it so `UiPath.Upgrade.exe` and the `Extensions/` folder sit directly in one folder, then tell me that folder or set `UIPATH_ACTIVITY_MIGRATOR_DIR` to it.
89
141
  >
90
142
  > On a machine an administrator manages, these settings can be preset so this question never comes up.
91
143
 
92
- Option 1: rerun the script with `--install`. The download is a few hundred MB: give the command at least 10 minutes, not the host's default timeout. Apply Step 0's table to its output.
144
+ Leave out the `<UIP_REASON>` clause and the `uip` sentence when the object carries no `uipMessage` (`UIPATH_ACTIVITY_MIGRATOR_DIR` or `_URL` is set, so `uip` was not asked).
93
145
 
94
- Option 2: wait for the user, then rerun the script without a flag, with the variable set to the folder they named in the syntax of the shell that runs it: bash `UIPATH_ACTIVITY_MIGRATOR_DIR="<FOLDER>" node ...`, PowerShell `$env:UIPATH_ACTIVITY_MIGRATOR_DIR = '<FOLDER>'; node ...`. Apply Step 0's table. `missing` again means the folder holds no `UiPath.Upgrade.exe`, neither at its root nor under `current/`: say so, name those two places, and wait for the user; do not download and do not ask the question a second time. A variable set in the command lasts for that command only: tell the user to set it in their user environment so later sessions find the tool; a folder placed at the default `%LOCALAPPDATA%\UiPath\ActivityMigrator\current` needs no variable. The preset settings for managed machines are in [Managed environments](#managed-environments); point an administrator there when asked.
146
+ Option 1: rerun the script with `--install`. Download, extraction and the version check can outlast the host's default timeout: give the command at least 10 minutes. Apply Step 0's table to its output.
147
+
148
+ Option 2: wait for the user. When they fixed `uip`, rerun the script without a flag and apply Step 0's table: `source: uip` is the expected result. When they named a folder, rerun the script without a flag, with the variable set to that folder in the syntax of the shell that runs it: bash `UIPATH_ACTIVITY_MIGRATOR_DIR="<FOLDER>" node ...`, PowerShell `$env:UIPATH_ACTIVITY_MIGRATOR_DIR = '<FOLDER>'; node ...`. Apply Step 0's table. `missing` again means the folder holds no `UiPath.Upgrade.exe`, neither at its root nor under `current/`: say so, name those two places, and wait for the user; do not download and do not ask the question a second time. A variable set in the command lasts for that command only: tell the user to set it in their user environment so later sessions find the tool; a folder placed at the default `%LOCALAPPDATA%\UiPath\ActivityMigrator\current` needs no variable. The preset settings for managed machines are in [Managed environments](#managed-environments); point an administrator there when asked.
95
149
 
96
150
  ## Manual placement
97
151
 
98
- For air-gapped machines or when both downloaders are blocked:
152
+ For air-gapped machines without a usable `uip`, or when both downloaders are blocked ([Helm through uip](#helm-through-uip) lists the shorter routes):
99
153
 
100
154
  1. Download `UiPath.Upgrade.Cli.zip` on a machine with access (URL above, or the Automation Cloud download page).
101
155
  2. Extract it so that `UiPath.Upgrade.exe` and the `Extensions/` folder sit directly inside one folder.
@@ -103,7 +157,7 @@ For air-gapped machines or when both downloaders are blocked:
103
157
  4. Set `UIPATH_ACTIVITY_MIGRATOR_OFFLINE=1` so the script never tries the network.
104
158
  5. Rerun the acquisition script. Expected: `status: ok`, `source: env` or `cached`.
105
159
 
106
- Runtime missing: install the .NET Desktop Runtime 8 (x64) from `https://dotnet.microsoft.com/download/dotnet/8.0`, then rerun. The script checks the one place the migrator loads its runtime from: `DOTNET_ROOT_X64` or `DOTNET_ROOT` while one is set; otherwise the install location the .NET installer registers, else `%ProgramFiles%\dotnet`. It never uses the `dotnet` on `PATH`, which the migrator ignores. Verify by rerunning the script, which checks those same places:
160
+ Runtime missing (`runtime-missing`, archive only): the tool did not start because the .NET Desktop Runtime its build targets is not installed where .NET's launcher looks. The message names the version and the fix; apply it, then verify by rerunning the script:
107
161
 
108
162
  ```bash
109
163
  node "<SKILL_DIR>/scripts/ensure-migrator.mjs"
@@ -111,24 +165,26 @@ node "<SKILL_DIR>/scripts/ensure-migrator.mjs"
111
165
 
112
166
  ## Telemetry flag crash
113
167
 
114
- The `25.10.x` builds read `UIPATH_TELEMETRY_DISABLED` with a strict boolean parse. Any value other than `true` or `false`, the documented `1` included, makes every command die at startup with `The type initializer for 'UiPath.Service.Api.Communication' threw an exception.` A re-download does not help. When `version` fails while the variable holds such a value, the script retries with the strict spelling of the same choice (`0`, `no`, `off` → `false`; anything else → `true`) and, when that starts, reports `telemetry-flag` with the assignment in `env`. Prefix it to the script and to every `UiPath.Upgrade.exe` command:
168
+ Archive only. The `25.10.x` builds read `UIPATH_TELEMETRY_DISABLED` with a strict boolean parse; the current builds no longer read it. Any value other than `true` or `false`, the documented `1` included, makes every command of a 25.10 build die at startup with `The type initializer for 'UiPath.Service.Api.Communication' threw an exception.` A re-download of the same build does not help. When `version` fails while the variable holds such a value, the script retries with the strict spelling of the same choice (`0`, `no`, `off` → `false`; anything else → `true`) and, when that starts, reports `telemetry-flag` with the assignment in `env`. Prefix it to the script and to every `<MIGRATOR>` command:
115
169
 
116
170
  ```bash
117
171
  UIPATH_TELEMETRY_DISABLED=true node "<SKILL_DIR>/scripts/ensure-migrator.mjs"
118
- UIPATH_TELEMETRY_DISABLED=true "<MIGRATOR_EXE>" analyze --help
172
+ UIPATH_TELEMETRY_DISABLED=true <MIGRATOR> analyze --help
119
173
  ```
120
174
 
121
175
  Never unset the variable instead: that turns telemetry on for a user who disabled it. A build that accepts `1` and `0` starts on the first try, and the script then never reports this code. Older `uip` CLIs crash the same way in `uip rpa build`; [build-verification-guide.md](build-verification-guide.md) covers that.
122
176
 
123
177
  ## Updating
124
178
 
125
- Every plain run sends a `HEAD` request and compares `Last-Modified` with `.last-modified`. When they differ it keeps the cached tool and reports `update: true`; nothing is replaced without an install run. To update, rerun with `--install`: `current/` is replaced only when the archive changed (`source: updated`). `--force` refreshes even an unchanged cache. An override dir is never updated unless its exe is missing; replace its contents by hand. Under `UIPATH_ACTIVITY_MIGRATOR_OFFLINE=1` no `HEAD` is sent and no update is reported.
179
+ Through `uip`: update the CLI (`uip update`). It brings the matching Helm, and with it the migrator; the script sends no request of its own.
180
+
181
+ Archive fallback: every plain run sends a `HEAD` request and compares `Last-Modified` with `.last-modified`. When they differ it keeps the cached tool and reports `update: true`; nothing is replaced without an install run. To update, rerun with `--install`: `current/` is replaced only when the archive changed (`source: updated`). `--force` refreshes even an unchanged cache. An override dir is never updated unless its exe is missing; replace its contents by hand. Under `UIPATH_ACTIVITY_MIGRATOR_OFFLINE=1` no `HEAD` is sent and no update is reported.
126
182
 
127
- ## Verifying an install by hand
183
+ ## Verifying by hand
128
184
 
129
185
  ```bash
130
- "<MIGRATOR_EXE>" version
131
- "<MIGRATOR_EXE>" analyze --help
186
+ <MIGRATOR> version
187
+ <MIGRATOR> analyze --help
132
188
  ```
133
189
 
134
- The help output lists the active extensions through their flags: `--uia-*` for UI Automation, `--mail-*` / `--config` for Mail, `--gsuite-*` only in preview builds. An extension whose flags are absent is not active in this build.
190
+ With `source: uip`, `<MIGRATOR>` carries Rule 8's `UIPATH_STUDIO_PID` prefix. The help output lists the active extensions through their flags: `--uia-*` for UI Automation, `--mail-*` / `--config` for Mail, `--gsuite-*` only in preview builds. An extension whose flags are absent is not active in this build.
@@ -55,7 +55,7 @@ At most 3 iterations. Each iteration:
55
55
  |---|---|---|
56
56
  | `CS0104` / `BC30561` ambiguous `SelectorStrategy` | Classic and modern enums with the same name both imported | Not a hand fix. Delete `<OUTPUT_DIR>` and rerun Step 4 with `--uia-fix-selector-strategy=true` added to the same flags. The rerun reuses the Step 3 analyze (Rule 4 names it as the exception), counts as one iteration, and needs no question before the delete: the skill created that folder in this session |
57
57
  | Missing type from a package reported as `TYPE-MISSING` or `RESTORE-INCOMPATIBLE-PACKAGE` | Package has no Windows version | Needs attention. Report the activities; do not stub them |
58
- | Expression compile error in an unchanged expression (`BC30451`, `CS0103` on a variable) | Legacy-only API or implicit `mscorlib` type | Fix the expression with the equivalent .NET 8 API. Keep the change minimal |
58
+ | Expression compile error in an unchanged expression (`BC30451`, `CS0103` on a variable) | Legacy-only API or implicit `mscorlib` type | Fix the expression with the equivalent API of the Windows framework (modern .NET). Keep the change minimal |
59
59
  | Error inside an activity the migrator generated (Assign, Sequence, Application Card) | Migration defect | Needs attention, with the activity name; do not rewrite the generated construct blind |
60
60
  | Anything else | Unknown | Ask one yes/no question: what would change, in which file and activity, and why it should clear the error. Yes applies that one targeted fix and counts one iteration; no makes it a needs-attention item |
61
61
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  > **Owner review pending.** Pre-filled from the migrator source (`UiPath.Upgrade.GSuiteActivities`). Lines marked `VERIFY` need confirmation by the GSuite package owners. Extend the three hooks; keep their headings.
4
4
 
5
- Extension `GSuiteActivities`. The public build lists its flags and runs its migrators (verified on 25.10.1; its preview gate is compiled in unconditionally). Still confirm with `"<MIGRATOR_EXE>" analyze --help`: a build that lists no `--gsuite-*` flag has no GSuite extension; report classic GSuite activities as not migrated and skip the rest of this guide.
5
+ Extension `GSuiteActivities`. The public build lists its flags and runs its migrators (verified on 25.10.1; its preview gate is compiled in unconditionally). Still confirm with `<MIGRATOR> analyze --help`: a build that lists no `--gsuite-*` flag has no GSuite extension; report classic GSuite activities as not migrated and skip the rest of this guide.
6
6
 
7
7
  Applies when `project.json` lists `UiPath.GSuite.Activities`; the version alone does not decide it (a `3.5.10` project still carries classic activities, which the tool migrates while raising the package to its `3.8.10` minimum or the requested version). Do not pre-scan the XAML: the `analyze` run reports every affected activity per file.
8
8
 
@@ -16,7 +16,7 @@ Applies when `project.json` lists `UiPath.GSuite.Activities`; the version alone
16
16
 
17
17
  ### Flags
18
18
 
19
- Availability and defaults come from `"<MIGRATOR_EXE>" analyze --help` on the installed build (Step 0).
19
+ Availability and defaults come from `<MIGRATOR> analyze --help` on the installed build (Step 0).
20
20
 
21
21
  | Flag | Use |
22
22
  |---|---|
@@ -14,7 +14,7 @@ Extension `MailActivities`. Applies when `project.json` lists `UiPath.Mail.Activ
14
14
 
15
15
  ### Flags
16
16
 
17
- Availability and defaults come from `"<MIGRATOR_EXE>" analyze --help` on the installed build (Step 0).
17
+ Availability and defaults come from `<MIGRATOR> analyze --help` on the installed build (Step 0).
18
18
 
19
19
  | Flag | Use |
20
20
  |---|---|
@@ -8,7 +8,7 @@ The migration logic is not in the CLI. The extension loads the migration service
8
8
 
9
9
  ### Flags
10
10
 
11
- Availability and defaults come from `"<MIGRATOR_EXE>" analyze --help` on the installed build (Step 0). This table says what each flag does and when to use it. Other `--uia-*` flags may exist in a newer build; Step 0 says when an unlisted flag may be used.
11
+ Availability and defaults come from `<MIGRATOR> analyze --help` on the installed build (Step 0). This table says what each flag does and when to use it. Other `--uia-*` flags may exist in a newer build; Step 0 says when an unlisted flag may be used.
12
12
 
13
13
  | Flag | Use |
14
14
  |---|---|
@@ -1,9 +1,9 @@
1
1
  # Tool Behavior Guide
2
2
 
3
- Facts about `UiPath.Upgrade.exe` that neither `--help` nor the product documentation states, learned from the tool's source and from live runs. For the list of commands and flags, the installed build is the only authority:
3
+ Facts about the Activity Migrator that neither `--help` nor the product documentation states, learned from the tool's source and from live runs. They hold for both forms of `<MIGRATOR>` (Step 0): `uip rpa project migrate`, which runs the migrator inside Helm and hands it its arguments, stdout, stderr and exit code unchanged, and the standalone `UiPath.Upgrade.exe`. For the list of commands and flags, the installed build is the only authority:
4
4
 
5
5
  ```bash
6
- "<MIGRATOR_EXE>" analyze --help
6
+ <MIGRATOR> analyze --help
7
7
  ```
8
8
 
9
9
  Core options come first, then one block per active extension. A flag named anywhere in this skill but missing from that output does not exist in this build: do not pass it, and say so in the report.
@@ -15,12 +15,12 @@ Core options come first, then one block per active extension. A flag named anywh
15
15
 
16
16
  ## Exit code
17
17
 
18
- `0` for success, partial success, and failure alike: every exception inside a step, a crashed core step included, is caught and written into the SARIF as a result (rule `ERROR` or `WARNING`, message `Step failed: <Step> - <exception>`), and the log is still printed. Non-zero only when the command never ran, a rejected command line or a startup crash; then stdout holds no log and the one-line cause is on stderr. Status comes from the SARIF results (see [sarif-triage-guide.md](sarif-triage-guide.md)).
18
+ `0` for success, partial success, and failure alike: every exception inside a step, a crashed core step included, is caught and written into the SARIF as a result (rule `ERROR` or `WARNING`, message `Step failed: <Step> - <exception>`), and the log is still printed. Non-zero only when the command never ran, a rejected command line or a startup crash; then stdout holds no log and the one-line cause is on stderr. Through `uip`, a failure of `uip` itself (Helm not found) also exits 1, with a JSON object holding `"Result":"Failure"` on stdout or stderr. Status comes from the SARIF results (see [sarif-triage-guide.md](sarif-triage-guide.md)).
19
19
 
20
20
  ## Output streams
21
21
 
22
- - `--output-format sarif`: stdout is the SARIF 2.1.0 log, sometimes preceded by stray `info:` lines from extension steps. Redirect it to a file; the summarizer skips the leading lines, a raw JSON parse does not. Console logging is otherwise suppressed and no browser opens.
23
- - `--output-format console` (the default): a text summary plus an HTML report that the tool opens in the browser. Never use it from the agent.
22
+ - `--output-format sarif`: stdout is the SARIF 2.1.0 log, sometimes preceded by stray `info:` lines from extension steps. Redirect it to a file; the summarizer skips the leading lines, a raw JSON parse does not. Console logging is otherwise suppressed and no browser opens. The HTML report is still written; under `uip` the SARIF run's `htmlReport` property is its `file:///` link.
23
+ - `--output-format console` (the default): a text summary and the HTML report. Under `uip` the tool prints the report's `file:///` link and opens the browser only with `--open-report` (`bulk`: the combined report); the standalone archive opens it every time. Never use console output from the agent.
24
24
  - stderr: normally empty. It carries the command-line validation errors and the `Error: <message>` line of a startup crash, the two cases where stdout holds no log at all. Steps 3 and 4 redirect it to `analyze-latest.err` / `upgrade-latest.err` in `.upgrade` so it survives a background run and can be read after the fact.
25
25
 
26
26
  ## The `.upgrade` folder
@@ -38,14 +38,24 @@ Created inside the source project on every run, `analyze` included. Files per ru
38
38
  - Extension package pins run before restore and replace the dependency with an exact `[x.y.z]`.
39
39
  - Every other dependency that is not Windows-compatible moves to the smallest compatible `major.minor` above its current version, highest patch. The tool does not chase the newest line.
40
40
  - A pinned version that no reachable feed serves surfaces as `RESTORE-MISSING-PACKAGE`.
41
- - Tenant feeds: without `--orchestrator-url`, the tool falls back to the local Studio or Robot connection. With the URL, it needs a PAT or a confidential external application with `OR.Execution.Read`.
41
+ - Tenant feeds: without `--orchestrator-url`, `uip rpa project migrate` uses the tenant library feeds of the `uip login` session, for `analyze`, `upgrade` and `bulk` alike; the token travels in the environment, never on the command line. The standalone tool, or a run with no `uip login` session, falls back to the local Studio or Robot connection. With the URL, it needs a PAT or a confidential external application with `OR.Execution.Read`.
42
+ - The feeds are resolved once per command. `bulk` resolves them before its first project and hands them to every per-project run, so credentials are exchanged once and never reach a per-project command line; explicit credentials that fail stop `bulk` before the first project.
43
+ - Not logged in under `uip rpa project migrate`: the tool warns once, and every `RESTORE-MISSING-PACKAGE` note says the user is not logged in and should run `uip login`. Ask the user to run `uip login` themselves, then rerun the same command; never collect credentials for them.
44
+ - A NuGet feed that does not answer (unreachable, 401, 403) is reported once as a warning naming it, and is not searched again. `bulk` checks the configured feeds once, before its first project, and its projects search only the ones that answered.
42
45
 
43
46
  ## Orchestrator hand-off template
44
47
 
45
48
  Secrets never pass through the agent (Critical Rule 6). Hand the user the complete command with placeholders:
46
49
 
47
50
  ```bash
48
- "<MIGRATOR_EXE>" analyze --project-path "<PROJECT_DIR>" --output-format sarif --orchestrator-url "https://cloud.uipath.com/<ORG>" --orchestrator-tenant "<TENANT>" --orchestrator-pat "<PAT>" > "<PROJECT_DIR>/.upgrade/analyze-latest.sarif"
51
+ <MIGRATOR> analyze --project-path "<PROJECT_DIR>" --output-format sarif --orchestrator-url "https://cloud.uipath.com/<ORG>" --orchestrator-tenant "<TENANT>" --orchestrator-pat "<PAT>" > "<PROJECT_DIR>/.upgrade/analyze-latest.sarif"
52
+ ```
53
+
54
+ When `<MIGRATOR>` is `uip rpa project migrate`, prefer the form that keeps the PAT off the command line, the shell history and the process list: each `--orchestrator-*` option it is not given is read from an environment variable.
55
+
56
+ ```powershell
57
+ $env:UIPATH_ORCHESTRATOR_URL = "https://cloud.uipath.com/<ORG>"; $env:UIPATH_ORCHESTRATOR_TENANT = "<TENANT>"; $env:UIPATH_ORCHESTRATOR_PAT = "<PAT>"
58
+ <MIGRATOR> analyze --project-path "<PROJECT_DIR>" --output-format sarif > "<PROJECT_DIR>/.upgrade/analyze-latest.sarif"
49
59
  ```
50
60
 
51
61
  ## Extensions
@@ -57,7 +67,7 @@ Secrets never pass through the agent (Critical Rule 6). Hand the user the comple
57
67
  ## bulk
58
68
 
59
69
  ```bash
60
- "<MIGRATOR_EXE>" bulk --path "<ROOT>" --command analyze
70
+ <MIGRATOR> bulk --path "<ROOT>" --command analyze
61
71
  node "<SKILL_DIR>/scripts/summarize-sarif.mjs" "<ROOT>/repository-analyze-results.sarif"
62
72
  ```
63
73
 
@@ -1,18 +1,30 @@
1
1
  #!/usr/bin/env node
2
- // ensure-migrator.mjs — locate and verify the UiPath Activity Migrator (UiPath.Upgrade.exe); install it only when asked.
2
+ // ensure-migrator.mjs — locate and verify the UiPath Activity Migrator: Helm's, through uip, else UiPath.Upgrade.exe;
3
+ // download the archive only when asked.
3
4
  //
4
5
  // Usage: node ensure-migrator.mjs [--install] [--force]
5
- // (no flag) locate a cached tool, verify it, and report whether UiPath published a newer archive; never download.
6
- // Exit 3 with status "missing" when nothing is cached: the caller asks the user before installing.
7
- // --install download and extract when nothing is cached; replace the cache when the archive changed
8
- // --force re-download and re-extract even when cached (implies --install)
9
- // Env: UIPATH_ACTIVITY_MIGRATOR_DIR install/cache root (default %LOCALAPPDATA%\UiPath\ActivityMigrator)
10
- // UIPATH_ACTIVITY_MIGRATOR_URL archive URL (default https://download.uipath.com/upgrade/UiPath.Upgrade.Cli.zip)
11
- // UIPATH_ACTIVITY_MIGRATOR_OFFLINE set to 1 to never touch the network; wins over --install and --force
12
- // UIPATH_TELEMETRY_DISABLED read only: a value other than true/false that crashes the tool is reported
6
+ // (no flag) ask uip, else locate a cached archive tool, verify it, and report whether UiPath published a newer
7
+ // archive; never download. Exit 3 with status "missing" when nothing is cached: the caller asks the user
8
+ // before installing.
9
+ // --install archive fallback: download and extract when nothing is cached; replace the cache when the archive changed
10
+ // --force archive fallback: re-download and re-extract even when cached (implies --install)
11
+ // Env: UIPATH_ACTIVITY_MIGRATOR_DIR archive fallback: a folder holding UiPath.Upgrade.exe, used as is; also the
12
+ // cache root (default %LOCALAPPDATA%\UiPath\ActivityMigrator). Skips uip
13
+ // UIPATH_ACTIVITY_MIGRATOR_URL archive fallback: the archive URL. Skips uip
14
+ // (default https://download.uipath.com/upgrade/UiPath.Upgrade.Cli.zip)
15
+ // UIPATH_ACTIVITY_MIGRATOR_OFFLINE archive fallback: set to 1 to never touch the network; wins over --install
16
+ // and --force
17
+ // UIPATH_TELEMETRY_DISABLED archive fallback, read only: a value other than true/false that crashes the
18
+ // 25.10 builds is reported
13
19
  // Output: the last stdout line is one JSON object; see references/acquisition-guide.md § Script output contract.
14
20
  // Exit: 0 ok, 1 error, 3 missing. No dependencies. Node 18+.
15
21
  //
22
+ // The migrator ships inside Helm, which uip installs with rpa-tool: `uip rpa project migrate analyze|upgrade|bulk|version`
23
+ // forwards its arguments to `UiPath.Upgrade.exe` in Helm's folder (Helm's apphost under another name), on the dotnet
24
+ // uip resolves for Helm. The script asks
25
+ // `uip rpa project migrate version`. The public archive of the standalone UiPath.Upgrade.exe is the fallback for a
26
+ // machine without uip, a uip without `project migrate`, a uip without Helm (helm-missing), or a Helm without the verb.
27
+ //
16
28
  // Node runs the whole flow so no .ps1 or .sh file is executed: script execution policies and hosts that gate
17
29
  // PowerShell script invocations never apply. Network and archive work is delegated to the Windows tools that
18
30
  // already handle proxies and zips: curl (HTTPS_PROXY), then PowerShell's WebClient as a -Command (system proxy).
@@ -30,8 +42,10 @@ const args = process.argv.slice(2);
30
42
  const FORCE = args.includes('--force') && !OFFLINE;
31
43
  const INSTALL = !OFFLINE && (FORCE || args.includes('--install'));
32
44
 
45
+ // Why uip could not supply the migrator, once the script fell back to the archive; reported with every later result.
46
+ let uipMessage = '';
33
47
  const emit = (obj, code) => {
34
- process.stdout.write(JSON.stringify(obj) + '\n');
48
+ process.stdout.write(JSON.stringify({ ...obj, ...(uipMessage && { uipMessage }) }) + '\n');
35
49
  process.exit(code);
36
50
  };
37
51
  const fail = (code, message) => emit({ status: 'error', code, message }, 1);
@@ -65,11 +79,54 @@ const head = (s, n) => s.replace(/\s+/g, ' ').trim().slice(0, n);
65
79
 
66
80
  // --- 1. Windows only -------------------------------------------------------
67
81
  if (process.platform !== 'win32') {
68
- fail('not-windows', 'The Activity Migrator is a Windows-only .NET 8 desktop tool. Run this skill from a Windows machine that holds the project.');
82
+ fail('not-windows', 'The Activity Migrator is a Windows-only .NET desktop tool. Run this skill from a Windows machine that holds the project.');
69
83
  }
70
84
 
71
- // --- 2. Resolve install root and any existing exe --------------------------
85
+ // --- 2. Ask uip ------------------------------------------------------------
86
+ // `uip rpa project migrate version` prints Helm's version as its last stdout line: the migrator is there. It downloads
87
+ // nothing, so a plain run and offline mode ask it too; the first run of a Helm version copies Helm into its run slot,
88
+ // which can take a while. The command line is fixed text, so the shell (needed for the uip.cmd shim) sees no input.
89
+ // uip's own failures are a JSON FailureOutput with a Code, on stdout or stderr. not-windows ends the run; helm-missing,
90
+ // an unknown command (a uip older than `project migrate`), no uip at all, or a Helm without the verb fall back.
91
+ const lastLine = (s) => s.split(/\r?\n/).map((l) => l.trim()).findLast(Boolean) || '';
92
+ const uipFailure = (text) => {
93
+ for (let start = text.indexOf('{'); start >= 0; start = text.indexOf('{', start + 1)) {
94
+ for (let end = text.lastIndexOf('}'); end > start; end = text.lastIndexOf('}', end - 1)) {
95
+ try {
96
+ const reply = JSON.parse(text.slice(start, end + 1));
97
+ if (reply && reply.Result === 'Failure') return reply;
98
+ } catch {
99
+ // not this span
100
+ }
101
+ }
102
+ }
103
+ return null;
104
+ };
105
+ const UIP_COMMAND = 'uip rpa project migrate';
106
+ const fromUip = () => {
107
+ const env = { ...process.env };
108
+ delete env.UIPATH_STUDIO_PID;
109
+ const r = run(`${UIP_COMMAND} version`, [], { shell: true, env, timeout: 5 * 60 * 1000 });
110
+ const reply = uipFailure(r.out) || uipFailure(r.err);
111
+ if (reply) {
112
+ const message = [reply.Message, reply.Instructions].filter(Boolean).join(' ');
113
+ if (reply.Code === 'not-windows') fail('not-windows', `${UIP_COMMAND}: ${message}`);
114
+ uipMessage = `${UIP_COMMAND} version: ${reply.Code ? `${reply.Code}: ` : ''}${message}`;
115
+ return;
116
+ }
117
+ // The last line that reads as a version: a notice uip prints after Helm's output does not hide it.
118
+ const version = r.out.split(/\r?\n/).map((l) => l.trim()).findLast((l) => /^\d+\.\d+/.test(l)) || '';
119
+ if (r.ok && version) emit({ status: 'ok', source: 'uip', command: UIP_COMMAND, version }, 0);
120
+ // No uip on PATH, a uip without the command, or a Helm that does not know `migrate`: their own error text.
121
+ const detail = head(r.err, 300) || head(r.out, 300) || (r.status == null ? 'no output' : `exit code ${r.status}, no output`);
122
+ uipMessage = `${UIP_COMMAND} version: ${detail}`;
123
+ };
124
+
125
+ if (!process.env.UIPATH_ACTIVITY_MIGRATOR_DIR && !process.env.UIPATH_ACTIVITY_MIGRATOR_URL) fromUip();
126
+
127
+ // --- 3. Archive fallback: resolve install root and any existing exe -------
72
128
  let source = '';
129
+ let exe = '';
73
130
  let root;
74
131
  if (process.env.UIPATH_ACTIVITY_MIGRATOR_DIR) {
75
132
  root = toWin(process.env.UIPATH_ACTIVITY_MIGRATOR_DIR);
@@ -80,7 +137,6 @@ if (process.env.UIPATH_ACTIVITY_MIGRATOR_DIR) {
80
137
  }
81
138
  const current = join(root, 'current');
82
139
  const stamp = join(root, '.last-modified');
83
- let exe = '';
84
140
  if (isFile(join(root, 'UiPath.Upgrade.exe'))) exe = join(root, 'UiPath.Upgrade.exe');
85
141
  else if (isFile(join(current, 'UiPath.Upgrade.exe'))) exe = join(current, 'UiPath.Upgrade.exe');
86
142
  if (!source) source = 'cached';
@@ -91,7 +147,7 @@ if (!exe && OFFLINE) {
91
147
  // Nothing cached and nobody consented to a download: report, so the caller can ask the user.
92
148
  if (!exe && !INSTALL) emit({ status: 'missing', dir: root, url: ARCHIVE_URL }, 3);
93
149
 
94
- // --- 3. Decide whether to download ----------------------------------------
150
+ // --- 3b. Decide whether to download ---------------------------------------
95
151
  let needDownload = !exe || FORCE;
96
152
  let isUpdate = false;
97
153
  let updateAvailable = false;
@@ -191,42 +247,49 @@ if (needDownload) {
191
247
  source = isUpdate ? 'updated' : 'downloaded';
192
248
  }
193
249
 
194
- // --- 5. .NET Desktop Runtime 8 ---------------------------------------------
195
- // Check the one place the migrator's launcher loads its runtime from: a set DOTNET_ROOT_X64 or DOTNET_ROOT, with no
196
- // fallback; otherwise the location the .NET installer registers (32-bit registry view), else %ProgramFiles%\dotnet.
197
- // The launcher never looks at PATH, so a dotnet on PATH says nothing about what the tool will load.
198
- let dotnetRootVar = '';
199
- if (process.env.DOTNET_ROOT_X64) dotnetRootVar = 'DOTNET_ROOT_X64';
200
- else if (process.env.DOTNET_ROOT) dotnetRootVar = 'DOTNET_ROOT';
201
- const registeredDotnet = () => {
202
- const reg = join(process.env.SystemRoot || 'C:\\Windows', 'System32', 'reg.exe');
203
- const q = run(reg, ['query', 'HKLM\\SOFTWARE\\dotnet\\Setup\\InstalledVersions\\x64', '/v', 'InstallLocation', '/reg:32']);
204
- const m = q.ok ? /InstallLocation\s+REG_SZ\s+(.+)/i.exec(q.out) : null;
205
- return m ? m[1].trim() : '';
206
- };
207
- const dotnetDir = dotnetRootVar
208
- ? process.env[dotnetRootVar]
209
- : registeredDotnet() || join(process.env.ProgramFiles || 'C:\\Program Files', 'dotnet');
210
- const dotnetExe = join(dotnetDir, 'dotnet.exe');
211
- const list = isFile(dotnetExe) ? run(dotnetExe, ['--list-runtimes']) : null;
212
- let runtime = '';
213
- for (const line of list?.ok ? list.out.split(/\r?\n/) : []) {
214
- const parts = line.trim().split(/\s+/);
215
- if (parts[0] === 'Microsoft.WindowsDesktop.App' && /^8\./.test(parts[1] || '')) runtime = parts[1];
216
- }
217
- if (!runtime) {
218
- const fix = dotnetRootVar
219
- ? `, the only place the migrator loads its runtime from while ${dotnetRootVar} is set. Unset ${dotnetRootVar}, or install the runtime there, and rerun.`
220
- : ', where the migrator loads its runtime from. Install the .NET Desktop Runtime 8 (x64) from https://dotnet.microsoft.com/download/dotnet/8.0 and rerun.';
221
- fail('runtime-missing', `Microsoft.WindowsDesktop.App 8.x not found in ${dotnetDir}` + fix);
222
- }
223
-
224
- // --- 6. Verify the tool answers --------------------------------------------
225
- // The tool's own stderr names why it could not start, such as a runtime it cannot resolve; a re-download never fixes
226
- // that. .NET launch errors lead with the cause and end with links, so the start of the text is kept.
250
+ // --- 5. Verify the tool answers --------------------------------------------
251
+ // Starting the tool is the only check of its .NET runtime. Which runtime a build needs, where the launcher looks for it
252
+ // and what a roll-forward setting lets it accept are the launcher's rules; a copy of them here would name the wrong
253
+ // runtime for a build that targets another .NET, and refuse a tool that starts.
227
254
  const ver = run(exe, ['version'], { timeout: 60000 });
228
- const lastLine = (s) => s.split(/\r?\n/).map((l) => l.trim()).findLast(Boolean) || '';
229
255
  const version = lastLine(ver.out);
256
+
257
+ // .NET's launcher exits with these codes before any tool code runs. FRAMEWORK_MISSING: it found a .NET install without
258
+ // the runtime this build needs. HOST_MISSING: it found no .NET install; a broken install exits the same way, so there
259
+ // the launcher's text decides, and anything else stays a verify failure that relays the text.
260
+ const FRAMEWORK_MISSING = 0x80008096;
261
+ const HOST_MISSING = 0x80008083;
262
+ if (ver.status === FRAMEWORK_MISSING || (ver.status === HOST_MISSING && /You must install \.NET to run this application/i.test(ver.err))) {
263
+ const hostLine = (re) => (re.exec(ver.err) || [])[1]?.trim() || '';
264
+ // The build's runtimeconfig, next to the exe, names the .NET it targets. It only words the fix; unreadable, the
265
+ // launcher's text is relayed instead. The launcher's first missing framework is the base runtime, and its download
266
+ // link installs that one alone, so the fix names the Desktop Runtime, which holds both frameworks the tool loads.
267
+ let major = '';
268
+ try {
269
+ const opts = JSON.parse(readFileSync(exe.replace(/\.exe$/i, '.runtimeconfig.json'), 'utf8')).runtimeOptions;
270
+ const frameworks = opts.frameworks || [opts.framework];
271
+ const target = frameworks.find((f) => f.name === 'Microsoft.WindowsDesktop.App') || frameworks.find((f) => f.name === 'Microsoft.NETCore.App');
272
+ major = /^(\d+)\./.exec(target.version)[1];
273
+ } catch { /* no major: the launcher's text names the version */ }
274
+ const arch = hostLine(/^Architecture:\s*(\S+)/m) || 'x64';
275
+ const runtimeName = major ? `the .NET Desktop Runtime ${major} (${arch})` : `a .NET Desktop Runtime (${arch})`;
276
+ const page = 'https://dotnet.microsoft.com/download/dotnet' + (major ? `/${major}.0` : '');
277
+ const reported = major ? '' : ` The launcher names the version: ${head(ver.err, 400)}`;
278
+ // The launcher lists what it found of the framework it missed: the reason an installed .NET did not count.
279
+ const found = [...ver.err.matchAll(/^[ \t]+(\d+\.\d+\.\S+) at \[/gm)].map((m) => m[1]);
280
+ const others = found.length ? ` Versions found there, none of which this build accepts: ${found.join(', ')}.` : '';
281
+ // The launcher takes the first of DOTNET_ROOT_<ARCH> and DOTNET_ROOT that names an existing folder and looks nowhere
282
+ // else, so an install into the default location would change nothing. A variable that names no folder is skipped;
283
+ // with neither left, the launcher uses the default location, reported below.
284
+ const rootVar = [`DOTNET_ROOT_${arch.toUpperCase()}`, 'DOTNET_ROOT'].find((name) => process.env[name] && isDir(process.env[name]));
285
+ if (rootVar) {
286
+ fail('runtime-missing', `${exe} needs ${runtimeName}, which is not in ${process.env[rootVar]}, the only place the migrator loads its runtime from while ${rootVar} is set.${others} Unset ${rootVar}, or install the runtime there, and rerun.${reported}`);
287
+ }
288
+ const where = hostLine(/^\.NET location:[ \t]*(\S.*)$/m);
289
+ const place = where && !/^not found$/i.test(where) ? ` in ${where}, where the migrator loads its runtime from.` : ': no .NET install was found on this machine.';
290
+ fail('runtime-missing', `${exe} needs ${runtimeName}, which is not installed${place}${others} Install ${runtimeName} from ${page} and rerun.${reported}`);
291
+ }
292
+
230
293
  // The 25.10 builds parse UIPATH_TELEMETRY_DISABLED with bool.Parse and crash at startup on any value but true or
231
294
  // false, such as the documented 1. Prove it with a retry under the strict spelling of the user's choice; never unset
232
295
  // the variable, which would turn the user's telemetry back on.
@@ -238,11 +301,13 @@ if ((!ver.ok || !version) && telemetry !== undefined && !/^\s*(true|false)\s*$/i
238
301
  emit({ status: 'error', code: 'telemetry-flag', env: `UIPATH_TELEMETRY_DISABLED=${strict}`, message: `${exe} crashes at startup while UIPATH_TELEMETRY_DISABLED is ${JSON.stringify(telemetry)}: this build accepts only true or false. It starts with UIPATH_TELEMETRY_DISABLED=${strict}, the same choice. Prefix this script and every UiPath.Upgrade.exe command with it; never unset the variable.` }, 1);
239
302
  }
240
303
  }
304
+ // Any other failure: the tool's own stderr names why it could not start. .NET launch errors lead with the cause and end
305
+ // with links, so the start of the text is kept.
241
306
  if (!ver.ok || !version) {
242
307
  const detail = head(ver.err, 400) || (ver.status == null ? 'no output' : `exit code ${ver.status}, no output`);
243
308
  fail('verify-failed', `${exe} did not print a version (${detail}). When that names a missing runtime or framework, fix it as it says; otherwise the install may be incomplete: rerun with --force.`);
244
309
  }
245
310
 
246
- const result = { status: 'ok', exe, version, source, runtime };
311
+ const result = { status: 'ok', source, command: exe, exe, version };
247
312
  if (updateAvailable) result.update = true;
248
313
  emit(result, 0);
@@ -103,6 +103,12 @@ try {
103
103
  console.error(`cannot parse ${file}: ${e.message}`);
104
104
  process.exit(2);
105
105
  }
106
+ // Through `uip rpa project migrate`, a uip failure (its FailureOutput JSON) can land in the redirected .sarif. It is
107
+ // no migrator log: report it as such rather than as a log without results.
108
+ if (sarif && sarif.Result === 'Failure' && !sarif.runs) {
109
+ console.error(`failure reported by uip in ${file}: ${[sarif.Code, sarif.Message, sarif.Instructions].filter(Boolean).join(': ')}`);
110
+ process.exit(2);
111
+ }
106
112
 
107
113
  const run = (sarif.runs && sarif.runs[0]) || {};
108
114
  const rules = new Map(((run.tool && run.tool.driver && run.tool.driver.rules) || []).map((r) => [r.id, r]));