The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.
Rust agent-orchestrationai-agentsai-assistantdesktopllmlocal-firstmcppersonal-aiprivacyrustsecond-braintauri
fix(tauriCommands): add missing import for invoke in multiple command files
Steven Enamakel57a9efe28381
diff --git a/app/src/utils/tauriCommands/auth.ts b/app/src/utils/tauriCommands/auth.tsindex 7260700ea0..20ceaa9efd 100644--- a/app/src/utils/tauriCommands/auth.ts+++ b/app/src/utils/tauriCommands/auth.ts@@ -8,16 +8,12 @@*/import { callCoreRpc } from '../../services/coreRpcClient';import { logoutSession, storeSessionToken } from '../../services/session/sessionOwner';-import { type CommandResponse, isTauri } from './common';+import { type CommandResponse } from './common';/*** Get the current authentication state from Rust*/export async function getAuthState(): Promise<{ is_authenticated: boolean; user: object | null }> {- if (!isTauri()) {- return { is_authenticated: false, user: null };- }-const response = await callCoreRpc<{ result: { isAuthenticated: boolean; user: object | null } }>({ method: 'openhuman.auth_get_state' });diff --git a/app/src/utils/tauriCommands/composio.ts b/app/src/utils/tauriCommands/composio.tsindex e5f018816d..b4a687f648 100644--- a/app/src/utils/tauriCommands/composio.ts+++ b/app/src/utils/tauriCommands/composio.ts@@ -1,5 +1,5 @@import { callCoreRpc } from '../../services/coreRpcClient';-import { type CommandResponse, isTauri } from './common';+import { type CommandResponse } from './common';export interface ComposioTriggerHistoryEntry {received_at_ms: number;diff --git a/app/src/utils/tauriCommands/cron.ts b/app/src/utils/tauriCommands/cron.tsindex bd020455fc..be61ac7f5d 100644--- a/app/src/utils/tauriCommands/cron.ts+++ b/app/src/utils/tauriCommands/cron.ts@@ -2,7 +2,7 @@* Cron job commands.*/import { callCoreRpc } from '../../services/coreRpcClient';-import { CommandResponse, isTauri } from './common';+import { CommandResponse } from './common';export interface CoreCronScheduleCron {kind: 'cron';diff --git a/app/src/utils/tauriCommands/localAi.ts b/app/src/utils/tauriCommands/localAi.tsindex 006f1b9e2e..863eab9614 100644--- a/app/src/utils/tauriCommands/localAi.ts+++ b/app/src/utils/tauriCommands/localAi.ts@@ -6,7 +6,7 @@* backend (for example an external Ollama endpoint).*/import { callCoreRpc } from '../../services/coreRpcClient';-import { CommandResponse, isTauri, tauriErrorMessage } from './common';+import { CommandResponse, tauriErrorMessage } from './common';export interface LocalAiStatus {state: string;diff --git a/app/src/utils/tauriCommands/memory.ts b/app/src/utils/tauriCommands/memory.tsindex 398861142e..19a9a9cabc 100644--- a/app/src/utils/tauriCommands/memory.ts+++ b/app/src/utils/tauriCommands/memory.ts@@ -2,7 +2,6 @@* Memory subsystem commands.*/import { callCoreRpc } from '../../services/coreRpcClient';-import { isTauri } from './common';export interface MemoryDebugDocument {documentId: string;@@ -80,15 +79,7 @@ export interface GraphRelation {* Initialise the local-only (SQLite) memory subsystem in the Rust core.*/export async function syncMemoryClientToken(token: string): Promise<void> {- console.debug(- '[memory] syncMemoryClientToken: entry (token_present=%s, is_tauri=%s)',- !!token,- isTauri()- );- if (!isTauri()) {- console.debug('[memory] syncMemoryClientToken: exit — skipped (not Tauri)');- return;- }+ console.debug('[memory] syncMemoryClientToken: entry (token_present=%s)', !!token);try {console.debug('[memory] syncMemoryClientToken: payload → memory.init (local-only)');// jwt_token is passed for backward compatibility but ignored by the core.diff --git a/app/src/utils/tauriCommands/service.ts b/app/src/utils/tauriCommands/service.tsindex 26e72d53ae..f3b3c62016 100644--- a/app/src/utils/tauriCommands/service.ts+++ b/app/src/utils/tauriCommands/service.ts@@ -31,66 +31,66 @@ export interface RestartStatus {}export async function openhumanServiceInstall(): Promise<CommandResponse<ServiceStatus>> {- if (!isTauri()) {- throw new Error('Not running in Tauri');- }try {return await callCoreRpc<CommandResponse<ServiceStatus>>({method: 'openhuman.service_install',});- } catch {+ } catch (err) {+ // The direct CLI fallback is a Tauri shell command; outside the shell+ // surface the core RPC error instead.+ if (!isTauri()) throw err;const raw = await invoke<string>('service_install_direct');return parseServiceCliOutput<ServiceStatus>(raw);}}export async function openhumanServiceStart(): Promise<CommandResponse<ServiceStatus>> {- if (!isTauri()) {- throw new Error('Not running in Tauri');- }try {return await callCoreRpc<CommandResponse<ServiceStatus>>({ method: 'openhuman.service_start' });- } catch {+ } catch (err) {+ // The direct CLI fallback is a Tauri shell command; outside the shell+ // surface the core RPC error instead.+ if (!isTauri()) throw err;const raw = await invoke<string>('service_start_direct');return parseServiceCliOutput<ServiceStatus>(raw);}}export async function openhumanServiceStop(): Promise<CommandResponse<ServiceStatus>> {- if (!isTauri()) {- throw new Error('Not running in Tauri');- }try {return await callCoreRpc<CommandResponse<ServiceStatus>>({ method: 'openhuman.service_stop' });- } catch {+ } catch (err) {+ // The direct CLI fallback is a Tauri shell command; outside the shell+ // surface the core RPC error instead.+ if (!isTauri()) throw err;const raw = await invoke<string>('service_stop_direct');return parseServiceCliOutput<ServiceStatus>(raw);}}export async function openhumanServiceStatus(): Promise<CommandResponse<ServiceStatus>> {- if (!isTauri()) {- throw new Error('Not running in Tauri');- }try {return await callCoreRpc<CommandResponse<ServiceStatus>>({method: 'openhuman.service_status',});- } catch {+ } catch (err) {+ // The direct CLI fallback is a Tauri shell command; outside the shell+ // surface the core RPC error instead.+ if (!isTauri()) throw err;const raw = await invoke<string>('service_status_direct');return parseServiceCliOutput<ServiceStatus>(raw);}}export async function openhumanServiceUninstall(): Promise<CommandResponse<ServiceStatus>> {- if (!isTauri()) {- throw new Error('Not running in Tauri');- }try {return await callCoreRpc<CommandResponse<ServiceStatus>>({method: 'openhuman.service_uninstall',});- } catch {+ } catch (err) {+ // The direct CLI fallback is a Tauri shell command; outside the shell+ // surface the core RPC error instead.+ if (!isTauri()) throw err;const raw = await invoke<string>('service_uninstall_direct');return parseServiceCliOutput<ServiceStatus>(raw);}diff --git a/app/src/utils/tauriCommands/taskSources.ts b/app/src/utils/tauriCommands/taskSources.tsindex 2a6bec4109..6f3fee32aa 100644--- a/app/src/utils/tauriCommands/taskSources.ts+++ b/app/src/utils/tauriCommands/taskSources.ts@@ -7,7 +7,6 @@* payload.*/import { callCoreRpc } from '../../services/coreRpcClient';-import { isTauri } from './common';export type TaskSourceProvider = 'github' | 'notion' | 'linear' | 'clickup';@@ -120,24 +119,15 @@ export interface TaskSourceAddParams {max_tasks_per_fetch?: number;}-function ensureTauri(): void {- if (!isTauri()) {- throw new Error('Not running in Tauri');- }-}-export async function openhumanTaskSourcesList(): Promise<TaskSource[]> {- ensureTauri();return await callCoreRpc<TaskSource[]>({ method: 'openhuman.task_sources_list' });}export async function openhumanTaskSourcesGet(id: string): Promise<TaskSource> {- ensureTauri();return await callCoreRpc<TaskSource>({ method: 'openhuman.task_sources_get', params: { id } });}export async function openhumanTaskSourcesAdd(params: TaskSourceAddParams): Promise<TaskSource> {- ensureTauri();return await callCoreRpc<TaskSource>({method: 'openhuman.task_sources_add',params: params as unknown as Record<string, unknown>,@@ -148,7 +138,6 @@ export async function openhumanTaskSourcesUpdate(id: string,patch: TaskSourcePatch): Promise<TaskSource> {- ensureTauri();return await callCoreRpc<TaskSource>({method: 'openhuman.task_sources_update',params: { id, patch },@@ -158,7 +147,6 @@ export async function openhumanTaskSourcesUpdate(export async function openhumanTaskSourcesRemove(id: string): Promise<{ id: string; removed: boolean; pruned?: number }> {- ensureTauri();return await callCoreRpc<{ id: string; removed: boolean; pruned?: number }>({method: 'openhuman.task_sources_remove',params: { id },@@ -166,7 +154,6 @@ export async function openhumanTaskSourcesRemove(}export async function openhumanTaskSourcesFetch(id: string): Promise<FetchOutcome> {- ensureTauri();return await callCoreRpc<FetchOutcome>({method: 'openhuman.task_sources_fetch',params: { id },@@ -174,7 +161,6 @@ export async function openhumanTaskSourcesFetch(id: string): Promise<FetchOutcom}export async function openhumanTaskSourcesSync(): Promise<FetchOutcome[]> {- ensureTauri();return await callCoreRpc<FetchOutcome[]>({ method: 'openhuman.task_sources_sync' });}@@ -182,7 +168,6 @@ export async function openhumanTaskSourcesListTasks(id: string,limit = 50): Promise<NormalizedTask[]> {- ensureTauri();return await callCoreRpc<NormalizedTask[]>({method: 'openhuman.task_sources_list_tasks',params: { id, limit },@@ -195,7 +180,6 @@ export async function openhumanTaskSourcesPreviewFilter(connectionId?: string,max?: number): Promise<NormalizedTask[]> {- ensureTauri();return await callCoreRpc<NormalizedTask[]>({method: 'openhuman.task_sources_preview_filter',params: { provider, filter, connection_id: connectionId, max },@@ -209,7 +193,6 @@ export async function openhumanTaskSourcesListDatabases(provider: TaskSourceProvider,connectionId?: string): Promise<TaskContainer[]> {- ensureTauri();return await callCoreRpc<TaskContainer[]>({method: 'openhuman.task_sources_list_databases',params: { provider, connection_id: connectionId },@@ -217,6 +200,5 @@ export async function openhumanTaskSourcesListDatabases(}export async function openhumanTaskSourcesStatus(): Promise<TaskSourcesStatus> {- ensureTauri();return await callCoreRpc<TaskSourcesStatus>({ method: 'openhuman.task_sources_status' });}