Repository navigation
Start failures say Revyl's reason; app links follow the backend; CDP counts as activity - #97
Conversation
- Devices: when the worker connection is terminal, read the device session's error_message and put it, without the app's host, in SESSION_START_FAILED. - Web (Python, Go): relay error_message instead of 'Web session ended before becoming ready'; strip the app host from the profile-ended message too. - Computers: name every failure_reason other than no_host/device_limit with what to do; persistent computers name it as well. - The app URL defaults to the app of the Revyl the backend URL names (backend-<name>.revyl.ai -> <name>.revyl.ai), else app.revyl.ai. - Web-app errors no longer repeat the URL or its host. - idleTimeoutSeconds hints and cdp() docs: CDP commands count as activity. Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…ign persistent start failures - withoutAppHost/_start_reason/startReason replace the host as parsed and as written, case-insensitively. - A whitespace-only error_message falls back to the connection's message. - Python and Go persistent start failures explain no_host and device_limit like computers do; TS persistent always gives the openPersistent fix. Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…ocus Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
5a53f59 to
7990537
Compare
TS's URL parser already gives the punycode host; Python now also matches
host.encode('idna') and Go an RFC 3492 encoding of each label.
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
The idna codec maps ß to ss (IDNA 2003), so faß.de missed xn--fa-hia.de. Encode each non-ASCII label with punycode over the lowercased label, and keep stripping the IDNA 2003 form when it differs. Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> # Conflicts: # CHANGELOG.md # go/session.go # packages/verify/src/session.ts # python/src/revyl_verify/_session.py
…start-reasons-app-link
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 2 potential issues.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 1aa9edf. Configure here.
| s := &Session{client: c, id: start.SessionID, runID: start.RunID, platform: target.Platform, stepTimeout: opt.StepTimeout, log: opt.Log, agent: agent, profile: profile} | ||
| if target.Platform == Web { | ||
| s.appURL = target.URL | ||
| } |
There was a problem hiding this comment.
Hosted web errors keep the host
Medium Severity
appURL is set only when Open builds a web Session. A web session started from a computer is a different Session and never sets it, but ready still calls startReason. With appURL empty, host redaction is skipped, so a preview host in Revyl's error_message is still printed.
Reviewed by Cursor Bugbot for commit 1aa9edf. Configure here.
| labels[i] = "xn--" + encoded | ||
| } | ||
| } | ||
| return strings.Join(labels, ".") |
There was a problem hiding this comment.
Go punycode skips browser normalization
Low Severity
idnaHost punycodes the lowerHost label with no Unicode normalization. Browsers and Python's idna codec normalize first, so an NFD host or İ becomes a different xn-- label than the one in Revyl's error. That form is left in the message. Unlike Python, Go also never strips the IDNA 2003 spelling, such as ß mapped to ss.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 1aa9edf. Configure here.
…start-reasons-app-link


G2, G3 and G5 from the /verify device dogfood (REVL-46674). Stacked on #93, which removes the app host from TS web start-failure and failed-profile messages, and reuses its helper.
G2: start failures say Revyl's reason
error_message, with the app host stripped as Web sessions: a failed start says "web session" once and leaves out the app's host #93 does in TS. Before, it said "Web session ended before becoming ready".error_messageand puts it inSESSION_START_FAILEDwith the link. The connection's ownmessageis always the placeholderSession <status>for a terminal session. When the reason is null, the error falls back to today's text.failure_reasonon the report is named in the message, such as(failed: host_start_failed). It is safe to try again: open() starts a new computer.Before, onlyno_hostanddevice_limitwere explained and the rest were dropped. A value is shown only if it's a plain code. No newRefusalReasonvalues.runtime_code=…appears only insideerror_message, and only for four runtime failure types. Any otherhost_startexception is stored as just "Failed during host_start", so that's all Verify can show.G3: links follow the backend
With no app URL and no
REVYL_APP_URL, the app link comes from the backend Verify talks to:backend.revyl.ai→app.revyl.aibackend-<name>.revyl.ai→<name>.revyl.aiapp.revyl.ai, as todayThis applies to session links,
report, and the API-key page hint, in all three languages. It's internal behaviour, so the CHANGELOG line describes it without naming environments.Host audit: after #93, these errors still echoed the host or URL; all are fixed in all three languages:
Verify: <host>Left on purpose: the scheme-fix hint for
http://or a scheme-less URL echoes the corrected URL. It's the caller's own value and it is the fix.G5: CDP and the idle timeout (docs and the config hint)
cdp()resets the web idle timer (cognisim_python_cli/web_runtime/action_host.py, inbound customer frames), as every Verify step does. Browser events and replies don't, and the SDK sends no keepalive.idleTimeoutSecondshint say so, and tell a quiet script to send a cheap command such asBrowser.getVersion, or to raiseidleTimeoutSeconds.keepAlive()API, because CDP traffic already counts.Proposal, needs Anam's approval (not built):
readyTimeoutMsfor webreadyTimeoutMs, 5000-120000 ms in whole seconds; Pythonready_timeout; GoReadyTimeout.INITIAL_NAVIGATION_TIMEOUT_SECONDS. Adding it needs:initial_navigation_timeout_secondsfield onWebSessionOptions,WebStartSourceandWebBundleSource, allextra="forbid"25 + nav) scaling with itReview
An independent review found no high-severity issues. Fixed in d9cb176:
Residual gap: for a non-ASCII host, Go strips only the host as written, not its punycode form.
Checks
npm test(317).check:links.No tests were added or changed, and nothing was run live; the device
error_messageformat is known only from code. This PR conflicts with #96 on the web-app error lines and the CHANGELOG headings, and lightly with #94 inpersistent.ts.Note
Medium Risk
Touches session startup error paths and URL derivation used for every session link; behavior changes are user-visible but limited to messaging and defaults, not request semantics.
Overview
Improves diagnostics and link consistency across TypeScript, Python, and Go for the 0.9.3 release.
Session start failures now relay Revyl’s reasons: web and device sessions read
error_message(and workermessagewhen needed) intoSESSION_START_FAILED, with the app URL’s host replaced by the app URL so preview hosts don’t leak in errors. Computer starts name every safefailure_reasoncode (not onlyno_host/device_limit), add retry guidance where appropriate, and persistent computers always tell you to callopenPersistent()again.Printed links (
viewerUrl, session links, missing-credentials API-key hint) default to the Revyl web app that matchesbackendUrlwhenappUrlis unset—backend-<env>.revyl.aimaps to<env>.revyl.ai, otherwise productionapp.revyl.ai.Docs and validation hints clarify that web idle timeout resets on Verify steps and CDP commands;
timeoutMson web/mobile targets is rejected with a message pointing atidleTimeoutSeconds. CDP sections also document auto-accepted dialogs and headless focus emulation.Web-app creation/register errors no longer quote app names or URLs; they refer to the app URL.
Reviewed by Cursor Bugbot for commit 1aa9edf. Bugbot is set up for automated code reviews on this repo. Configure here.
Stack
Top of the 0.9.3 stack, based on #96 (
capy/web-app-no-host), which is based on #94. Merge in order: #94 → #96 → #97.