Skip to content

Commit b3d0002

Browse files
thymikeeclaude
andcommitted
docs(revyl): close the embedded host when the release fails, and keep plugin help where it was
The embed example released the lease and then closed the host in one `finally`, so a release that threw left the embedded daemon alive with the session still rented. The close now runs in its own `finally`, on every exit path. In the remote help, the plugin-installation paragraph is back where it was: the rendered text keeps its first-screen rules inside the first 30 lines, and the rewrap pushed the MCP rule past them. The Revyl lines themselves are unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent 8d2e11d commit b3d0002

2 files changed

Lines changed: 8 additions & 3 deletions

File tree

‎src/commands/schema/cli-help.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,7 @@ After direct-provider connect:
550550
Do not run devices as a pre-open catalog probe for direct providers; it can allocate the deferred provider session. Limrun is the exception for apps: before allocation it lists uploaded assets for the selected platform.
551551
552552
Device cloud interfaces:
553-
CLI is the canonical bootstrap path: connect limrun/browserstack/aws-device-farm/testmu/revyl, then use normal open/snapshot/click/close/disconnect commands; artifacts are provider-dependent.
553+
CLI is the canonical bootstrap path: connect limrun/browserstack/aws-device-farm/testmu/revyl, then use normal open/snapshot/click/close/artifacts/disconnect commands.
554554
JavaScript can skip persisted connect state by passing leaseProvider plus provider fields to createAgentDeviceClient or per-command options.
555555
MCP exposes operational tools such as open, snapshot, click, close, and artifacts. It does not expose connect/disconnect; run CLI connect first in the same state dir before relying on MCP tools.
556556

‎website/docs/docs/revyl.md‎

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,8 +146,13 @@ try {
146146
await client.interactions.click({ selector: 'label="Continue"' });
147147
} finally {
148148
// Releasing the lease ends the Revyl session, so a failure cannot leave a device rented.
149-
await host.client.leases.release({ ...scope, leaseId: lease.leaseId });
150-
await host.close();
149+
// The inner finally closes the host even when the release itself fails; otherwise the embedded
150+
// daemon stays alive and nothing retries the release.
151+
try {
152+
await host.client.leases.release({ ...scope, leaseId: lease.leaseId });
153+
} finally {
154+
await host.close();
155+
}
151156
}
152157
```
153158

0 commit comments

Comments
 (0)