iOfficeAI/AionUi · error · Error
t(keys.startFailed)
Error message
t(keys.startFailed)
What it means
start() in OfficeWatchViewer throws t(keys.startFailed) when the IPC call that launches the Office watch HTTP server succeeds (loading ends) but returns a result without a url. The viewer cannot construct a webview URL, so the Office document cannot be previewed.
Source
Thrown at packages/desktop/src/renderer/pages/conversation/Preview/components/viewers/OfficeWatchViewer.tsx:212
const start = async () => {
setLoading(true);
setStatus('starting');
setError(null);
try {
const result = await bridge.start.invoke({ file_path, workspace, file: fileRef });
const errorCode = normalizeOfficeWatchErrorCode(result.error);
if (errorCode) {
setError({
code: errorCode,
message: t(OFFICE_ERROR_I18N_KEYS[errorCode]),
});
setLoading(false);
return;
}
const url = result.url;
if (!url) {
throw new Error(t(keys.startFailed));
}
// Small delay to ensure the watch HTTP server is fully ready for the webview
await new Promise((r) => setTimeout(r, 300));
if (!cancelled) {
const resolvedUrl = resolveOfficeWatchUrl(url, docType);
setWatchUrl(resolvedUrl);
setLoading(false);
}
} catch (err) {
if (!cancelled) {
const backendCode = isBackendHttpError(err) ? normalizeOfficeWatchErrorCode(err.code) : undefined;
if (backendCode) {
setError({
code: backendCode,
message: t(OFFICE_ERROR_I18N_KEYS[backendCode]),
});
setLoading(false);
return;View on GitHub (pinned to 711aa0550e)
Solutions
- Check main-process logs for why the watch server returned no URL (crash, port conflict)
- Verify the Office preview dependency/binary is installed and its version is supported
- Retry opening the document once — transient startup races are common
- Convert or re-save a corrupt document and retry
Defensive patterns
Strategy: retry
Try / catch
try {
const result = await start();
if (!result?.url) throw new Error(t(keys.startFailed));
} catch (e) {
// one retry after short delay, then show retry UI
} Prevention
- Verify the office preview dependency is installed before enabling the viewer
- Retry start once — watch server startup races are common
- Surface a manual 'Retry' button instead of a dead-end error state
When it happens
Trigger: Invoking the office-watch start IPC and receiving { url: undefined/null }; the Collabora/OnlyOffice watch server process starting but failing to report its listening URL; race where the server exits before reporting.
Common situations: Office preview dependency not installed or wrong version, port allocation failure on the main side, or the watch server crashing on malformed .docx/.xlsx files.
Related errors
- fork returned no conversation
- scm port not configured
- result?.msg || fallbackMessage
- File data not found
- Image file not found
AI-assisted analysis of iOfficeAI/AionUi@711aa0550e (2026-08-28).
Data as JSON: /api/errors/784817794a7e78f4.
Report an issue: GitHub.